Re: DB_DataObject not creating tables
| From: | Larry Garfield | Date: | Wed, 19 Jan 2005 22:36:11 +0000 |
| Subject: | Re: DB_DataObject not creating tables | ||
| References: | 1 2 3 4 5 6 7 8 | Groups: | php.pear.general |
| Request: | Send a blank email to pear-general+get-17025@lists.php.net to get a copy of this message | ||
Justin Patrin wrote:
Oh yeah...what DB backend are you using? It may not work with some (SQLite, etc).MySQL. Well I went in and put a lot of debugging lines into createTables.php, and finally managed to track down the problem. My config file had specified paths for the schema location and class location that were relative to my home directory, i.e., ~/public_html/myproject/. I'd completely forgotten that you can't leave ~ unquoted, so it was returning a string of -1 for the schema_location and freaking out with a useless error. I tried quoting the string, "~/public_html/myproject/", and ended up with a directory called "~" in the directory where createTables.php was, inside which was public_html, inside which was myproject, inside which was DataObjects. :-) I finally gave in and just hard coded the name of my home directory, and it worked fine. I just upgraded back to 4.3.10 (with the define statement still in place), and it still worked fine. So the moral of the story is that ini files (or at least as used by DB_DataObject) DON'T LIKE ~! :-) *sigh* Thanks for your help, Justin. I should probably go submit a bug on the weird error message, and perhaps the documentation so that they can mention this. -- Larry Garfield AIM: LOLG42 larry@garfieldtech.com ICQ: 6817012 "If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea, which an individual may exclusively possess as long as he keeps it to himself; but the moment it is divulged, it forces itself into the possession of every one, and the receiver cannot dispossess himself of it." -- Thomas Jefferson