October 26, 1999

Problems with ADO

Question: I was out on the Fox newsgroup and somebody posted some ADO code in Visual FoxPro that alarmed me. VFP seems to have a major problem repeatedly accessing the Field collection on the ADO recordset. There seems to be a huge memory leak. I ran the following code in

Limited Dynamic SQL

Question: I am a technical copywriter currently writing a fact sheet for a software company providing DB2 SQL support. They have something they want to call “limited dynamic SQL.” Here’s a description: Flexible SQL lets developers add SQL text strings to SQL statements. With “Limited Dynamic SQL”, natural host variables

Comparing Columns from Different Tables

Question: I have a problem comparing columns from different tables. I tried: SELECT tblThumBereinigt.Nummer, dbo_BABEWERTUNG.BANUMMERFROM dbo_BABEWERTUNG, tblThumBereinigtWHERE (((dbo_BABEWERTUNG.BANUMMER)[tblThumBereinigt].[Nummer])); but this does not give me what I want. How can I compare different tables with an exclusive condition? Answer: Try this: select * from information_schema.columns That should give you a list

SQL Syntax

Question: How difficult is it to convert a Sybase Transact-SQL database to SQL/400, and where can I find information on SQL/400? Answer: I don’t know but, in the main, learning syntax is a question of exploiting the vendor’s extensions, so if you know SQL, you’re already 75 percent of the

Changing the Text Value of a Populated Field

Question: How do I correct a spelling error in a table? I am at a loss as to where to start. Answer: Hoping for the best, I’d say that what you need to do is something like this: UPDATE MyTable.MyField SET MyTable.MyField = to NEWVALUE where MyTable.MyField = OLDVALUE On

DTS & Data Driven Query Task

Question: I am trying to import data from a .CSV file and verify that the rec importing does not exist on the destination database (SQL7 DB), then either insert or update the rec’s details. But suffice to say this is not happening as I predicted. The insert and update query

Forwarding E-mail and Retaining the From Address

Question: I have a Microsoft Exchange mailbox and want to have all my e-mail forwarded to a Unix e-mail address. I tried the Forward All Mail feature in Outlook but it doesn’t retain the From address (it replaces it with my Exchange address). Is there any way to forward e-mail

List View Control and Structure in Data Attribute

Question: I populate the list view control with the required items and each of these items are set with a pre-defined structure in the data attribute of the list view item. When I access the data in the structure through some code it works fine in most of the cases.

Comparing Two Tables

Question: How do I compare two tables and extract only where field1 doesn’t match field2? Will MINUS do it? Answer: Yes, but it’s not that direct. To do MINUS (or DIFFERENCE), I think you need to use WHERE NOT IN like this: SELECT t1.c1 from t1 where t1.c1 NOT IN

No more posts to show