TD 5.1, MS SQL Server via ODBC and umlauts

General discussion forum about all databases other than SqlBase.
lars

TD 5.1, MS SQL Server via ODBC and umlauts

Post by lars » 01 Apr 2008, 14:15

I found out that there is a problem selecting data from a MS SQL Server (2005) when there is an umlaut in a constant search condition like in the example below.

When running this function against MS Sql Server, the result ist 'niente'. The same against SQLBase ends with 'yeah'.


!!CB!! 134
Function: fInsertAndSelectUmlaut
Description:
Returns
Parameters
Static Variables
Local variables
Sql Handle: hSql
Number: nFetch
Actions
Set SqlDatabase = 'uml'
Call SqlConnect( hSql )
Call SqlPrepareAndExecute( hSql, 'insert into tabelle (nchar) values (\'ü\')' )
Call SqlCommit( hSql )
Call SqlPrepareAndExecute( hSql, 'select nchar from tabelle where nchar=\'ü\' ' )
If not SqlFetchNext( hSql, nFetch )
Call SalMessageBox( 'nada', 'niente', 0 )
Else
Call SalMessageBox( 'that´s the way I like it', 'yeah', 0 )
Call SqlDisconnect( hSql )



Table definition MS Sql Server:
CREATE TABLE [dbo].[tabelle](
[nchar] [nchar](10) NULL
) ON [PRIMARY]


SQLBase:
sysadm.tabelle: nachar char(10)

jmccall

Re: TD 5.1, MS SQL Server via ODBC and umlauts

Post by jmccall » 01 Apr 2008, 19:32

You have posted this in the "Bugs" forum but how much investigation have you done to be sure it's a bug? You don't say anything about what you have tried or what settings are used. In the ODBC data source setting is "Perform translation for character data" checked (on the standard Windows XP ODBC manager this is on the last page of the configuratation wizard). Also, what code page is in use on the table?

lars

Re: TD 5.1, MS SQL Server via ODBC and umlauts

Post by lars » 01 Apr 2008, 19:45

what else should i do rather than use SQLWindows, put a statement to insert data, than another to fetch data in the same way, just one line below the other statement as it was inserted and to see that it doesn´t work.
My investigation :-) when i use the same odbc dsn connection with another frontant - other than Unify: it works fine.
So just tell me, what else I should do for testing - I will do it.

<edit>
have a look at the hardcopies attached. there you can see the difference between TD 5.1 and TD 3.1 on the same computer with the same database and same odbc and same code.

and please solutions but no discussions. thank you - also in the name of my customers who are waitung for a working application.
You do not have the required permissions to view the files attached to this post.

jinva

Re: TD 5.1, MS SQL Server via ODBC and umlauts

Post by jinva » 02 Apr 2008, 14:24

Maybe you have the same problem as in this topic:
Team Developer - Team Developer 5.1 - unicode retrieval from SqlServer
https://support.guptatechnologies.com/su ... bind#p3128

Then using bind variable could help - or waiting for SP2.

jmccall

Re: TD 5.1, MS SQL Server via ODBC and umlauts

Post by jmccall » 02 Apr 2008, 14:32

lars wrote:what else should i do rather than use SQLWindows, put a statement to insert data, than another to fetch data in the same way, just one line below the other statement as it was inserted and to see that it doesn´t work.
Check to see whether it was the insert of the select that failed. What value is stored in the table?
lars wrote:So just tell me, what else I should do for testing - I will do it.
How about the suggestions in my first response - ODBC character translation setting and the table's code page?
lars wrote:and please solutions but no discussions. thank you - also in the name of my customers who are waitung for a working application.
This isn't a solutions or discussions forum, it's for reporting bugs (which this might not be). I have a feeling I know what's going on and I'd like to have known for sure because it will affect me when I upgrade to 5.1. If anyone else can be bothered to help you I hope we all hear about the solution.

lars

Re: TD 5.1, MS SQL Server via ODBC and umlauts

Post by lars » 02 Apr 2008, 15:21

jinva wrote:Maybe you have the same problem as in this topic:
Team Developer - Team Developer 5.1 - unicode retrieval from SqlServer
https://support.guptatechnologies.com/su ... bind#p3128

Then using bind variable could help - or waiting for SP2.

Thank you, this is reading very similar to my problem. So let´s hope for SP2 to come out .......... yesterday? sorry. me kidding :lol:

lars

Re: TD 5.1, MS SQL Server via ODBC and umlauts

Post by lars » 10 Apr 2008, 00:46

SP2: works fine now :D

Return to “General Discussion”

Who is online

Users browsing this forum: [Ccbot] and 3 guests