On Thu, 1 Feb 2001, Seger, Jeffrey wrote:
>LOAD is not an SQL command.
Correct. Even in the Informix databases, LOAD is not implemented by the
database server itself. Various programs (DB-Access, I4GL, ISQL,
SQLCMD) provide user-level implementations of the LOAD functionality,
but the database server does not.
The TODO file distributed with DBD::Informix 1.00.PC1 (current version)
lists LOAD and UNLOAD as things to consider providing. In the meantime,
use either DB-Access or DB-Load or SQLCMD or HPL or Pload or something
to handle the LOAD operations. SQLCMD can be obtained from the IIUG at
http://www.iiug.org.
>I'm not sure what database you are using,
Informix -- at least, I don't know of another DBMS that generates -201
errors for "A syntax error has occurred". The fact that the messages is
copied to [EMAIL PROTECTED] is another strong hint...
>but that looks a lot like SQL*Loader control file syntax.
Sounds plausible. Informix has many ways to load data too.
>DBI implements valid SQL commands.
>
>-----Original Message-----
>From: Liu, Jenny [mailto:[EMAIL PROTECTED]]
>Sent: Thursday, February 01, 2001 11:05 AM
>To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
>Subject: load file into table, get syntax error
>
>
>I tried to load some data from a text file into a table. The statements and
>the error message are as following:
>Please advise.
>
>Thanks
>
>Jenny
>
>$Sql_stmt = "LOAD FROM cac_pos_format.load INSERT INTO cac_pos_format";
> $sth = $dbh->do($Sql_stmt);
>
>SQL error: -201
>Error text: SQL: -201: A syntax error has occurred.
>Error: Start Rollback....10:58:17
>Error: Rollback Completed....10:58:17
>
--
Yours,
Jonathan Leffler ([EMAIL PROTECTED]) #include <disclaimer.h>
Guardian of DBD::Informix v1.00.PC1 -- http://www.perl.com/CPAN
"I don't suffer from insanity; I enjoy every minute of it!"