How extract pure sequences from an Oracle DB?

From: Date: Mon, 18 Sep 2000 15:03:23 +0000
Subject: How extract pure sequences from an Oracle DB?
Groups: php.db 
Request: Send a blank email to php-db+get-2947@lists.php.net to get a copy of this message
<?php ... $sel_seq_sql="SELECT EDIPRO_SEQ.NEXTVAL ID_EDIPRO FROM DUAL"; $cur_seq= OCIParse ($conn, $sel_seq); OCIDefineByName ($cur_seq, "ID_EDIPRO", &$id_edipro,-1); ... OCIExecute ($cur_seq,OCI_DEFAULT); // this is line 56 OCIFetch ($cur_seq); // this is line 57 ... ?> connections is an OCILogon and Oracle server is up. All goes on with normal queries, but I receive following errors select from sequences: Running this piece of PHP, I receive following error: /home/httpd/html/privati//bianco_xxx.php on line 56 Warning: OCIFetch: OCI_INVALID_HANDLE in /home/httpd/html/privati//bianco_xxx.php on line 57 Warning: OCIStmtExecute: ORA-24337: statement handle not prepared in /home/httpd/html/privati//bianco_xxx.php on line 56 Warning: OCIFetch: OCI_INVALID_HANDLE in /home/httpd/html/privati//bianco_xxx.php on line 57 Warning: OCIStmtExecute: ORA-00001: unique constraint Is over there a workaround for this? Thanks in advance to everyone for your answers. Ciao Roberto

« previous php.db (#2947) next »