On 04/13/2016 07:50 AM, Piotr Dobrogost wrote:
Mike,

Thanks for your reply!

On Wednesday, April 13, 2016 at 1:15:32 PM UTC+2, Mike Bayer wrote:

    We've not started supporting new oracle 12c features as of yet, in
    this case it might be possible to get it working with some dialect
    flags since we already use "returning" to get at the newly generated
    primary key, although testing would be needed and other assumptions
    in the dialect might get in the way.


Which flags do you have in mind? Looking at
http://docs.sqlalchemy.org/en/latest/dialects/oracle.html I don't see
anything which might be useful to make it work.

they're module level flags on the dialect class itself like "postfetch_lastrowid" and "preexecute_autoincrement_sequences"


I was surprised Oracle needs different syntax with explicit sequence in
SA. Having one syntax for auto increment column (primary key) across all
backends seems like very important feature to have.  What is the reason
there's no Oracle dialect option to generate and use suitable sequence
for such column? Is there some recipe solving this problem?

Oracle (and Firebird) is the only database backend that until 12c did not provide any mechanism for auto-incrementing integer primary key columns. SQLAlchemy doesn't want to get in the business of inventing an opinionated system for this. We don't ever dictate any details about how the schema is to be designed.






Regards,
Piotr Dobrogost

--
You received this message because you are subscribed to the Google
Groups "sqlalchemy" group.
To unsubscribe from this group and stop receiving emails from it, send
an email to sqlalchemy+unsubscr...@googlegroups.com
<mailto:sqlalchemy+unsubscr...@googlegroups.com>.
To post to this group, send email to sqlalchemy@googlegroups.com
<mailto:sqlalchemy@googlegroups.com>.
Visit this group at https://groups.google.com/group/sqlalchemy.
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups 
"sqlalchemy" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sqlalchemy+unsubscr...@googlegroups.com.
To post to this group, send email to sqlalchemy@googlegroups.com.
Visit this group at https://groups.google.com/group/sqlalchemy.
For more options, visit https://groups.google.com/d/optout.

Reply via email to