X-Original-To: pgsql-odbc-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id B701C5295E for ; Thu, 21 Jul 2005 15:51:03 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 35852-10 for ; Thu, 21 Jul 2005 18:50:52 +0000 (GMT) Received: from web60819.mail.yahoo.com (web60819.mail.yahoo.com [209.73.178.227]) by svr1.postgresql.org (Postfix) with SMTP id 7F247528DA for ; Thu, 21 Jul 2005 15:50:48 -0300 (ADT) Received: (qmail 55516 invoked by uid 60001); 21 Jul 2005 18:50:49 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=Message-ID:Received:Date:From:Subject:To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=Lko9U4/Zpf2PP/UJHZH8L/okjX+sCsAxucYM0VaLdUnd+teetanhyhYsokhBkcWjyxwIbrtnMp6rSySrhS+ONF1qYMdusmjP0o7HrEX4jqno1mFMmkQF/8MN/1vMyiE5zEPsqBz9372jPq53PLZ3jWU1kaU0xzohfrXAp3s/PzE= ; Message-ID: <20050721185049.55514.qmail@web60819.mail.yahoo.com> Received: from [66.208.189.118] by web60819.mail.yahoo.com via HTTP; Thu, 21 Jul 2005 11:50:48 PDT Date: Thu, 21 Jul 2005 11:50:48 -0700 (PDT) From: "Peter L." Subject: Blank varchar and text fields To: pgsql-odbc@postgresql.org MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="0-338261555-1121971848=:54154" Content-Transfer-Encoding: 8bit X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.296 tagged_above=0 required=5 tests=HTML_10_20, HTML_MESSAGE X-Spam-Level: X-Archive-Number: 200507/104 X-Sequence-Number: 5570 --0-338261555-1121971848=:54154 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit I'm using the latest release version of the driver dll psqlodbc-08_00_0101 with a report writing application called R&R Report writer. When a report queries the database for data to display, all of the varchar and text fields come back blank. After doing some research, the only evidence of the cause that I'm finding is that the cbValueMax for those fields is 1 instead of the actual length of the text buffer. Can anyone suggest a solution or where in the code I should look to fix this problem? Log snippets: psqldobc.log conn=43202584, query='select * from www.quote where 0 = 1' [ fetched 0 rows ] conn=43202584, query='select u.nspname, c.relname, a.attname, a.atttypid, t.typname, a.attnum, a.attlen, a.atttypmod, a.attnotnull, c.relhasrules, c.relkind from pg_catalog.pg_namespace u, pg_catalog.pg_class c, pg_catalog.pg_attribute a, pg_catalog.pg_type t where u.oid = c.relnamespace and (not a.attisdropped) and c.oid= a.attrelid and a.atttypid = t.oid and (a.attnum > 0) and c.relname = 'quote' and u.nspname = 'www' and nspname !~ '^pg_' order by u.nspname, c.relname, attnum' [ fetched 72 rows ] ... PGAPI_Columns: table='quote',field_name='quote_id',type=23,name='int4' PGAPI_Columns: table='quote',field_name='account_name',type=1043,name='varchar' PGAPI_Columns: table='quote',field_name='responses',type=25,name='text' ... The 2th item was truncated The buffer size = 1 and the value is 'Hydro Aluminum Automotive' The 3th item was truncated The buffer size = 1 and the value is ' The crimp specification is 15.9mm or .626 inch. Unfortunataly there is not a 43 series die that goes that tight.' mylog.log [940]READING ATTTYPMOD [940]CI_read_fields: fieldname='quote_id', adtid=23, adtsize=4, atttypmod=-1 [940]READING ATTTYPMOD [940]CI_read_fields: fieldname='account_name', adtid=1043, adtsize=-1, atttypmod=80 [940]READING ATTTYPMOD [940]CI_read_fields: fieldname='responses', adtid=25, adtsize=-1, atttypmod=-1 ... [940][SQLDescribeColW][940]PGAPI_DescribeCol: entering.3.. [940]PARSE: DescribeCol: icol=2, stmt=43230000, stmt->nfld=23, stmt->fi=43197072 [940]DescribeCol: getting info for icol=2 [940]PARSE: fieldtype=23, col_name='quote_id', column_size=10 [940]describeCol: col 2 fieldname = 'quote_id' [940]describeCol: col 2 fieldtype = 23 [940]describeCol: col 2 column_size = 10 [940]describeCol: col 2 *pfSqlType = 4 [940]describeCol: col 2 *pcbColDef = 10 [940]describeCol: col 2 *pibScale = 0 [940]describeCol: col 2 *pfNullable = 1 [940][SQLDescribeColW][940]PGAPI_DescribeCol: entering.16.. [940]PARSE: DescribeCol: icol=15, stmt=43230000, stmt->nfld=35, stmt->fi=43196648 [940]DescribeCol: getting info for icol=15 [940]PARSE: fieldtype=1043, col_name='account_name', column_size=80 [940]describeCol: col 15 fieldname = 'account_name' [940]describeCol: col 15 fieldtype = 1043 [940]describeCol: col 15 column_size = 80 [940]getCharColumnSize: type=1043, col=15, unknown = 0 [940]describeCol: col 15 *pfSqlType = -9 [940]describeCol: col 15 *pcbColDef = 80 [940]describeCol: col 15 *pibScale = 0 [940][SQLDescribeColW][940]PGAPI_DescribeCol: entering.9.. [940]PARSE: DescribeCol: icol=8, stmt=43230000, stmt->nfld=35, stmt->fi=43196648 [940]DescribeCol: getting info for icol=8 [940]PARSE: fieldtype=25, col_name='responses', column_size=8190 [940]describeCol: col 8 fieldname = 'responses' [940]describeCol: col 8 fieldtype = 25 [940]describeCol: col 8 column_size = 8190 [940]describeCol: col 8 *pfSqlType = -10 [940]describeCol: col 8 *pcbColDef = 8190 [940]describeCol: col 8 *pibScale = 0 [940]describeCol: col 8 *pfNullable = 1 ... [940][SQLBindCol][940]PGAPI_BindCol: entering... [940]**** PGAPI_BindCol: stmt = 43230000, icol = 1 [940]**** : fCType=4 rgb=18a490 valusMax=4 pcb=16de88 [940]extend_getdata_info: entering ... self=43230348, gdata_allocated=17, num_columns=18 [940]exit extend_gdata_info [940] bound buffer[17] = 1614992 [940][SQLBindCol][940]PGAPI_BindCol: entering... [940]**** PGAPI_BindCol: stmt = 43230000, icol = 2 [940]**** : fCType=1 rgb=12d564 valusMax=1 pcb=cc008 [940]extend_getdata_info: entering ... self=43230348, gdata_allocated=6, num_columns=7 [940]exit extend_gdata_info [940] bound buffer[6] = 1234276 [940]**** PGAPI_BindCol: stmt = 43230000, icol = 3 [940]**** : fCType=1 rgb=18a574 valusMax=16 pcb=16e088 [940]extend_getdata_info: entering ... self=43230348, gdata_allocated=20, num_columns=21 [940]exit extend_gdata_info [940] bound buffer[20] = 1615220 --------------------------------- Start your day with Yahoo! - make it your home page --0-338261555-1121971848=:54154 Content-Type: text/html; charset=iso-8859-1 Content-Transfer-Encoding: 8bit
I'm using the latest release version of the driver dll psqlodbc-08_00_0101 with a report writing application called R&R Report writer.  When a report queries the database for data to display, all of the varchar and text fields come back blank.  After doing some research, the only evidence of the cause that I'm finding is that the cbValueMax for those fields is 1 instead of the actual length of the text buffer.  Can anyone suggest a solution or where in the code I should look to fix this problem?
 
