X-Original-To: pgsql-odbc-postgresql.org@localhost.postgresql.org Received: from localhost (neptune.hub.org [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id 7BAC0D1B4BB for ; Thu, 27 Nov 2003 16:46:45 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 06431-01 for ; Thu, 27 Nov 2003 12:46:13 -0400 (AST) Received: from paiol.terra.com.br (paiol.terra.com.br [200.176.3.18]) by svr1.postgresql.org (Postfix) with ESMTP id D8455D1B4B4 for ; Thu, 27 Nov 2003 12:46:11 -0400 (AST) Received: from gunga.terra.com.br (gunga.terra.com.br [200.176.3.45]) by paiol.terra.com.br (Postfix) with ESMTP id AC7938480B8 for ; Thu, 27 Nov 2003 14:46:10 -0200 (BRST) Received: from ttcristian (200-180-005-167.fnsce7006.dsl.brasiltelecom.net.br [200.180.5.167]) (authenticated user cristian_custodio) by gunga.terra.com.br (Postfix) with ESMTP id D5C641280F9 for ; Thu, 27 Nov 2003 14:46:08 -0200 (BRST) Message-ID: <005d01c3b50d$f1328c90$b301a8c0@ttcristian> Reply-To: "Cristian Custodio" From: "Cristian Custodio" To: References: Subject: Re: Character invalid saving memo with UpdateSQL Date: Thu, 27 Nov 2003 14:43:17 -0300 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_005A_01C3B4F4.CB327F50" X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2800.1158 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165 X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200311/121 X-Sequence-Number: 3523 This is a multi-part message in MIME format. ------=_NextPart_000_005A_01C3B4F4.CB327F50 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable I'll do this, thanks. Cristian ----- Original Message -----=20 From: Leeuw van der, Tim=20 To: 'Cristian Custodio' ; pgsql-odbc@postgresql.org=20 Sent: Thursday, November 27, 2003 11:17 AM Subject: RE: [ODBC] Character invalid saving memo with UpdateSQL Hi, If you're converting an application from Oracle to PG, that implies that = in the Oracle DB you also had such large VARCHAR fields. And since that did= n't give trouble, it furthermore implies that the problem is in the PG ODBC= drivers. Perhaps you should file a bug against them? I have a varchar(1000) field in my db but since it's not actually used I = haven't ran into any trouble with my application (using C#) (it's just a co= mment-field and I haven't filled the comment with sensible and large things= in my tests, and I'm the only one testing with PG from time to time - regu= lar testing is with MySQL and Oracle, production on Oracle only). About testing with MS-Access, I thought you could perhaps try to open the= db tables as linked tables in Access, and execute an update-query from the= re just to see whether or not any garbage is entered into the database inst= ead of the proper info. regards, --Tim -----Original Message----- From: pgsql-odbc-owner@postgresql.org [mailto:pgsql-odbc-owner@postgres= ql.org]On Behalf Of Cristian Custodio Sent: donderdag 27 november 2003 15:06 To: pgsql-odbc@postgresql.org Subject: Re: [ODBC] Character invalid saving memo with UpdateSQL Its imposible. We are converting ours application in Oracle to PG. I will try create a trigger or a function to resolve this problem. Thanks, Cristian ----- Original Message -----=20 From: Leeuw van der, Tim=20 To: pgsql-odbc@postgresql.org=20 Sent: Thursday, November 27, 2003 8:41 AM Subject: Re: [ODBC] Character invalid saving memo with UpdateSQL In quite a lot of databases, VARCHAR has an upper limit of 255 charac= ters. I would say that most likely some of the libraries don't count of eve= r having a VARCHAR of greater length than that. It sounds like a buffer-ove= rrun problem, but I couldn't say where - in the postgresql ODBC drivers, or= in other parts of the odbc layers / libraries. Most like not in the postgr= esql drivers though. I don't know what BDE is - some sort of library on top of ODBC? If so= , what happens if you try to insert/update such long strings using direct O= DBC? Or from another platform than Delphi, from MS-Access for instance? regards, --Tim -----Original Message----- From: pgsql-odbc-owner@postgresql.org [mailto:pgsql-odbc-owner@post= gresql.org]On Behalf Of Cristian Custodio Sent: donderdag 27 november 2003 12:59 To: pgsql-odbc@postgresql.org Subject: Re: [ODBC] Character invalid saving memo with UpdateSQL I'm using LATIN1 but the problem happened with any other database.= =20 It Occur with any varchar column greatest 255 characters. Cristian ----- Original Message -----=20 From: Richard Combs=20 To: Cristian Custodio=20 Cc: pgsql-odbc@postgresql.org=20 Sent: Wednesday, November 26, 2003 2:50 PM Subject: Re: [ODBC] Character invalid saving memo with UpdateSQL I haven't used the BDE in a while, however it looks like a proble= m with character sets. That is BDE is using one character set and PG is us= ing another, hence the "invalid" characters. Check the postgreSQL document= ation on localization to see how to make your server recognize other langua= ge (character) sets. One other question, does this happen only with varchar and only w= ith that one column, or can you duplicate the problem with character type i= n another column? Cristian Custodio wrote: I'm using delphi 5 and PG: 7.3.4 and BDE I have 1 varchar(4000) column. When I try post any value in thi= s column using UpdateSQL it save very invalids caracters. Like this: =ED= =ED=ED=ED=ED=ED=ED=ED=ED. Any body could help me? Thanks, Cristian Luciano Custodio=20 ------=_NextPart_000_005A_01C3B4F4.CB327F50 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
I'll do this, thanks.
 
Cristian
 
----- Original Message -----
Fro= m:=20 Leeuw van der, Tim
To: 'Cristian Custodio' ; = pgsql-odbc@postgresql.org <= /DIV>
Sent: Thursday, November 27, 2003 = 11:17=20 AM
Subject: RE: [ODBC] Character inva= lid=20 saving memo with UpdateSQL

Hi,
 
If=20 you're converting an application from Oracle to PG, that implies that in = the=20 Oracle DB you also had such large VARCHAR fields. And since that didn't g= ive=20 trouble, it furthermore implies that the problem is in the PG ODBC=20 drivers.
 
Perhaps you should file a bug against them?
 
I=20 have a varchar(1000) field in my db but since it's not actually used I ha= ven't=20 ran into any trouble with my application (using C#) (it's just a=20 comment-field and I haven't filled the comment with sensible and large th= ings=20 in my tests, and I'm the only one testing with PG from time to time - reg= ular=20 testing is with MySQL and Oracle, production on Oracle=20 only).
 
About testing with MS-Access, I thought you could perhaps t= ry to=20 open the db tables as linked tables in Access, and execute an=20 update-query from there just to see whether or not any garbage is entered= into=20 the database instead of the proper info.
 
 
regards,
 
--Tim
 
-----Original Message-----
From:=20 pgsql-odbc-owner@postgresql.org=20 [mailto:pgsql-odbc-owner@postgresql.org]On Behalf Of Cristian=20 Custodio
Sent: donderdag 27 november 2003 15:06
To:= =20 pgsql-odbc@postgresql.org
Subject: Re: [ODBC] Character inval= id=20 saving memo with UpdateSQL

Its imposible. We are conver= ting ours=20 application in Oracle to PG.
 
I will try create a trigger or a = function=20 to resolve this problem.
 
Thanks,
 
Cristian
 
 
 
 
----- Original Message -----
From:=20 Leeuw van der, Tim =
To: pgsql-odbc@postgresql.org=20
Sent: Thursday, November 27, 2= 003=20 8:41 AM
Subject: Re: [ODBC] Character = invalid=20 saving memo with UpdateSQL

In quite a lot of databases, VARCHAR has a= n upper=20 limit of 255 characters. I would say that most likely some of th= e=20 libraries don't count of ever having a VARCHAR of greater length than= =20 that. It sounds like a buffer-overrun problem, but I couldn't sa= y=20 where - in the postgresql ODBC drivers, or in other parts of the odbc= =20 layers / libraries. Most like not in the postgresql drivers=20 though.
 
I don't know what BDE is - some sort of li= brary=20 on top of ODBC? If so, what happens if you try to insert/update such = long=20 strings using direct ODBC? Or from another platform than Delphi, from= =20 MS-Access for instance?
 
regards,
 
--Tim
-----Original Message-----
From:=20 pgsql-odbc-owner@postgresql.org=20 [mailto:pgsql-odbc-owner@postgresql.org]On Behalf Of Cristia= n=20 Custodio
Sent: donderdag 27 november 2003 12:59
To:= =20 pgsql-odbc@postgresql.org
Subject: Re: [ODBC] Character= =20 invalid saving memo with UpdateSQL

I'm using LATIN1 but the prob= lem=20 happened with any other database.
 
It Occur with any varchar column g= reatest=20 255 characters.
 
Cristian
 
 
----- Original Message ----- Ri= chard=20 Combs
To: Cristian Custodio<= /A>=20
Cc: pgsql-odbc@postgresql.o= rg=20
Sent: Wednesday, November = 26,=20 2003 2:50 PM
Subject: Re: [ODBC] Charac= ter=20 invalid saving memo with UpdateSQL

I haven't used the BDE in a while, however it look= s=20 like a problem with character sets.  That is BDE is using on= e=20 character set and PG is using another, hence the "invalid"=20 characters.  Check the postgreSQL documentation on localizat= ion=20 to see how to make your server recognize other language (characte= r)=20 sets.

One other question, does this happen only with varch= ar=20 and only with that one column, or can you duplicate the problem w= ith=20 character type in another column?

Cristian Custodio wrote:=
 
I'm using delphi 5 and PG: 7.3= .4 and=20 BDE
 
I have 1 varchar(4000) column.= When I=20 try post any value in this column
using UpdateSQL it save very i= nvalids=20 caracters. Like this: =ED=ED=ED=ED=ED=ED=ED=ED=ED.
 
Any body could help me?=
 
Thanks,
 
Cristian Luciano Custodio=20
------=_NextPart_000_005A_01C3B4F4.CB327F50--