CF and Oracle 9i: INSERT INTO table_a ... RETURNING ID INTO variable_a
Posted on 2004-10-04
The question of getting the new ID after INSERT keeps popping up in forums but my question is very specific. I don't need any workarounds like MAX(ID), sequences, triggers, timestamps, etc.
Here is my question:
Does ColdFusion(6.1)/JRun4/JDBC support this specific Oracle 9i extension to SQL and, if it does, what is the CF syntax of doing it:
Trigger and sequence are used to generate a new ID value
Oracle 9i SQL:
INSERT INTO table_a (name, address) VALUES ('Bob', '100 Main st') RETURNING ID INTO v_variable_id