Log snippets:
psqldobc.log
conn=43202584, query='select * from www.quote where 0 = 1'
    [ fetched 0 rows ]
conn=43202584, query='select u.nspname, c.relname, a.attname, a.atttypid, t.typname, a.attnum, a.attlen, a.atttypmod, a.attnotnull, c.relhasrules, c.relkind from pg_catalog.pg_namespace u, pg_catalog.pg_class c, pg_catalog.pg_attribute a, pg_catalog.pg_type t where u.oid = c.relnamespace and (not a.attisdropped) and c.oid= a.attrelid and a.atttypid = t.oid and (a.attnum > 0) and c.relname = 'quote' and u.nspname = 'www'  and nspname !~ '^pg_' order by u.nspname, c.relname, attnum'
    [ fetched 72 rows ]
...
PGAPI_Columns: table='quote',field_name='quote_id',type=23,name='int4'
PGAPI_Columns: table='quote',field_name='account_name',type=1043,name='varchar'
PGAPI_Columns: table='quote',field_name='responses',type=25,name='text'
...
The 2th item was truncated
The buffer size = 1 and the value is 'Hydro Aluminum Automotive'
The 3th item was truncated
The buffer size = 1 and the value is ' The crimp specification is 15.9mm or .626 inch.  Unfortunataly there is not a 43 series die that goes that tight.'
mylog.log
 
