Return code for bad command

Return code for bad command

am 04.06.2006 00:23:21 von Jonathan Blitz

This is a multi-part message in MIME format.

------=_NextPart_000_0775_01C68773.6869A2A0
Content-Type: text/plain;
charset="windows-1250"
Content-Transfer-Encoding: quoted-printable

I am using PostgreSQL version 8.0 with VC++ 2005.

=20

I use the native VC++ ODBC classes to access the PostgreSQL ODBC driver.

=20

When I issue an SQL command with an error I always get the same error =
code:
7

=20

The message is ok but the code would be kinda useful =96 don=92t really =
want to
start parsing the message.

=20

I tried it with the 8.02.00.02 driver and the ANSI version of the =
8.01.02.00

=20

Both give the same result.

=20

Is this a bug or am I doing something wrong?

=20

Jonathan Blitz


--=20
No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.1.394 / Virus Database: 268.8.1/355 - Release Date: =
06/02/2006
=20

------=_NextPart_000_0775_01C68773.6869A2A0
Content-Type: text/html;
charset="windows-1250"
Content-Transfer-Encoding: quoted-printable

xmlns:w=3D"urn:schemas-microsoft-com:office:word" =
xmlns=3D"http://www.w3.org/TR/REC-html40">


charset=3Dwindows-1250">











style=3D'font-size:10.0pt;
font-family:Arial'>I am using PostgreSQL version 8.0 with VC++ =
2005.



style=3D'font-size:10.0pt;
font-family:Arial'> 



style=3D'font-size:10.0pt;
font-family:Arial'>I use the native VC++ ODBC classes to access the =
PostgreSQL
ODBC driver.



style=3D'font-size:10.0pt;
font-family:Arial'> 



style=3D'font-size:10.0pt;
font-family:Arial'>When I issue an SQL command with an error I always =
get the
same error code: 7



style=3D'font-size:10.0pt;
font-family:Arial'> 



style=3D'font-size:10.0pt;
font-family:Arial'>The message is ok but the code would be kinda useful =
– don’t
really want to start parsing the message.



style=3D'font-size:10.0pt;
font-family:Arial'> 



style=3D'font-size:10.0pt;
font-family:Arial'>I tried it with the 8.02.00.02 driver and the ANSI =
version
of the 8.01.02.00



style=3D'font-size:10.0pt;
font-family:Arial'> 



style=3D'font-size:10.0pt;
font-family:Arial'>Both give the same =
result.



style=3D'font-size:10.0pt;
font-family:Arial'> 



style=3D'font-size:10.0pt;
font-family:Arial'>Is this a bug or am I doing something =
wrong?



style=3D'font-size:10.0pt;
font-family:Arial'> 



style=3D'font-size:10.0pt;
font-family:Arial'>Jonathan Blitz











--

No virus found in this outgoing message.

Checked by AVG Free Edition.

Version: 7.1.394 / Virus Database: 268.8.1/355 - Release Date: =
06/02/2006



------=_NextPart_000_0775_01C68773.6869A2A0--

Re: Return code for bad command

am 04.06.2006 18:04:43 von Ludek Finstrle

> I am using PostgreSQL version 8.0 with VC++ 2005.
>
> I use the native VC++ ODBC classes to access the PostgreSQL ODBC driver.
>
> When I issue an SQL command with an error I always get the same error code:
> 7

....

> Is this a bug or am I doing something wrong?

It's normal behaviour. Let's try read sqlstate (I don't know how it is
accessed through VC++ ODBC classes.

Regards,

Luf

---------------------------(end of broadcast)---------------------------
TIP 4: Have you searched our list archives?

http://archives.postgresql.org

Re: Return code for bad command

am 04.06.2006 19:06:42 von Jonathan Blitz

Ok - I'll give it a try and see what I get.

> -----Original Message-----
> From: Ludek Finstrle [mailto:luf@pzkagis.cz]
> Sent: Sunday, June 04, 2006 6:05 PM
> To: Jonathan Blitz
> Cc: pgsql-odbc@postgresql.org
> Subject: Re: [ODBC] Return code for bad command
>
> > I am using PostgreSQL version 8.0 with VC++ 2005.
> >
> > I use the native VC++ ODBC classes to access the PostgreSQL ODBC driver.
> >
> > When I issue an SQL command with an error I always get the same error
code:
> > 7
>
> ...
>
> > Is this a bug or am I doing something wrong?
>
> It's normal behaviour. Let's try read sqlstate (I don't know how it is
> accessed through VC++ ODBC classes.
>
> Regards,
>
> Luf
>
> ---------------------------(end of broadcast)---------------------------
> TIP 4: Have you searched our list archives?
>
> http://archives.postgresql.org
>
>
>
>
> --
> No virus found in this incoming message.
> Checked by AVG Free Edition.
> Version: 7.1.394 / Virus Database: 268.8.1/355 - Release Date: 6/2/2006
>
> --
> No virus found in this incoming message.
> Checked by AVG Free Edition.
> Version: 7.1.394 / Virus Database: 268.8.1/355 - Release Date: 06/02/2006
>

--
No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.1.394 / Virus Database: 268.8.1/355 - Release Date: 06/02/2006



---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?

http://www.postgresql.org/docs/faq

RES: Return code for bad command

am 05.06.2006 14:03:20 von Renato Gondim

I'm having the same behavior and the sqlstate returns the same code: HY000.
Reading the MSDN this code is described as "General error".

Renato Gondim.

-----Mensagem original-----
De: pgsql-odbc-owner@postgresql.org [mailto:pgsql-odbc-owner@postgresql.org]
Em nome de Ludek Finstrle
Enviada em: domingo, 4 de junho de 2006 13:05
Para: Jonathan Blitz
Cc: pgsql-odbc@postgresql.org
Assunto: Re: [ODBC] Return code for bad command

> I am using PostgreSQL version 8.0 with VC++ 2005.
>=20
> I use the native VC++ ODBC classes to access the PostgreSQL ODBC driver.
>=20
> When I issue an SQL command with an error I always get the same error
code:
> 7

....

> Is this a bug or am I doing something wrong?

It's normal behaviour. Let's try read sqlstate (I don't know how it is
accessed through VC++ ODBC classes.

Regards,

Luf

---------------------------(end of broadcast)---------------------------
TIP 4: Have you searched our list archives?

http://archives.postgresql.org


---------------------------(end of broadcast)---------------------------
TIP 2: Don't 'kill -9' the postmaster

Re: RES: Return code for bad command

am 05.06.2006 14:16:16 von Ludek Finstrle

> I'm having the same behavior and the sqlstate returns the same code: HY000.
> Reading the MSDN this code is described as "General error".

Does psqlodbc 08.01.0200 return the same?
Please could you send mylog outputs from two different errors?

Regards,

Luf

---------------------------(end of broadcast)---------------------------
TIP 4: Have you searched our list archives?

http://archives.postgresql.org