Am 12.03.2013 15:43, schrieb Michael Bayer:
I suppose the reflection could have some feature where you flag it as,
single unique key w/no primary key means that's the primary key, but
we've not had requests for this feature before.
We will at some point be adding a feature whereby one can
Am 11.03.2013 17:27, schrieb Michael Bayer:
OK well that table has no primary key established.
I see. So even if MySQL tells me (in 'show fields') that a column is a primary
key, SQLAlchemy won't recognize it unless the column is explicitely marked as
primary key (as opposed to a unique key).
On Mar 12, 2013, at 6:32 AM, Felix Schwarz felix.schw...@oss.schwarz.eu wrote:
Am 11.03.2013 17:27, schrieb Michael Bayer:
OK well that table has no primary key established.
I see. So even if MySQL tells me (in 'show fields') that a column is a primary
key, SQLAlchemy won't recognize
Hey,
I'm trying to use reflection with SQLAlchemy 0.8 but I always get this
exception:
sqlalchemy.exc.ArgumentError: Mapper Mapper|links|links could not assemble any
primary key columns for mapped table 'links'
mysql show fields from links;
can you send the SHOW CREATE TABLE, I'll copy it exactly
On Mar 11, 2013, at 9:59 AM, Felix Schwarz felix.schw...@oss.schwarz.eu wrote:
Hey,
I'm trying to use reflection with SQLAlchemy 0.8 but I always get this
exception:
sqlalchemy.exc.ArgumentError: Mapper Mapper|links|links could not
OK well that table has no primary key established.
If I create a table with a PK:
create table test (id integer primary key);
you see PRIMARY KEY in the output:
mysql show create table test;