pg.ddx.io  pgsql-odbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
PostgreSQL ODBC 8.04.0200 and Crystal Reports XI Developer
3+ messages / 2 participants
[nested] [flat]

* PostgreSQL ODBC 8.04.0200 and Crystal Reports XI Developer
@ 2010-10-04 22:02  Raiford@labware.com
  0 siblings, 1 reply; 3+ messages in thread

From: Raiford@labware.com @ 2010-10-04 22:02 UTC (permalink / raw)
  To: pgsql-odbc

Hi everyone, 

Before I explain my problem I want to mention that this is a critical 
issue for me.  If this is not the correct forum for resolving this issue 
in the driver, please point me to the proper place.

Whenever I try to use Crystal Reports with PostgreSQL ODBC, I get an error 
"logon failed".  There is not much available on this error online and no 
real solution that I'm aware of.  When I compare the ODBC trace and the 
mylog log files (shown below), you will see that the problem is that 
something is telling the Postgres driver to connect again.  If that wasn't 
weird enough, in the connection information, instead of using the correct 
database name, its telling it to use a database name that matches the 
datasource name.  I suppose I might be able to trick it by naming my 
database the same as the datasource, but that isn't a good generic 
solution.

Jon



My environment info:
Crystal Reports 11 Developer Edition
Postgres ODBC Driver Version='08.04.0200,200912260001' linking 1500 static 
Multithread library
Postgres Server version=8.4.4


Here is what I see using ODBC Tracing.  This is the only thing that 
appears in the SQL log when I tell Crystal to use my existing ODBC 
connection.  I have shortened the format to make it readable.  If you want 
anything that isn't listed, I can provide the rest:

