-
Notifications
You must be signed in to change notification settings - Fork 142
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Characters outside ASCII range not queryable by prepared statement on varchar column #83
Comments
Thank you for creating this issue. I need to think about this problem before I consider your fix. Alex |
Shouldn't varchar(200) be nvarchar(200) here? Alex |
If nvarchar is used, everything works correctly. But the column is on a legacy table so I can't change the column type to nvarchar easily. |
I do not see how I can help you here. I do not know enough about storing Chinese in varchar columns. I am not even sure it is possible. Alex |
It seems storing Chinese in varchar column depends on the server code page setting. Workarounds for others encountering the same issue: cast varchar column to nvarchar in the query, e.g. |
I do not know enough about this matter. Maybe others will help you here. I did test (on windows and linux) that #82 does not help this issue. Alex |
Thanks for the nice package though, it helps so much in my daily work! |
same problem for cp1251 codepage - varchar columns not converted to unicode and transferred to &interface{} variable as []byte in cp1251 codepage (but i waiting for utf8) |
SQL Server 2000
Test table:
Go program:
The text was updated successfully, but these errors were encountered: