-
Notifications
You must be signed in to change notification settings - Fork 18
Open
Description
Had a lot of challenges running this against a generic sqlite database I had but here are some things I found out that you may want to put on the readme... at least for me they were needed
- You MUST have xcode installed and command line tools as well.
- Name tables with schema name and no use of spaces or underscores. eg. main.CustomerRefunds
- Ensure no field on any table has a hyphen in the name. Underscores are ok. eg. first-name is NOT ok. first_name is ok.
- Ensure that lookup tables are broken up. You cannot have a relationship (FK) from one table to another MORE THAN ONCE. You must break that up into two separate table relationships. So for example, I tried to use a single table to hold all my lookup values and so what would happen is that one table might point to the lookup table using a currency foreign key, and a language fk as well. This will cause an error on this script. Break out language lists and currency lists to two tables then build the fk.
- When running sqlite2coredata you must supply the fully qualified path to the output directory right after you supply the database path.
- if you mark your id columns as AUTOINCREMENT, then SQLITE will generate a sequence table. Unfortunately, the table name is will not play well with the naming scheme this script expects. This will result in errors. So I just did not mark them as autoincrement.
I hope this helps someone.
Metadata
Metadata
Assignees
Labels
No labels