Hi Anton,

Thanks for the ODBC trace which I have passed on to development of analysis.
My observation shows the following call sequences being the source of the
failure when using the Unicode driver which works with the ANSI driver:

python          B7DB26C0 ENTER SQLExecDirect
                SQLHSTMT          0x820f460
                SQLCHAR         * 0xb7daea34
                                  | SELECT RDF_QUAD_URI_L(?, ?, ?, ?)
|
                SQLINTEGER        -3 (SQL_NTS)

[000000.054939]
python          B7DB26C0 EXIT  SQLExecDirect with return code 0
(SQL_SUCCESS)
                SQLHSTMT          0x820f460
                SQLCHAR         * 0xb7daea34
                SQLINTEGER        -3 (SQL_NTS)

[000000.054996]
python          B7DB26C0 ENTER SQLNumResultCols
                SQLHSTMT          0x820f460
                SQLSMALLINT     * 0xbf90d02a

[000000.055029]
python          B7DB26C0 EXIT  SQLNumResultCols with return code 0
(SQL_SUCCESS)
                SQLHSTMT          0x820f460
                SQLSMALLINT     * 0xbf90d02a (1)

[000000.055063]
python          B7DB26C0 ENTER SQLRowCount
                SQLHSTMT          0x820f460
                SQLLEN          * 0xbf90d024

[000000.055098]
python          B7DB26C0 EXIT  SQLRowCount with return code 0 (SQL_SUCCESS)
                SQLHSTMT          0x820f460
                SQLLEN          * 0xbf90d024 (-1)

[000000.055134]
python          B7DB26C0 ENTER SQLDescribeCol
                SQLHSTMT          0x820f460
                SQLUSMALLINT      1
                SQLCHAR         * 0x0
                SQLSMALLINT       0
                SQLSMALLINT     * 0x0
                SQLSMALLINT     * 0x820f9d0
                SQLULEN         * 0x820f9d4
                SQLSMALLINT     * 0x0
                SQLSMALLINT     * 0x0

[000000.055208]
python          B7DB26C0 EXIT  SQLDescribeCol with return code -1
(SQL_ERROR)
                SQLHSTMT          0x820f460
                SQLUSMALLINT      1
                SQLCHAR         * 0x0
                SQLSMALLINT       0
                SQLSMALLINT     * 0x0
                SQLSMALLINT     * 0x820f9d0
                SQLULEN         * 0x820f9d4
                SQLSMALLINT     * 0x0
                SQLSMALLINT     * 0x0

[000000.055289]
python          B7DB26C0 ENTER SQLGetDiagRec
                SQLSMALLINT       3 (SQL_HANDLE_STMT)
                SQLHSTMT          0x820f460
                SQLSMALLINT       1
                SQLCHAR         * 0xbf90cf04
                SQLINTEGER      * 0xbf90cf14
                SQLCHAR         * 0xbf90cb04
                SQLSMALLINT       1023
                SQLSMALLINT     * 0xbf90cf1a

[000000.055365]
python          B7DB26C0 EXIT  SQLGetDiagRec with return code 0
(SQL_SUCCESS)
                SQLSMALLINT       3 (SQL_HANDLE_STMT)
                SQLHSTMT          0x820f460
                SQLSMALLINT       1
                SQLCHAR         * 0xbf90cf04
                                  | HY001
|
                SQLINTEGER      * 0xbf90cf14 (-1211302908)
                SQLCHAR         * 0xbf90cb04
                                  | [iODBC][Driver Manager]Memory allocation
|
                                  |  error
|
                SQLSMALLINT       1023
                SQLSMALLINT     * 0xbf90cf1a (46)

[000000.055471]

We have an idea as to the cause of the problem but need to check/test with
the pyodbc layer first to confirm. So I should have an update for you soon
...

Regards,
Hugh


On 4/4/07 00:52, "Anton Krasovsky" <anton_krasov...@yahoo.com> wrote:

