[unixODBC-dev] SQLConfigDataSource

Igor Korot ikorot at earthlink.net
Wed Nov 30 21:57:48 GMT 2005


Hi, ALL,
After reviewing the code I found out following:

Function "SQLConfigDataSource()" is declared in the file unixODBC/odbcinst/SQLConfigDataSource.c as follows:

BOOL SQLConfigDataSource(	HWND hWnd, WORD nRequest, LPCSTR pszDriver, /* USER FRIENDLY NAME (not file name) */ LPCSTR	pszAttributes );

Now my question/concern is: I always thought that the type 'HWND' is Windows only. What I should cast it to on Linux/UNIX?

I think this is my problem, because the system can't make a conversion to the proper type and, therefore, failing to call a function properly. And since its not NULL, it gaves me an error instead of silently disappear...

Thank you in advance.


-----Original Message-----
From: Igor Korot <ikorot at earthlink.net>
Sent: Nov 29, 2005 5:38 PM
To: Nick Gorham <nick at lurcher.org>
Cc: Development issues and topics for unixODBC <unixodbc-dev at easysoft.com>
Subject: Re: [unixODBC-dev] SQLConfigDataSource

You mean re-compile unixODBC with debug information? Or my program?
Please advise that my program is co0mpiled with the debug info and I was able to step into the SQLDrivers.
Unfortunately I am not able to step into SQLConfigDataSource using gdb, and when I look the strace.log, I couldn't find anything that consists phrase "SQL"...

Thank you.

-----Original Message-----
From: Nick Gorham <nick at lurcher.org>
Sent: Nov 28, 2005 11:54 PM
To: Igor Korot <ikorot at earthlink.net>
Subject: Re: [unixODBC-dev] SQLConfigDataSource

Igor Korot wrote:

>Hi, ALL,
>I just tried to see if there was a string "SQL" in the trace.log. Editor didn't find such string...
>But I know I linked the app with the libraries. I saw that they have been loaded. I use "-lodbcinst -lodbc".
>Maybe the problem is that I idn't link he main application with those libraries, but link only ".so" file, that was using the unixODBC functions?
>Coul someboy clarify, please?
>
>  
>
Best way, is to add debug to the source (you have the source to all the 
driver manager parts) untill you find where its failing.

-- 

Nick




More information about the unixODBC-dev mailing list