in reply to Re: Perl DBI can't display Chinese text?
in thread Perl DBI can't display Chinese text?
In my compute, chinese display well in x.log. In print text(cmd), there is such info as follows:Unicode login6 dbname=SQLSERVER2008R2, uid='sa', pwd=xxxxx SQLDriverConnect 'SQLSERVER2008R2', ''sa'', 'xxxx' SQLDriverConnectW failed: SQLConnect ''SQLSERVER2008R2'', ''sa'' !!dbd_error2(err_rc=1, what=db_login6sv/SQLConnectW, handles=(26a8 +398,20caeb0,0) !SQLError(26a8398,20caeb0,0) = (01000, 5701, [Microsoft][SQL Serve +r Native Client 10.0][SQL Server]ӑ½«˽¾ݿ㊏f +6;τ¸�'ECISAN_JX'¡£) !SQLError(26a8398,20caeb0,0) = (01000, 5703, [Microsoft][SQL Serve +r Native Client 10.0][SQL Server]ӑ½«ԯҔʨ׃ +¸�¼󍦖юġ£) Turning autocommit on DRIVER_ODBC_VER = 03.52 DRIVER_NAME = sqlncli10.dll, type=2 DRIVER_VERSION = 10.50.4000 MAX_COLUMN_NAME_LEN = 128 DBD::ODBC is unicode built : YES SQLMoreResults supported: 1 SQLDescribeParam supported: 1 !!DBD::ODBC unsupported attribute passed (PrintError) setting AutoCommit !!DBD::ODBC unsupported attribute passed (Username) !!DBD::ODBC unsupported attribute passed (dbi_connect_closure) initializing sth query timeout to -1 ignore named placeholders = 0 SQLPrepare select top 1000 name,create_date from sys.objects where + type = 'U' and charindex('t_',name) > 0 order by create_date Processing non-utf8 sql in unicode mode SQLPrepare = 0 initializing sth query timeout to -1 ignore named placeholders = 0 SQLPrepare select name,deptcode from t_department Processing non-utf8 sql in unicode mode SQLPrepare = 0 +dbd_st_execute(2683be4) dbd_st_finish(2683be4) outparams = 0 SQLExecute/SQLExecDirect(20c6630)=0 SQLRowCount=0 (rows=-1) SQLNumResultCols=0 (flds=2) dbd_describe done_desc=0 dbd_describe SQLNumResultCols=0 (columns=2) DescribeCol column = 1, name = n, namelen = 4, type = VARCHAR(12), + precision/column size = 50, scale = 0, nullable = 0 SQL_COLUMN_DISPLAY_SIZE = 50 SQL_COLUMN_LENGTH = 50 now using col 1: type = UNICODE CHAR (-8), len = 102, display siz +e = 102, prec = 50, scale = 0 DescribeCol column = 2, name = d, namelen = 8, type = VARCHAR(12), + precision/column size = 10, scale = 0, nullable = 0 SQL_COLUMN_DISPLAY_SIZE = 10 SQL_COLUMN_LENGTH = 10 now using col 2: type = UNICODE CHAR (-8), len = 22, display size + = 22, prec = 10, scale = 0 -dbd_describe done_bind=0 have 2 fields -dbd_st_execute(2683be4)=-1 bind_columns fbh=2716b94 fields=2 Bind 1: type = UNICODE CHAR(-8), buf=2180494, buflen=102 Bind 2: type = UNICODE CHAR(-8), buf=21804fc, buflen=22 bind_columns=0 SQLFetch=0 fetch num_fields=2 fetch col#1 n datalen=8 displ=102 SQL_C_WCHAR data = "临床科室" fetch col#2 d datalen=2 displ=22 SQL_C_WCHAR data = '1' SQLFetch=0 fetch num_fields=2 ... ...
What's the question key?Wide character in print at E:\temp\DBI_HG_Study_20130912\ConnectSQL +Server.pl line 122.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Perl DBI can't display Chinese text?
by graff (Chancellor) on Oct 15, 2013 at 01:55 UTC | |
|
Re^3: Perl DBI can't display Chinese text?
by mje (Curate) on Oct 15, 2013 at 09:33 UTC |