Hi,
I use Informix database and i have a problem
Sql statements LOAD and UNLOAD dont work from the application via ODBC
Program report syntax error
Some sugestions ?
Best regards,
Again, unless you can do this from a batch file, I believe your best bet is going to be looping through recordsets and handling the file access manually. I.e. in pseudocode:
'UNLOAD
Open recordset with SELECT * FROM table
Open file for write access
Until recordset.EOF
{ Write record to file (with delimiters)
Move to next record
}
Close recordset
Close file
'LOAD
Open file for read access
Until file.EOF
{ Read line from file
Parse line (Split on delimiters) and generate SQL INSERT statement
Insert record into database using command .Execute method
}
Close file
Return to FiveWin for Harbour/xHarbour
Users browsing this forum: No registered users and 94 guests