Index mysql_length does not work with column ames with spaces

Issue #3085 resolved
Iuri de Silvio created an issue

I have a Column 1 in MySQL database. I tried to define an index with:

mysql_length={'Column 1': 255}

It doesn't work. I have to add backticks to column name:

mysql_length={'`Column 1`': 255}

Comments (5)

  1. Mike Bayer repo owner
    • Fixed bug where column names added to mysql_length parameter on an index needed to have the same quoting for quoted names in order to be recognized. The fix makes the quotes optional but also provides the old behavior for backwards compatibility with those using the workaround. fixes #3085

    → <<cset a46932422b9b>>

  2. Mike Bayer repo owner
    • Fixed bug where column names added to mysql_length parameter on an index needed to have the same quoting for quoted names in order to be recognized. The fix makes the quotes optional but also provides the old behavior for backwards compatibility with those using the workaround. fixes #3085

    → <<cset 4bab5e97b1f4>>

  3. Mike Bayer repo owner
    • Fixed bug where column names added to mysql_length parameter on an index needed to have the same quoting for quoted names in order to be recognized. The fix makes the quotes optional but also provides the old behavior for backwards compatibility with those using the workaround. fixes #3085

    → <<cset 6f9a8034ca20>>

  4. Mike Bayer repo owner

    I don't even know why the API is like that, using column.key or the actual column would have been the better choice, using names is not really our style. not worth fixing at the moment...

  5. Log in to comment