是否有任何 oracle 函数等同于 mysql_query( set names 'utf8' )
Is there is any oracle function equivalent to mysql_query( set names 'utf8' )
我们正在使用 PHP 和 Oracle。
Connection string :
$connect_db = oci_connect($username, $password, $host_db, 'AL32UTF8');
也在 php 代码中。
header('Content-Type: text/html; charset=utf-8');
我的问题在 php 页面内,它被转换为区域语言。但是当它存储到 Oracle 数据库中时,它存储为 '¿¿¿¿¿¿'。
我们如何解决这个问题?
任何 Oracle 函数都可用,等同于 mysql_query( set names 'utf8' ).
以前我们在连接字符串中使用 UTF8 而不是 "AL32UTF8"。
我们可以使用这种格式
$connect_db = oci_connect($用户名, $密码, $host_db, 'AL32UTF8');
我们正在使用 PHP 和 Oracle。
Connection string :
$connect_db = oci_connect($username, $password, $host_db, 'AL32UTF8');
也在 php 代码中。
header('Content-Type: text/html; charset=utf-8');
我的问题在 php 页面内,它被转换为区域语言。但是当它存储到 Oracle 数据库中时,它存储为 '¿¿¿¿¿¿'。
我们如何解决这个问题? 任何 Oracle 函数都可用,等同于 mysql_query( set names 'utf8' ).
以前我们在连接字符串中使用 UTF8 而不是 "AL32UTF8"。
我们可以使用这种格式 $connect_db = oci_connect($用户名, $密码, $host_db, 'AL32UTF8');