Page 1 of 1

cmsmadesimple-1.2.2 and SQLite

Posted: Wed Dec 12, 2007 12:00 am
by fvdw
Hello, I'm a newbie in CMS Made Simple.
I'm installing CMS v1.2.2 using SQLite (linux server running XAMPP / PHP5).

1st problem : After install when I try to connect I hit a 404 error .... because I didn't specify an absolute path as dbname for my SQLite db. I suggest a (specific) message will be displayed when a SQLite DB is choose  [solved]

2nd Problem: I hit a php warning "Warning: sqlite_create_function() expects parameter 1 to be resource, null given in /my_site/lib/adodb.functions.php on line 80". I solved the problem by modifying the adodb.functions.php file on line ...80
// ::: Change this
// sqlite_create_function($config['use_adodb_lite'] ? $db->connectionId : $db->_connectionID, 'now', 'time', 0);
// ::: by
sqlite_create_function($config['use_adodb_lite'] ? $dbinstance->connectionId : $dbinstance->_connectionID, 'now', 'time', 0);
// ::: End change

Now it works [solved] too.

I'm not sure this topics sits at the right place... feel free to move it on a better location if needed.

Re: cmsmadesimple-1.2.2 and SQLite

Posted: Wed Dec 12, 2007 12:39 am
by calguy1000
we don't officially support sqlite anyways.

Re: cmsmadesimple-1.2.2 and SQLite

Posted: Wed Dec 12, 2007 1:54 pm
by cyberman
If you want to work with SQLite you should use AdoDB instead AdoDB lite.

Re: cmsmadesimple-1.2.2 and SQLite

Posted: Thu Dec 13, 2007 10:04 am
by kermit
calguy1000 wrote: we don't officially support sqlite anyways.

i would rather see sqlite officially supported; right down to creating the database during install.. as it will perform better than mysql for some folks.

but, if you're not going to support sqlite; then perhaps it should NOT even appear as a database option during install and it should be removed from the drivers directory or moved to an 'unsupported_drivers' directory (as should all others that are not used and/or will never be used) so people don't try to use it.. especially if it requires a different adodb version than what is included with cmsms in order for it to work properly.

getting rid of the unused clutter in adodb directory can probably reduce its footprint by 50% or more. if you can't just dump the junk, put it all into a separate archive 'unsupported.tar.gz' or something so at least you're "distributing" the entire library, but you are still making a clear distinction between what the project will support and what it will not.

Re: cmsmadesimple-1.2.2 and SQLite

Posted: Thu Dec 13, 2007 2:51 pm
by calguy1000
You sound an awful lot like a volunteer.

I can't wait to see your build scripts, and your installer diffs.

Re: cmsmadesimple-1.2.2 and SQLite

Posted: Thu Dec 13, 2007 6:31 pm
by Pierre M.
Hello kermit,
kermit wrote: i would rather see sqlite officially supported; right down to creating the database during install.. as it will perform better than mysql for some folks.
Can you please elaborate on this "better for some folks" ? Maybe I'm in those folks without knowing. (for example : can the db store be a regular file, easy to backup/copy, easy to restore/move ?)
Another question about CMSms and databases : isn't CMSms ADO(lite?) based ? doesn't ADO provide database agnosticism ?
kermit wrote: but, if you're not going to support sqlite; then perhaps it should NOT even appear as a database option during install and it should be removed from the drivers directory
I agree on this : the simpler, the lighter, the better. But I'm not a PHP dev and I can't help the dev team as Calguy has suggested to volunteer.

Have fun all with CMSms

Pierre

Re: cmsmadesimple-1.2.2 and SQLite

Posted: Thu Dec 13, 2007 8:04 pm
by cyberman
Pierre M. wrote: for example : can the db store be a regular file, easy to backup/copy, easy to restore/move ?)
Use sqlite and you will see - it works. As I said you have only to use AdoDB ful (not lite). Tried it with a local Xampp server ...