in reply to Re^2: create SQLite database problems
in thread create SQLite database problems

I am unclear on what you mean by "when I go to the SQLite3 procedure". Can you expand on that, please?

In my example, after the perl script runs, I used the sqlite3 command line tool to connect to the database that was created. That's where I saw the tables and schema.

Replies are listed 'Best First'.
Re^4: create SQLite database problems
by fionbarr (Friar) on Mar 06, 2012 at 20:03 UTC
    sorry, I was not clear...I meant the sqlite3 command line tool.

      What directory are you in when connecting to the sqlite3 database? What command are you using to connect to said database?

      I changed the path to the database file like so: my $database = "/Users/collin/Db/code_review.db";

      Then:

      kryten:scripts collin$ pwd /Users/collin/scripts
      And to connect to the database via sqlite3:
      kryten:scripts collin$ sqlite3 /Users/collin/Db/code_review.db SQLite version 3.7.7 2011-06-25 16:35:41 Enter ".help" for instructions Enter SQL statements terminated with a ";" sqlite> .tables depot review reviewer sqlite> .schema CREATE TABLE depot (change_num INTEGER PRIMARY KEY, depot VARCHAR(50) ); CREATE TABLE review (key INTEGER PRIMARY KEY, submitter VARCHAR(50), director VARCHAR(50), change_num INTEGER, action VARCHAR(20), time DATE ); CREATE TABLE reviewer (change_num INTEGER PRIMARY KEY, reviewed_by VARCHAR(50) ); CREATE TRIGGER INS_TIMEENTER AFTER INSERT ON REVIEW BEGIN UPDATE REVIEW SET TIME = DATETIME('NOW','LOCALTIME') WHERE ROWID = NEW.ROWID; END;