At 3:26 PM -0500 10/8/04, Freeman, Michael wrote:
Also, another weird error is that if I specify the full path to the
database and I have DBI->trace(1); on, it says it can't connect to the
database. Without the full path, It just says the trapdlog doesn't
exist..

I was going to bring this up too, but the other problem was more glaring.

When you do not give a full path, then SQLite will look in your current working directory for the database file.

If you are running your program from a shell prompt, then you need to first cd into the directory that contains your database file before running your script.

If you are running your program as a web application / CGI script, then your current working directory is probably whatever actual folder corresponds to the web address you invoked to run the program; unless this is where your database file is (and it shouldn't be, for security reasons), then giving an unqualified filename won't work.

Your current working directory when running your script is probably different than the one your database is in, hence your problem. Using full paths gets around this because then it doesn't matter what your cwd is.

-- Darren Duncan

Reply via email to