⚠ In case you've missed it we are migrating to our new website, with a brand new forum. For more details about the migration you can read our blog post for website migration. This forum is read-only and soon will be archived. ⚠


SQLite ?

sqlite

  • Please log in to reply
4 replies to this topic

#1 redl

redl

    Newbie

  • Members
  • Pip
  • 1 posts

Posted 10 January 2012 - 12:36 AM

Hi ! I just discovered your fabulous work ! It's really awesome !

I was wondering if it would be possible to port that to work with SQLite databases ? I had a quick look at the source, but I guess this is a bit over my level...

I know it is more difficult to get SQLite's databases metadata, but even with less functionality, your script would be very useful !

Thanks !

#2 steveoc

steveoc

    Member

  • Members
  • PipPip
  • 22 posts

Posted 10 January 2012 - 03:48 AM

grocery_CRUD is built on top of CodeIgniter ... which in turn provides the actual database drivers for a range of different DBs - including SQLite.

If you edit
application/config/database.php

and set the appropriate line to sqllite, it should work !
(should be line 55)

$db['default']['dbdriver'] = 'sqllite';

According to the doco, it should also work with :
['dbdriver'] The database type. ie: mysql. Currently supported: mysql, mysqli, postgre, odbc, mssql, sqlite, oci8

Having said that, there are several internal database calls that grocery_CRUD uses to determine the layout of tables and types of fields - any one of these _may_ be a source of incompatibility, but it does look OK from here. (Havent actually tried to use SQLLite yet)

Have a read of this thread for more info on what may be needed to get it working thoroughly with other databases :
http://www.grocerycr...__fromsearch__1

Try that and let us know how it goes.

#3 web-johnny

web-johnny

    grocery CRUD Author

  • Administrators
  • 1,166 posts

Posted 10 January 2012 - 07:44 AM

With SQLLite doesn't work completely.

You can though try to use the set_model function to use your custom model for sqllite, without changing the actual core of grocery_CRUD. There is still not anyone yet to have this model to send it to you or have a link of it.
And to create it, its really easy. Just follow the ERRORS :)

#4 wenkhairu

wenkhairu

    Member

  • Members
  • PipPip
  • 13 posts

Posted 10 January 2012 - 02:24 PM

I was wondering it will work great if we use some custom model in codeigniter, i have made it with SQLServer 2005 before, with some line of code in grocery_crud library it will work

#5 rolo2012

rolo2012

    Member

  • Members
  • PipPip
  • 12 posts

Posted 05 July 2012 - 06:48 PM

I made this model for sqlite3
http://www.grocerycr...rt-for-sqlite3/





Also tagged with one or more of these keywords: sqlite

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users