> Hi Hugh,
> 
> please find trace files attached. First one is for
> pyodbc used with virtodbc32_r.so, second is for
> pyodbc with virtodbc32u_r.so.
> 
> The mxODBC driver seems to work okay with
> virtodbc32u_r.so, but it has problems working under
> python 2.5, so I'd like to see if pyodbc can be used
> with unicode version of virtuoso driver.
> 
> Regards,
> Anton
> 
> 
> --- Hugh Williams <hwilli...@openlinksw.com> wrote:
> 
>> Hi Anton,
>> 
>> Can you please provide an iODBC trace of your
>> attempts to insert unicode
>> data with the Virtuoso unicode driver
>> (virtodbc32u_r.so) with the mxODBC and
>> pyodbc drivers. The iODBC tracing can be enabled by
>> adding the following
>> entry to your odbc.ini file:
>> 
>> [ODBC]
>> Trace=1
>> TraceFile=<filename>
>> 
>> This will enable us to see where the Memory
>> Allocation error is occuring
>> during the attempt to insert the data and hopefully
>> to diagnose the cause of
>> the problem
>> 
>> Regards,
>> Hugh
>> 
>> 
>> On 2/4/07 23:39, "Anton Krasovsky"
>> <anton_krasov...@yahoo.com> wrote:
>> 
>>> Hi Hugh,
>>> 
>>> I tried to do some tests, and found that pyodbc
>> when
>>> used with virtodbc32u_r.so fails to execute any
>>> queries with error:
>>> 
>>>  "[HY001] [iODBC][Driver Manager]Memory allocation
>>> error (-1211581185)"
>>> 
>>> though it works for non-unicode queries with
>>> virtodbc32_r.so.
>>> 
>>> The mxODBC seem to work with virtodbc32u_r.so (at
>>> least for non-unicode queries) but it crashes when
>>> compiled for python25.
>>> 
>>> My intention would be to use pyodbc with Python
>> 2.5,
>>> so I'll try to have closer look at this, perhaps
>> I'll
>>> contact pyodbc maintainer.
>>> 
>>> Regards,
>>> Anton
>>> 
>>> --- Hugh Williams <hwilli...@openlinksw.com>
>> wrote:
>>> 
>>>> Hi Anton,
>>>> 
>>>> Can you please provide details on how you are
>>>> attempting to save these
>>>> unicode strings as RDF literals ?
>>>> 
>>>> From on OpenLink point of view both iODBC and the
>>>> Virtuoso ODBC driver
>>>> support unicode, although note for the Virtuoso
>> ODBC
>>>> Driver you need to
>>>> ensure you are using the virtodbc32u_r.so which
>> is
>>>> the Unicode variant of
>>>> this driver.
>>>> 
>>>> What I am not sure about is the unicode support
>>>> available in mxODBC or
>>>> pyodbc, thus do you know if either of these
>> drivers
>>>> support unicode ?
>>>> 
>>>> 
>>>> Best Regards,
>>>> Hugh Williams
>>>> Professional Services
>>>> OpenLink Software
>>>> Web: http://www.openlinksw.com
>>>> Universal Data Access & Data Integration
>> Technology
>>>> Providers
>>>> 
>>>> On 2/4/07 11:24, "Anton Krasovsky"
>>>> <anton_krasov...@yahoo.com> wrote:
>>>> 
>>>>> Hi,
>>>>> 
>>>>> yesterday I tried to do few simple tests saving
>>>> python
>>>>> unicode string as RDF literals in Virtuoso, but
>>>> with
>>>>> no success. So I wonder if there is any existing
>>>> guide
>>>>> on
>>>>> setting system up for Unicode support?
>>>>> 
>>>>> What db driver should I use mxODBC or pyodbc?
>>>>> What ODBC manager unixODBC or iODBC?
>>>>> What Virtuoso ODBC driver?
>>>>> 
>>>>> Regards,
>>>>> Anton
>>>>> 
>>>>> 
>>>>> 
>>>>> 
>>>>> 
>>>>>  
>>>>> 
>>>> 
>>> 
>> 
> ______________________________________________________________________________
>>>>> ______
>>>>> Finding fabulous fares is fun.
>>>>> Let Yahoo! FareChase search your favorite travel
>>>> sites to find flight and
>>>>> hotel bargains.
>>>>> 
>> http://farechase.yahoo.com/promo-generic-14795097
>>>>> 
>>>>> 
>>>> 
>>> 
>> 
> -------------------------------------------------------------------------
>>>>> Take Surveys. Earn Cash. Influence the Future of
>>>> IT
>>>>> Join SourceForge.net's Techsay panel and you'll
>>>> get the chance to share your
>>>>> opinions on IT & business topics through brief
>>>> surveys-and earn cash
>>>>> 
>>>> 
>>> 
>> 
> http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
>>>>> _______________________________________________
>>>>> Virtuoso-users mailing list
>>>>> Virtuoso-users@lists.sourceforge.net
>>>>> 
>>>> 
>>> 
>> 
> https://lists.sourceforge.net/lists/listinfo/virtuoso-users
>>>> 
>>>> 
>>>> 
>>>> 
>>>> 
>>> 
>>> 
>>> 
>>>  
>>> 
>> 
> ______________________________________________________________________________
>>> ______
>>> Food fight? Enjoy some healthy debate
>>> in the Yahoo! Answers Food & Drink Q&A.
>>> 
>> 
> http://answers.yahoo.com/dir/?link=list&sid=396545367
>>> 
>>> 
>> 
> -------------------------------------------------------------------------
>>> Take Surveys. Earn Cash. Influence the Future of
>> IT
>>> Join SourceForge.net's Techsay panel and you'll
>> get the chance to share your
>>> opinions on IT & business topics through brief
>> surveys-and earn cash
>>> 
>> 
> http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
>>> _______________________________________________
>>> Virtuoso-users mailing list
>>> Virtuoso-users@lists.sourceforge.net
>>> 
>> 
> https://lists.sourceforge.net/lists/listinfo/virtuoso-users
>> 
>> 
>> Best Regards,
>> Hugh Williams
>> VP Product Development
>> OpenLink Software
>> Tel: +44 (0) 8681 7701
>> Web: http://www.openlinksw.com
>> Universal Data Access & Data Integration Technology
>> Providers
>> 
>> 
>> 
> 
> 
> 
>  
> ______________________________________________________________________________
> ______
> Now that's room service!  Choose from over 150,000 hotels
> in 45,000 destinations on Yahoo! Travel to find your fit.
> http://farechase.yahoo.com/promo-generic-14795097
> -------------------------------------------------------------------------
> Take Surveys. Earn Cash. Influence the Future of IT
> Join SourceForge.net's Techsay panel and you'll get the chance to share your
> opinions on IT & business topics through brief surveys-and earn cash
> http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
> _______________________________________________
> Virtuoso-users mailing list
> Virtuoso-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/virtuoso-users


Best Regards,
Hugh Williams
VP Product Development
OpenLink Software
Tel: +44 (0) 8681 7701
Web: http://www.openlinksw.com
Universal Data Access & Data Integration Technology Providers



Reply via email to