[940]READING ATTTYPMOD
[940]CI_read_fields: fieldname='quote_id', adtid=23, adtsize=4, atttypmod=-1
[940]READING ATTTYPMOD
[940]CI_read_fields: fieldname='account_name', adtid=1043, adtsize=-1, atttypmod=80
[940]READING ATTTYPMOD
[940]CI_read_fields: fieldname='responses', adtid=25, adtsize=-1, atttypmod=-1
...
[940][SQLDescribeColW][940]PGAPI_DescribeCol: entering.3..
[940]PARSE: DescribeCol: icol=2, stmt=43230000, stmt->nfld=23, stmt->fi=43197072
[940]DescribeCol: getting info for icol=2
[940]PARSE: fieldtype=23, col_name='quote_id', column_size=10
[940]describeCol: col 2 fieldname = 'quote_id'
[940]describeCol: col 2 fieldtype = 23
[940]describeCol: col 2 column_size = 10
[940]describeCol: col 2 *pfSqlType = 4
[940]describeCol: col 2  *pcbColDef = 10
[940]describeCol: col 2  *pibScale = 0
[940]describeCol: col 2  *pfNullable = 1
[940][SQLDescribeColW][940]PGAPI_DescribeCol: entering.16..
[940]PARSE: DescribeCol: icol=15, stmt=43230000, stmt->nfld=35, stmt->fi=43196648
[940]DescribeCol: getting info for icol=15
[940]PARSE: fieldtype=1043, col_name='account_name', column_size=80
[940]describeCol: col 15 fieldname = 'account_name'
[940]describeCol: col 15 fieldtype = 1043
[940]describeCol: col 15 column_size = 80
[940]getCharColumnSize: type=1043, col=15, unknown = 0
[940]describeCol: col 15 *pfSqlType = -9
[940]describeCol: col 15  *pcbColDef = 80
[940]describeCol: col 15  *pibScale = 0
[940][SQLDescribeColW][940]PGAPI_DescribeCol: entering.9..
[940]PARSE: DescribeCol: icol=8, stmt=43230000, stmt->nfld=35, stmt->fi=43196648
[940]DescribeCol: getting info for icol=8
[940]PARSE: fieldtype=25, col_name='responses', column_size=8190
[940]describeCol: col 8 fieldname = 'responses'
[940]describeCol: col 8 fieldtype = 25
[940]describeCol: col 8 column_size = 8190
[940]describeCol: col 8 *pfSqlType = -10
[940]describeCol: col 8  *pcbColDef = 8190
[940]describeCol: col 8  *pibScale = 0
[940]describeCol: col 8  *pfNullable = 1
...
[940][SQLBindCol][940]PGAPI_BindCol: entering...
[940]**** PGAPI_BindCol: stmt = 43230000, icol = 1
[940]**** : fCType=4 rgb=18a490 valusMax=4 pcb=16de88
[940]extend_getdata_info: entering ... self=43230348, gdata_allocated=17, num_columns=18
[940]exit extend_gdata_info
[940]       bound buffer[17] = 1614992
[940][SQLBindCol][940]PGAPI_BindCol: entering...
[940]**** PGAPI_BindCol: stmt = 43230000, icol = 2
[940]**** : fCType=1 rgb=12d564 valusMax=1 pcb=cc008
[940]extend_getdata_info: entering ... self=43230348, gdata_allocated=6, num_columns=7
[940]exit extend_gdata_info
[940]       bound buffer[6] = 1234276
[940]**** PGAPI_BindCol: stmt = 43230000, icol = 3
[940]**** : fCType=1 rgb=18a574 valusMax=16 pcb=16e088
[940]extend_getdata_info: entering ... self=43230348, gdata_allocated=20, num_columns=21
[940]exit extend_gdata_info
[940]       bound buffer[20] = 1615220


Start your day with Yahoo! - make it your home page --0-338261555-1121971848=:54154--