odbc error

Michele Petrazzo michele.petrazzo at TOGLIunipex.it
Thu Sep 30 09:00:13 CEST 2004


Steve Holden wrote:
> Michele Petrazzo wrote:
> 
>> I'm using odbc on win95 and I have an incomprehensible error after a 
>> query:
>>
>> INSERT INTO test VALUES (f1,f2,f3) VALUES ("t1", "t2", "")
>>
>> table test and fields f1,f2,f3 exists :) and I can write to this table.
>>
>> The error is :
>> [Microsoft][Driver ODBC dBase] Too few parameters. Expected 2.
>>
>> What can I do?
>>
> The easiest thing to do is use correct syntax, which should put single 
> quotes around string literals. The ODBC drivers tend to use standard SQL 
> syntax even when the underlying database is a bit more liberal. Try
> 
> INSERT INTO test VALUES (f1,f2,f3) VALUES ('t1', 't2', '')
> 
> and see if that works.
> 
> regards
>  Steve

It work !!!!
Thanks very much.

Michele Petrazzo



More information about the Python-list mailing list