开发者

Convert SQL to SQLite in an easy way? [closed]

开发者 https://www.devze.com 2023-02-02 03:38 出处:网络
开发者_JAVA百科It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical andcannot be reasonably answered in its current form.
开发者_JAVA百科 It's difficult to tell what is being asked here. This question is ambiguous, vague, incomplete, overly broad, or rhetorical and cannot be reasonably answered in its current form. For help clarifying this question so that it can be reopened, visit the help center. Closed 12 years ago.

My question: has someone a super-easy way to convert a SQL-file in SQLite?


Okay, now it's a little clearer: You want to take an existing MySQL file and translate it into its SQL Lite equivalent.

There are two parts to this process:

  1. Translate the DDL from one SQL database to another (DDL == "Data Definition Language")
  2. Migrate data from one schema to another.

Every SQL vendor starts with ANSI SQL and adds in their own proprietary syntax. So you'll have to create a SQL Lite schema (tables, columns, indexes, etc) from the MySQL definition.

The data migration process is called ETL ("Extract-Transform-Load"). You might have to massage some of that data from MySQL to get it into SQL Lite.

The best scenario would be to export your MySQL data into a .csv file, create the table in SQL Lite, then import the .csv file.

0

精彩评论

暂无评论...
验证码 换一张
取 消