On 12/4/08, Julian Bui <[EMAIL PROTECTED]> wrote: > Hi all, > > I can't seem to use fully qualified table names (dbName.tableName). > > For instance, I create a database file inventory.db, and create a table > food. "SELECT * FROM inventory.food" does not work, nor does "SELECT * FROM > inventory.db.food" bc it says "no such table ...". Since there is no > CREATE DATABASE statement, I'm wondering what qualifies as a database in > sqlite. I expect it to be the name of the database file.
You are inside a database (inventory.db). Once inside it, its name doesn't matter (by inside, I mean, you have opened the db in the sqlite3 shell, or you have connected to the database have have a db handle to work with). You say "SELECT * FROM food" and you get your food. Couldn't be simpler. Once in the db, you ATTACH another db. In that case you can use the name of the ATTACHed db. See the syntax in the docs. > > This seems like a simple question, and I bet I'm just being a bonehead. > Please help me out. > > Thanks, > jb > _______________________________________________ > sqlite-users mailing list > sqlite-users@sqlite.org > http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users > -- Puneet Kishor http://www.punkish.org/ Nelson Institute for Environmental Studies http://www.nelson.wisc.edu/ Open Source Geospatial Foundation (OSGeo) http://www.osgeo.org/ _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users