Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: PHP MySQL Sqlite
Hey Folks,
I am new to PHP. I want to convert a MYSQL database into .sqlite using PHP code. Can anyone offer me a solutions regarding it?
Posted 23-Sep-12 23:58pm
Edited 23-Sep-12 23:59pm
v2
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

Here's a list of converters.
  Permalink  
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 3

I finally found its solution.
Save sh file available at
https://gist.github.com/943776
and execute
"`./mysql2sqlite.sh DBNAME --databases DBNAME -u DB_USERNAME -pDB_PASSWORD | sqlite3 database.sqlite`"(without qoutes and with "`")
in php file.
Save both files in one folder
  Permalink  
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 4

Hi Every one,
 
I have tried but this script was not working as well.
 
I have also copy the both file in same folder and after executing PHP file than a blank sqlite file.
 
Could you please provide me another better way to execute this script and convert Mysql database into sqlite file.
 
Thanks,
Sam
  Permalink  
Comments
AakashGupta at 6-Dec-12 5:13am
   
What was the error you getting?
try running that stand alone script in terminal.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 Sergey Alexandrovich Kryukov 518
1 OriginalGriff 459
2 ChintanShukla 305
3 Richard Deeming 250
4 RyanDev 210
0 Sergey Alexandrovich Kryukov 8,901
1 OriginalGriff 7,571
2 CPallini 2,603
3 Richard MacCutchan 2,095
4 Abhinav S 1,893


Advertise | Privacy | Mobile
Web04 | 2.8.140827.1 | Last Updated 5 Dec 2012
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100