SQLGetInfoW  ( 6 <SQL_DRIVER_NAME> ) -> return code 0 (SQL_SUCCESS)  -> 
"PSQLODBC35W.DLL"
SQLGetInfoW  ( 6 <SQL_DRIVER_NAME> ) -> return code 0 (SQL_SUCCESS)  -> 
"PSQLODBC35W.DLL"
SQLGetInfoW  (14 <SQL_SEARCH_PATTERN_ESCAPE> ) -> return code 0 
(SQL_SUCCESS)  ->  "\"
SQLGetInfoW  (17 <SQL_DBMS_NAME> ) -> return code 0 (SQL_SUCCESS)  -> 
"PostgreSQL"
SQLGetInfoW  (18 <SQL_DBMS_VER> ) -> return code 0 (SQL_SUCCESS)  -> 
"8.4.4"
SQLGetInfoW  (77 <SQL_DRIVER_ODBC_VER> ) -> return code 0 (SQL_SUCCESS) -> 
"03.51"
SQLGetInfoW  (10 <SQL_ODBC_VER> ) -> return code 0 (SQL_SUCCESS)  -> 
"03.52.0000"
SQLGetInfoW  (29 <SQL_IDENTIFIER_QUOTE_CHAR> ) -> return code 0 
(SQL_SUCCESS)  -> """
SQLGetInfoW  (41 <SQL_CATALOG_NAME_SEPARATOR> ) -> return code 0 
(SQL_SUCCESS)  -> "."
SQLGetInfoW  (114 <SQL_CATALOG_LOCATION> ) -> return code 0 (SQL_SUCCESS) 
-> PTR  0x07A58700 (1)
SQLGetInfoW  (10003 <SQL_CATALOG_NAME> ) -> return code 0 (SQL_SUCCESS) -> 
"Y"
SQLGetInfoW  (21 <SQL_PROCEDURES>) -> return code 0 (SQL_SUCCESS) -> "Y"
SQLGetInfoW (10021 <SQL_ASYNC_MODE>) -> return code 0 (SQL_SUCCESS) -> PTR 
 0x07A58754 (0)
SQLGetInfoW (115 <SQL_OJ_CAPABILITIES>) -> with return code 0 
(SQL_SUCCESS) -> PTR  07A58758
SQLGetInfoW (84 <SQL_FILE_USAGE>) -> with return code 0 (SQL_SUCCESS) -> 
PTR  0x07A5875C (0)
SQLGetInfoW (39 <SQL_OWNER_TERM>) -> with return code 0 (SQL_SUCCESS) -> 
"schema"
SQLGetInfoW (74 <SQL_CORRELATION_NAME>) -> with return code 0 
(SQL_SUCCESS) -> PTR  0x0012D8C8 (2)

Here is what I get in the mylog_1736.log (unaltered):

[3596-77.711][[SQLAllocHandle]][3596-77.711]**** in PGAPI_AllocEnv ** 
[3596-77.711]** exit PGAPI_AllocEnv: phenv = 08ABC6C0 **
[3596-77.711][[SQLSetEnvAttr]] att=200,3
[3596-77.711][[SQLAllocHandle]][3596-77.711]PGAPI_AllocConnect: 
entering...
[3596-77.711]**** PGAPI_AllocConnect: henv = 08ABC6C0, conn = 08ACA008
[3596-77.711]EN_add_connection: self = 08ABC6C0, conn = 08ACA008
[3596-77.711]       added at i=2, conn->henv = 08ABC6C0, conns[i]->henv = 
08ABC6C0
[3596-77.711][SQLGetInfoW(30)][3596-77.711]PGAPI_GetInfo: 
entering...fInfoType=77
[3596-77.711]PGAPI_GetInfo: p='03.51', len=0, value=0, cbMax=12
[3596-77.711][SQLSetConnectAttrW][3596-77.711]PGAPI_SetConnectAttr for 
08ACA008: 115 00000000
[3596-77.711]the application is unicode
[3596-77.711][SQLSetConnectAttrW][3596-77.711]PGAPI_SetConnectAttr for 
08ACA008: 101 00000001
[3596-77.711]PGAPI_SetConnectOption: entering fOption = 101 vParam = 1
[3596-77.711][SQLSetConnectAttrW][3596-77.711]PGAPI_SetConnectAttr for 
08ACA008: 111 076421B8
[3596-77.721]PGAPI_SetConnectOption: entering fOption = 111 vParam = 
124002744
[3596-77.721][SQLDriverConnectW][3596-77.721]PGAPI_DriverConnect: 
entering...
[3596-77.721]**** PGAPI_DriverConnect: fDriverCompletion=0, 
connStrIn='DSN=6 Base Postgres;UID=postgres;PWD=xxxx;DATABASE=6 Base 
Postgres;'
[3596-77.721]our_connect_string = 'DSN=6 Base 
Postgres;UID=postgres;PWD=xxxx;DATABASE=6 Base Postgres;'
[3596-77.721]attribute = 'DSN', value = '6 Base Postgres'
[3596-77.721]copyAttributes: DSN='6 Base 
Postgres',server='',dbase='',user='',passwd='xxxxx',port='',onlyread='',protocol='',conn_settings='',disallow_premature=-1)
[3596-77.721]attribute = 'UID', value = 'postgres'
[3596-77.721]copyAttributes: DSN='6 Base 
Postgres',server='',dbase='',user='postgres',passwd='xxxxx',port='',onlyread='',protocol='',conn_settings='',disallow_premature=-1)
[3596-77.721]attribute = 'PWD', value = 'xxxxx'
[3596-77.721]copyAttributes: DSN='6 Base 
Postgres',server='',dbase='',user='postgres',passwd='xxxxx',port='',onlyread='',protocol='',conn_settings='',disallow_premature=-1)
[3596-77.721]attribute = 'DATABASE', value = '6 Base Postgres'
[3596-77.721]copyAttributes: DSN='6 Base Postgres',server='',dbase='6 Base 
Postgres',user='postgres',passwd='xxxxx',port='',onlyread='',protocol='',conn_settings='',disallow_premature=-1)
[3596-77.721]getDSNinfo: DSN=6 Base Postgres overwrite=0
[3596-77.721]rollback_on_error=1
[3596-77.721]force_abbrev=0 bde=0 cvt_null_date=0
[3596-77.721]globals.extra_systable_prefixes = 'dd_;'
[3596-77.721]our_connect_string = 'DSN=6 Base 
Postgres;UID=postgres;PWD=xxxx;DATABASE=6 Base Postgres;'
[3596-77.721]attribute = 'DSN', value = '6 Base Postgres'
[3596-77.721]copyCommonAttributes: 
A7=100;A8=4096;A9=0;B0=255;B1=8190;B2=1;B3=0;B4=0;B5=1;B6=0;B7=1;B8=0;B9=1;C0=0;C1=0;C2=dd_;[3596-77.731]attribute 
= 'UID', value = 'postgres'
[3596-77.731]copyCommonAttributes: 
A7=100;A8=4096;A9=0;B0=255;B1=8190;B2=1;B3=0;B4=0;B5=1;B6=0;B7=1;B8=0;B9=1;C0=0;C1=0;C2=dd_;[3596-77.731]attribute 
= 'PWD', value = 'xxxxx'
[3596-77.731]copyCommonAttributes: 
A7=100;A8=4096;A9=0;B0=255;B1=8190;B2=1;B3=0;B4=0;B5=1;B6=0;B7=1;B8=0;B9=1;C0=0;C1=0;C2=dd_;[3596-77.731]attribute 
= 'DATABASE', value = '6 Base Postgres'
[3596-77.731]copyCommonAttributes: 
A7=100;A8=4096;A9=0;B0=255;B1=8190;B2=1;B3=0;B4=0;B5=1;B6=0;B7=1;B8=0;B9=1;C0=0;C1=0;C2=dd_;[3596-77.731]calling 
getDSNdefaults
[3596-77.731]CC_connect: entering...
[3596-77.731]sslmode=prefer
[3596-77.731]LIBPQ_CC_connect: entering...
[3596-77.731]Driver Version='08.04.0200,200912260001' linking 1500 static 
Multithread library
[3596-77.731]LIBPQ_CC_connect: DSN = '6 Base Postgres', server = 
'vm-postgres', port = '5432', database = '6 Base Postgres', username = 
'postgres', password='xxxxx'
[3596-77.731]connecting to the database  using vm-postgres as the server
[3596-77.731]sizeof connectdb option = 106
[3596-77.751]CC_error_statements: self=08ACA008
[3596-77.751]CONN ERROR: func=LIBPQ_connect, desc='', errnum=101, 
errmsg='FATAL:  database "6 Base Postgres" does not exist
'
[3596-77.751]Could not establish connection to the database; LIBPQ 
returned -> FATAL:  database "6 Base Postgres" does not exist

[3596-77.761]SOCK_Destructor
[3596-77.761]CONN ERROR: func=PGAPI_DriverConnect, desc='Error from 
CC_Connect', errnum=101, errmsg='FATAL:  database "6 Base Postgres" does 
not exist
'
[3596-77.761][SQLGetDiagRecW][3596-77.761]PGAPI_GetDiagRec entering type=2 
rec=1
[3596-77.761]**** PGAPI_ConnectError: hdbc=08ACA008 <0>
[3596-77.761]enter CC_get_error
[3596-77.761]enter CC_create_errormsg
[3596-77.761]msg = 'FATAL:  database "6 Base Postgres" does not exist
'
[3596-77.761]exit CC_create_errormsg
[3596-77.761]exit CC_get_error
[3596-77.761]CC_get_error: status = 101, msg = #FATAL:  database "6 Base 
Postgres" does not exist
#
[3596-77.761]        szSqlState = '08001',len=50, szError='(null)'
[3596-77.761]PGAPI_GetDiagRec exiting 1
[3596-77.761][SQLGetDiagRecW][3596-77.761]PGAPI_GetDiagRec entering type=2 
rec=1
[3596-77.761]**** PGAPI_ConnectError: hdbc=08ACA008 <52>
[3596-77.761]enter CC_get_error
[3596-77.761]exit CC_get_error
[3596-77.761]CC_get_error: status = 101, msg = #FATAL:  database "6 Base 
Postgres" does not exist
#
[3596-77.761]        szSqlState = '(null)',len=50, szError='FATAL: 
database "6 Base Postgres" does not exist
'
[3596-77.761]PGAPI_GetDiagRec exiting 0
[3596-77.761][[SQLGetDiagFieldW]] Handle=(2,08ACA008) Rec=1 Id=8 
info=(0012B6D8,256)
[3596-77.761]PGAPI_GetDiagField entering 
rec=1[3596-77.761]PGAPI_GetDiagField exiting 0
[3596-77.761][[SQLGetDiagFieldW]] Handle=(2,08ACA008) Rec=1 Id=9 
info=(0012B6D8,256)
[3596-77.761]PGAPI_GetDiagField entering 
rec=1[3596-77.761]PGAPI_GetDiagField exiting 0
[3596-77.761][[SQLGetDiagFieldW]] Handle=(2,08ACA008) Rec=1 Id=10 
info=(0012B6D8,256)
[3596-77.761]PGAPI_GetDiagField entering 
rec=1[3596-77.761]PGAPI_GetDiagField exiting 0
[3596-77.761][[SQLGetDiagFieldW]] Handle=(2,08ACA008) Rec=1 Id=11 
info=(0012B6D8,256)
[3596-77.761]PGAPI_GetDiagField entering 
rec=1[3596-77.761]PGAPI_GetDiagField exiting 0
[3596-77.761][SQLGetDiagRecW][3596-77.761]PGAPI_GetDiagRec entering type=2 
rec=2
[3596-77.761]**** PGAPI_ConnectError: hdbc=08ACA008 <0>
[3596-77.761]PGAPI_GetDiagRec exiting 100
[3596-77.761][[SQLFreeHandle]][3596-77.761]PGAPI_FreeConnect: entering...
[3596-77.761]**** in PGAPI_FreeConnect: hdbc=08ACA008
[3596-77.761]enter CC_Destructor, self=08ACA008
[3596-77.761]in CC_Cleanup, self=08ACA008
[3596-77.761]after SOCK destructor
[3596-77.761]exit CC_Cleanup
[3596-77.761]after CC_Cleanup
[3596-77.771]after free statement holders
[3596-77.771]exit CC_Destructor
[3596-77.771]PGAPI_FreeConnect: returning...
[3596-77.771][[SQLFreeHandle]][3596-77.771]**** in PGAPI_FreeEnv: env = 
08ABC6C0 ** 
[3596-77.771]in EN_Destructor, self=08ABC6C0
[3596-77.771]exit EN_Destructor: rv = 1
[3596-77.771]   ok

^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: PostgreSQL ODBC 8.04.0200 and Crystal Reports XI Developer
@ 2010-10-08 11:50  Jan-Peter.Seifert@gmx.de
  parent: Raiford@labware.com
  0 siblings, 1 reply; 3+ messages in thread

From: Jan-Peter.Seifert@gmx.de @ 2010-10-08 11:50 UTC (permalink / raw)
  To: Raiford@labware.com; pgsql-odbc

Hello,

you don't happen to have a semicolon within your password?
This obviously cuts the connection string sent by the PGAPI used by Crystal Reports.
Try an ODBC DSN without spaces.
Does the test connection via the configuration dialogue of the DSN work?

Good luck,

Peter

-------- Original-Nachricht --------
> Datum: Mon, 4 Oct 2010 18:02:21 -0400
> Von: Raiford@labware.com
> An: pgsql-odbc@postgresql.org
> Betreff: PostgreSQL ODBC 8.04.0200 and Crystal Reports XI Developer

> Hi everyone, 
> 
> Before I explain my problem I want to mention that this is a critical 
> issue for me.  If this is not the correct forum for resolving this issue 
> in the driver, please point me to the proper place.
> 
> Whenever I try to use Crystal Reports with PostgreSQL ODBC, I get an error
> "logon failed".  There is not much available on this error online and no 
-- 
GMX DSL Doppel-Flat ab 19,99 &euro;/mtl.! Jetzt auch mit 
gratis Notebook-Flat! http://portal.gmx.net/de/go/dsl



^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: PostgreSQL ODBC 8.04.0200 and Crystal Reports XI Developer
@ 2010-10-08 14:06  Raiford@labware.com
  parent: Jan-Peter.Seifert@gmx.de
  0 siblings, 0 replies; 3+ messages in thread

From: Raiford@labware.com @ 2010-10-08 14:06 UTC (permalink / raw)
  To: Jan-Peter.Seifert@gmx.de; +Cc: pgsql-odbc; pgsql-odbc-owner@postgresql.org

Hi Peter,

I'm not sure exactly what is going on, but I found that once I installed 
Crystal 2008 the problem went away.  Its surprising that there was nothing 
in the ODBC trace for the driver connect.  Maybe Crystal is trying to be 
"smart" and talking to the driver directly instead of issuing normal ODBC 
calls?  Regardless, now I have the fun game of seeing what's different so 
I can update our runtime files install. :)

Jon




From:   Jan-Peter.Seifert@gmx.de
To:     Raiford@labware.com, pgsql-odbc@postgresql.org
Date:   10/08/2010 07:50 AM
Subject:        Re: [ODBC] PostgreSQL ODBC 8.04.0200 and Crystal Reports 
XI Developer
Sent by:        pgsql-odbc-owner@postgresql.org



Hello,

you don't happen to have a semicolon within your password?
This obviously cuts the connection string sent by the PGAPI used by 
Crystal Reports.
Try an ODBC DSN without spaces.
Does the test connection via the configuration dialogue of the DSN work?

Good luck,

Peter

-------- Original-Nachricht --------
> Datum: Mon, 4 Oct 2010 18:02:21 -0400
> Von: Raiford@labware.com
> An: pgsql-odbc@postgresql.org
> Betreff: PostgreSQL ODBC 8.04.0200 and Crystal Reports XI Developer

> Hi everyone, 
> 
> Before I explain my problem I want to mention that this is a critical 
> issue for me.  If this is not the correct forum for resolving this issue 

> in the driver, please point me to the proper place.
> 
> Whenever I try to use Crystal Reports with PostgreSQL ODBC, I get an 
error
> "logon failed".  There is not much available on this error online and no 

-- 
GMX DSL Doppel-Flat ab 19,99 &euro;/mtl.! Jetzt auch mit 
gratis Notebook-Flat! http://portal.gmx.net/de/go/dsl

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

^ permalink  raw  reply  [nested|flat] 3+ messages in thread


end of thread, other threads:[~2010-10-08 14:06 UTC | newest]

Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2010-10-04 22:02 PostgreSQL ODBC 8.04.0200 and Crystal Reports XI Developer Raiford@labware.com
2010-10-08 11:50 ` Jan-Peter.Seifert@gmx.de
2010-10-08 14:06   ` Raiford@labware.com

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox