關於在 asp 中使用 ADODB 時, 在使用 unicode 時要特別注意的地方:
1. ado connection 直接下sql command 時, 若有 Unicode 字元時, 要加上 N, 如
Conn.execute “Insert into test (f1) values (N’陶喆’)”
Conn.execute “Select * from test where f1 like N’%喆%’”
2. ado recordset 新增資料時, 就直接給定值即可, 沒有 unicode 問題, 如
Rs.open “select * from test where 1=2”, conn, 3, 3
Rs.AddNew
Rs(“f1”)=”陶喆”
Rs.Update
另外參考微軟資料: http://support.microsoft.com/default.as ... -tw;239530