The columns in tables are nvarchar. It was working fine with sybase ASE. (I
like ASE but what to do.)
I figured out that I have to execute sql statement with N prefix. Update X
set name=N'xxx'. I tried to modify all update and insert sql statements in
sqlpreview event but it does not work. Pb says datawindow has not update
capability.
I know if I use disablebind=0, I will solve the problem but a lot of
problems are coming with disablebind=0. For example if subqueries have
retrieve argument in datawindow, I get error 42000 and lost connection.
Is the situation is same in PB 11.5?
How can I solve this problem?
Thanks.
Can you tell us how you are connecting to SS2008 and the connection
parameters you are using?
--
Regards ... Chris
ISUG - NA RUG Director
http://chrispollach.pbdjmagazine.com
"Murat Yelkovan" <muraty...@yahoo.com> wrote in message
news:49c11bc8@forums-1-dub...
I dont know if there is a another easy sollution but I solved the problem by
typing following script to the sqlpreview event. It adds N prefix to the
sqlstatements. I could not use disablebind=0 because I am replicating data
to another database in the application so I need to get the sql statements
with value. I tried oledb and native connection in powerbuilder 11.5 but
there is a same problem. If we have to send sql statement with N prefix to
the SQL server for unicode data, Sybase PowerBuilder had better generate sql
statement with N prefix for MS Sql Server.
What do you think about my sollution and about enchantment request regarding
this issue?.
//SQLPREVIEW EVENT
n_cst_string lnv_string
if sqlca.database="mssql" then
choose case sqltype
case PreviewInsert!
sqlsyntax= lnv_string.of_globalreplace(sqlsyntax ,"( '", "( N'")
sqlsyntax= lnv_string.of_globalreplace(sqlsyntax ,",'", ",N'")
this.setsqlpreview(sqlsyntax)
case PreviewUpdate!, PreviewDelete!
sqlsyntax= lnv_string.of_globalreplace(sqlsyntax ,"= '","= N'")
this.setsqlpreview(sqlsyntax)
end choose
end if
//This is my connection string;
ODBC=create n_tr_odbc
ODBC.DBMS = "OLE DB"
ODBC.AutoCommit = False
ODBC.DBPARM =
"PROVIDER='SQLNCLI10',DATASOURCE='KEDI-PC\MSSQL',PROVIDERSTRING='database=vinn_local',CommitOnDisconnect='No',OJSyntax='ANSI'"
"Chris Pollach" <cpol...@travel-net.com> wrote in message
news:49c227c5$1@forums-1-dub...
--
Paul Horan[Sybase]
paulhoran.pbdjmagazine.com
"Murat Yelkovan" <muraty...@yahoo.com> wrote in message
news:49c257d9@forums-1-dub...