On 15 Dec 2009, at 3:00am, FrankLane wrote:
> Hi - I ran across a php script where the data file was created in /tmp, so I
> tried that, and it works!
Just be aware that it may be deleted when that computer is rebooted. That's
what /tmp is for.
> I found some errors in my insert command,
> b
Hi - I ran across a php script where the data file was created in /tmp, so I
tried that, and it works! I found some errors in my insert command,
basically they were differences in insert as opposed to reading a
tab-delimited file as I was doing in sqlite3. For example, two commas are
interpreted
Frank,
I think you might get things done faster if you take a step back from your own
application and try to get a simpler PHP application working. You need to
learn how the PDO system works and also what it takes to get Apache to store
data on your computer.
Test it command by command: make
On 13 Dec 2009, at 7:15pm, FrankLane wrote:
> Well, I have such a file that I created, because with out it, I would get an
> error that reads:
>
> SQLSTATE[HY000] [14] unable to open database file
>
> So I created a junk.sqlite file and I got
>
> SQLSTATE[HY000] [10] disk I/O error
>
> so I
Hmmm
Well, I have such a file that I created, because with out it, I would get an
error that reads:
SQLSTATE[HY000] [14] unable to open database file
So I created a junk.sqlite file and I got
SQLSTATE[HY000] [10] disk I/O error
so I changed permissions using chmod 777 junk.sqlite and th
On 13 Dec 2009, at 5:45pm, FrankLane wrote:
> Hi Simon - I don't know how to access the database created by my php program,
The database is whatever file you specified when you created the database:
try { $dbHandle = new PDO('sqlite:'."/Users/me/junk.sqlite"); }
So your database file is the fi
Hi Simon - I don't know how to access the database created by my php program,
but I did put an echo after the definition of the command used by exec:
$i = 0;
while ($i <= 5)
{
$valuesSeparatedByCommas = preg_replace('/\t/', ',', $data2[$i]);
$sqlcmd = 'INSERT INTO tab (i0,i1,i2,i3,i4,t0,ID0,
On 13 Dec 2009, at 10:18am, FrankLane wrote:
> After the loop that inserts the data
> into the databease,
I would like to be sure that your INSERT commands work correctly. Once you
have executed the code that puts data in the database, please open the same
database in the command-line tool (s
Hi - The $valuesSeparatedByCommas worked fine, but I am still having problems
executing a command on the database - After the loop that inserts the data
into the databease, I'm using the following code to try to execute an sqlite
commmand:
$sth = $dbHandle->prepare("select * from tab where i0=2")
On 13 Dec 2009, at 5:27am, FrankLane wrote:
> $data3 = preg_split('/\t/',$data2[$i]); // tab delimited record data into
> array
>
> $sqlcmd = 'INSERT INTO tab (i0) VALUES ('.$data3[0].')';
Good so far. Now you should know that a normal SQL command to insert a record
would look something li
Well, Im getting closer. I can't seem to get the query function right.
Running the following program gives:
The first record is 1 0 0 0 0 BUSI @TOWB.1@ Ernest Blacksmith Shop
INSERT INTO tab (i0) VALUES (1)
INSERT INTO tab (i0) VALUES (1)
INSERT INTO tab (i0) VALUES (1)
INSERT INTO tab (i0) VALUE
On 12 Dec 2009, at 5:36pm, FrankLane wrote:
> I have a tab-delimited file that contains all my data, and I would like to
> write a php program which displays on a web page the results of various
> sqlite operations on a table created from that data. I still do not
> understand how to load the fil
Hello Simon - Thank you for your response. I think its clear that I am just
learning php, and I appreciate your help on very basic problems I am having.
I have a tab-delimited file that contains all my data, and I would like to
write a php program which displays on a web page the results of variou
On 12 Dec 2009, at 5:09am, FrankLane wrote:
Thank you for pasting your code fragment. It makes it easier to help you.
If you have your code check the results of '->errorCode' (and depending on that
'->errorInfo') you will get information about whether each command executed
correctly and what
Hello - I am trying to learn how to write a php program that uses sqlite
commands. I use the following file named hist.php to try to load a database,
but I get the error (on the fetch() line near the bottom, I assume)
Fatal error: Call to a member function fetch() on a non-object in
/Library/Web
hello i want to use php_sqlite.dll in php 4.3, i make this :
- i'm working in Win XP pro with IIS
- put the php_sqlite.dll in c:\php
- edit the php.ini, i change the "extension_dir" to c:\php
- restart the iis
but when i load a page with sqlite i've an error can load module
php_sqlite.dll...
i'v
16 matches
Mail list logo