Hi guys, sorry for the vague subject, here is my problem. Let's say I
have the following table:

a = Table('aaa', meta,
  Column('id', Integer, primary_key=True),
  Column('id2', Integer))

class A(object):
  pass

mapper(A, a)

I want the default value of A.id2 to be that of a A.id. So, for
example, unless I modify it, I would like the A.id2 to be sort of a
duplicate primary key. I know I can find out what is A.id after
committing my object to database and then setting A.id2 accordingly,
but I was wondering can SA do this automatically for me? Maybe some
kind of a special `default=` construct in the Column call?

Thanks,
Karlo.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"sqlalchemy" group.
To post to this group, send email to sqlalchemy@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/sqlalchemy?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to