Probably you should use the $db->lastSequenceId($sequenceName) method.
See
http://framework.zend.com/manual/en/zend.db.html#zend.db.adapter.write.l
astinsertid
Regards,
Bill Karwin
________________________________
From: Svetlin Petrov [mailto:[EMAIL PROTECTED]
Sent: Thursday, June 14, 2007 3:17 AM
To: [email protected]
Subject: [fw-general] Zend_DB Oracle adapter
Hi,
I need to execute query like this one:
INSERT INTO deal
(name, deal_type)
VALUES
(:name, :deal_type)
RETURNING
id
INTO
:id
If I do not use Zend Framework, I do the following:
$stmt = oci_parse($_conn, $sql);
oci_bind_by_name($stmt, ":name", $name, 32);
oci_bind_by_name($stmt, ":deal_type", $deal_type, 32);
oci_bind_by_name($stmt, ":id", $id, -1, SQLT_INT);
oci_execute($stmt);
My question is: is there an way to do this inside Zend
Framework?
Thanks!
Svetlin Tsvetanov
--
http://www.spetrov.com