meraki-analytics/cassiopeia-datastores

Missing length on Strings for MySQL

RobertBeilich opened this issue · 3 comments

MySQL requires a length for varchar and sqlalchemy does not seem to provide a default, so it's needed to provide a length for all strings

needs to be fixed here:

or am I missing something?

Sorry for the late response. I'm currently looking at this issue.

There seems to be the same problem for Numeric keys here:

Column("0-10", Numeric),
Column("10-20", Numeric),
Column("20-30", Numeric),
Column("30-end", Numeric),

as the default values don't seem to fit and lead to truncated values.

I will test the sqlstore on mysql a bit more and see if more changes need to be made for it to function properly. I've only tested it with postgresql yet. Will open a PR later today with all nessesary changes.
If you find any more problems while using mysql let me know.

Just opened the PR. It includes various small fixes for mysql.
You can install it after it got merged directly from github:
pip install -e 'git+https://github.com/meraki-analytics/cassiopeia-datastores#egg=cassiopeia-sqlstore&subdirectory=cassiopeia-sqlstore'
If you find any more bugs, let me know.

thanks, it's working now (=