Re: [sqlite] mysql -> sqlite problem
> On Dec 19, 2019, at 4:49 PM, Mike Bentley wrote: > > Is it true that "Each index name must be unique in the database"? Yes. You're right that the docs don't seem to spell this out, but since the syntax to delete an index is "DROP INDEX ", you couldn't have multiple indexes with the same name because it wouldn't know which one to delete. You can pretty easily get a unique index name by prefixing the name of the table. —Jens ___ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
[sqlite] mysql -> sqlite problem
I used two different mysql to sqlite conversion tools to do test conversions. One tool is written in python and is called mysql-to-sqlite, and the other in awk called mysql2sqlite, both available via github. The one in python ran into an error and stopped very early in the process. The one in awk ran into a couple problems but completed. If I use a sqlite database inspector, the tables look like I expect. The error message generated by the python converter: 100%|██| 1/1 [00:00<00:00, 724.15it/s] 2019-12-19 10:26:55 ERRORSQLite failed creating table adm_table: index id_column already exists index id_column already exists The column name "id_column" turns out to be used alot as a unique key in many tables in the mysql db. The author of the tool points out: https://stackoverflow.com/questions/27238178/duplicate-index-on-sqlite-not-on-mysql where we encounter a phrase similar to "Each index name must be unique in the database". I've searched the internet for the above and variants; it shows up on techonthenet.com in sqlite tutorials and a couple other places. It does not appear to show up on sqlite.org, tho. Is it true that "Each index name must be unique in the database"? I was able to use the output of the qwk script to create an inspectable sqlite database without the process generating complaints about named indexes already existing. Thanks! -Mike ___ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users