Re: Insert query
От | Jeff Eckermann |
---|---|
Тема | Re: Insert query |
Дата | |
Msg-id | 20031017135933.47682.qmail@web20803.mail.yahoo.com обсуждение исходный текст |
Ответ на | Insert query ("Nigel Brookes" <nigel.brookes@clerys.ie>) |
Список | pgsql-odbc |
--- Nigel Brookes <nigel.brookes@clerys.ie> wrote: > Hi Folks, > > I'm very new to ODBC and am using VB 5.0. I have a > table with a serial data > type that I'm trying to insert a record into using. > > INSERT INTO users VALUES (DEFAULT,'Nigel'); > > This works when i'm in linux. But when I try to > execute it in VB I get an > error 'Too few parameters. Expected 1.'. Very > strange. Have tried all 3 > odbc drivers. The VB code I use is as follows: > > Dim Backupdb As Database > '******opens access to PostgreSQL database > *********************** > Connect = > "ODBC;DSN=backupdb;DATABASE=backupdb;UID=test;PWD=test;" > Set Backupdb = OpenDatabase("backupdb", > False, False, Connect) > > '***************************************************************** > > Backupdb.Execute txtExecute.Text > > Any Ideas?? Don't know the cause of the error, but: what happens if you use "INSERT INTO users (fieldname) VALUES ('Nigel');" ? __________________________________ Do you Yahoo!? The New Yahoo! Shopping - with improved product search http://shopping.yahoo.com
В списке pgsql-odbc по дате отправления: