FluentMigrator: More Schema Discord

Well alright, I’m finding more ways in which SQL Server schema differs from SQLite. I’m not really surprised; just learning how much. For instance, SQLite doesn’t support Foreign Keys, which is why the SQliteGenerator in FM throws a NotImplementedException when it tries to generate sql for Foreign Keys. Also, you can’t do a simple rename of a column in SQLite. You have to rename the table, create a new table with the new column name, copy the data from the old into the new, and then drop the old table.

So a quick web search found a couple articles on differences between sql server and sqlite: uno, dos. Chances are there will be more issues to address.

I’m not going to worry about it to much right now since I don’t need it. I just need to change the sample migration so the tests pass withthe SQLite generator. If we ever work on supporting mysql, there will be similar problems. Ultimately, you have to know at least a little about the database you are creating schema for.

-j

 
August 20, 2009 07:00 by josh
E-mail | Permalink
blog comments powered by Disqus


about josh

another programmer blogging about his misadventures in writing code.

Contact

contact us for website & software consulting

Decide

decide on pragmatic solutions

Develop

develop your product together

Succeed

achieve your goals with our services