Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 129923
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T05:52:00+00:00 2026-05-11T05:52:00+00:00

I have an export SQL file containing tables and data from MySQL and I

  • 0

I have an export SQL file containing tables and data from MySQL and I want to import it into a Sqlite 3 DB.

What is the best way to do that?

Just importing the file via the sqlite3 tool doesn’t work.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. 2026-05-11T05:52:01+00:00Added an answer on May 11, 2026 at 5:52 am

    This shell script help you

    #!/bin/sh if [ 'x$1' == 'x' ]; then    echo 'Usage: $0 <dumpname>'    exit fi cat $1 | grep -v ' KEY '' | grep -v ' UNIQUE KEY '' | grep -v ' PRIMARY KEY ' | sed '/^SET/d' | sed 's/ unsigned / /g' | sed 's/ auto_increment/ primary key autoincrement/g' | sed 's/ smallint([0-9]*) / integer /g' | sed 's/ tinyint([0-9]*) / integer /g' | sed 's/ int([0-9]*) / integer /g' | sed 's/ character set [^ ]* / /g' | sed 's/ enum([^)]*) / varchar(255) /g' | sed 's/ on update [^,]*//g' | perl -e 'local $/;$_=<>;s/,\n\)/\n\)/gs;print 'begin;\n';print;print 'commit;\n'' | perl -pe '   if (/^(INSERT.+?)\(/) {      $a=$1;      s/\\'\''/'\'\''/g;      s/\\n/\n/g;      s/\),\(/\);\n$a\(/g;   }   ' > $1.sql cat $1.sql | sqlite3 $1.db > $1.err ERRORS=`cat $1.err | wc -l` if [ $ERRORS == 0 ]; then   echo 'Conversion completed without error. Output file: $1.db'   rm $1.sql   rm $1.err     rm tmp else    echo 'There were errors during conversion.  Please review $1.err and $1.sql for details.' fi 
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 121k
  • Answers 121k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer Lists (as well as vectors and maps) are not a… May 12, 2026 at 12:29 am
  • Editorial Team
    Editorial Team added an answer Right-click in the File System tab, click "Add Special Folder"… May 12, 2026 at 12:29 am
  • Editorial Team
    Editorial Team added an answer Yes, and the flow does return to the spin method.… May 12, 2026 at 12:29 am

Related Questions

After reading through many of the questions here about DB schema migration and versions,
I have an Oracle database backup file (.dmp) that was created with expdp .
I've been beating myself over the head with this app migration for a few
I have an access database, with a query made. I need to automate it

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.