i can set xml String to xmltype field with:

$sql_insert_sql = "insert into g_province

but if $xml_con too long,i can not set this content into xmltype fields.

then , i use :
//(tabel_name:articles)DDL; //just for test;
//create table articles (id number(11),content sys.xmltype);
//----------This is insert test---------------------------------- 
$conn = @OCILogon("in_user","user_in","bigfish");
$stmt = @OCIParse($conn,"insert into articles (id,content)
values(1,xmltype(EMPTY_CLOB())) RETURNING content INTO:CONTENT");
$clob = @OCINewDescriptor($conn,OCI_D_LOB);
if ($clob->save("<root><a>JUST TEST</a></root>")){
echo "Insert succes!";
echo "Insert default!";
//---------------Insert end-----------------------------------------
//---------------Select start---------------------------------------
$sql = "select content from articles order by id desc";
$stmt = @OCIParse($conn,$sql);
echo "<br>Content is:\"".$rows[0]."\"";
//---------------Select end-----------------------------------------

run it ,display these errors:

Warning: ociexecute(): OCIStmtExecute: ORA-22816: unsupported feature with
RETURNING clause in /home/www/bigfish/sgtest/testclob.php on line 12

Warning: save(): OCILobWrite: OCI_INVALID_HANDLE in
/home/www/bigfish/sgtest/testclob.php on line 13
Insert default!
Content is:""
Warning: Unknown(): _oci_close_session: OCISessionEnd: ORA-00600: internal
error code, arguments: [729], [28], [space leak], [], [], [], [], [] in
Unknown on line 0

how can i set long content to xmltype fields??

PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to