Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 Extended StoredProcedures and Unicode

Author  Topic 

yanivib
Starting Member

8 Posts

Posted - 2003-03-24 : 09:51:35
Hi all,
I'm having hard time with this issue,
I wrote an Extended SP using the Visual C++ wizard.
The dll get a string in and return a string out.
All is working fine except the fact that the dll
convert any unicode string to ???.

It seems that the srv_paramdata allways return ??? when
i give the SP a unicode string.

I have allso tried working like this:
LPWSTR wcBuff=(LPWSTR)LocalAlloc(LPTR,((srv_paramlen
(srvproc,1)+1)*sizeof(WCHAR)));
MultiByteToWideChar(CP_ACP,0,(const char*)srv_paramdata
(srvproc, 1),
srv_paramlen(srvproc,1)+1,wcBuff,
(srv_paramlen(srvproc,1)+1)*sizeof(WCHAR));

but the wcBuff will have ??? where non english characters
apears..

Any help will be wellcomed,
Regards,
Yaniv
yaniv.inbar@retalix.com


   

- Advertisement -