>So can the stored procedure return a field as a different datatype to the one stored?
Yes!
>How is this conversion handled?
Explicitly using using CONVERT (although CAST can also be used)
>Can you ensure that the varchar is encoded as utf-8 and not using a codepage?
You can also specify an explicit collating sequence using COLLATE
The existing table will need to be changed from VARCHAR to NVARCHAR
Click "Mark as Answer" on the post that helped you.
This earns you a point and marks your thread as Resolved so we will all know you have been helped.
FAQ on the correct forum http://forums.asp.net/p/1337412/2699239.aspx#2699239
TATWORTH
All-Star
72415 Points
14017 Posts
MVP
Re: utf-8 in database varchar
May 22, 2007 06:47 AM|LINK
>So can the stored procedure return a field as a different datatype to the one stored?
Yes!
>How is this conversion handled?
Explicitly using using CONVERT (although CAST can also be used)
>Can you ensure that the varchar is encoded as utf-8 and not using a codepage?
You can also specify an explicit collating sequence using COLLATE
The existing table will need to be changed from VARCHAR to NVARCHAR
This earns you a point and marks your thread as Resolved so we will all know you have been helped.
FAQ on the correct forum http://forums.asp.net/p/1337412/2699239.aspx#2699239