Thread: Query Fails

Query Fails

From
Sheikh Salman Ahmed
Date:

Hallo Fellows
 
I am a new User of postgresql.I have installed it on window XP.I feel it little complicated on Window.I have already connected it with visual c++ 2005,but when i wanted to insert some data in my databank,then it fails and shows sytax error or  doesn't recognise my table, but connection to data it shows.
i am using this code to insert data.
 
res = PQexec (conn, "INSERT INTO public.Person values (121,'xxx','yyy')");
 
It will be grateful,if u ppl can help me. 

 
Sheikh Salman Ahmed
Diplomand in Nano Struktur Technologie
Duisburg-Essen Universität
Mobile : 0049-179-9463738
Home :0049-203-3945028




Explore the seven wonders of the world Learn more!

Re: Query Fails

From
"A. Kretschmer"
Date:
am  Mon, dem 30.06.2008, um 20:38:08 +0000 mailte Sheikh Salman Ahmed folgendes:
>
> Hallo Fellows
>
> I am a new User of postgresql.I have installed it on window XP.I feel it little
> complicated on Window.I have already connected it with visual c++ 2005,but when
> i wanted to insert some data in my databank,then it fails and shows sytax error
> or  doesn't recognise my table, but connection to data it shows.
> i am using this code to insert data.
>
> res = PQexec (conn, "INSERT INTO public.Person values (121,'xxx','yyy')");
>
> It will be grateful,if u ppl can help me.

Please provide more details such the table-definition and the error
message.


Regards, Andreas
--
Andreas Kretschmer
Kontakt:  Heynitz: 035242/47150,   D1: 0160/7141639 (mehr: -> Header)
GnuPG-ID:   0x3FFF606C, privat 0x7F4584DA   http://wwwkeys.de.pgp.net

Re: Query Fails

From
"Chandra ASGI Tech"
Date:
Hi,
 
Also please check the number of attributes (columns) in the table and their datatype - ensure that your Insert query handles them properly. Better would be if you can give the details like the table structure, the error output.
 
Also, verify if the error is something related to VC++, rather than postgres.
 
regards,
ChandraASGI

On Tue, Jul 1, 2008 at 4:12 AM, A. Kretschmer <andreas.kretschmer@schollglas.com> wrote:
am  Mon, dem 30.06.2008, um 20:38:08 +0000 mailte Sheikh Salman Ahmed folgendes:
>
> Hallo Fellows
>
> I am a new User of postgresql.I have installed it on window XP.I feel it little
> complicated on Window.I have already connected it with visual c++ 2005,but when
> i wanted to insert some data in my databank,then it fails and shows sytax error
> or  doesn't recognise my table, but connection to data it shows.
> i am using this code to insert data.
>
> res = PQexec (conn, "INSERT INTO public.Person values (121,'xxx','yyy')");
>
> It will be grateful,if u ppl can help me.

Please provide more details such the table-definition and the error
message.


Regards, Andreas
--
Andreas Kretschmer
Kontakt:  Heynitz: 035242/47150,   D1: 0160/7141639 (mehr: -> Header)
GnuPG-ID:   0x3FFF606C, privat 0x7F4584DA   http://wwwkeys.de.pgp.net

--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general