Documenations on MSEnum incorrect

Issue #1108 resolved
Former user created an issue

The documentation at http://www.sqlalchemy.org/docs/05/types.html#types_dialect has a bad example of how to use MSEnum() which will not work.

from sqlalchemy.databases.mysql import MSEnum, MSBigInteger

table = Table('foo', meta,
    Column('enumerates', MSEnum('a', 'b', 'c')),
    Column('id', MSBigInteger)
)

should be

from sqlalchemy.databases.mysql import MSEnum, MSBigInteger

table = Table('foo', meta,
    Column('enumerates', MSEnum("'a'", "'b'", "'c'")),
    Column('id', MSBigInteger)
)

Comments (2)

  1. Log in to comment