Re: [sqlite] database AND table already exist?

2012-07-20 Thread Igor Tandetnik
Black, Michael (IS) wrote: > Good pointso probably time equivalent either way. Though table_info will > allow the feature creep of "does a column exist" > pretty easily. So would preparing a statement of the form "select ColumnToCheck from TableToCheck;" -- Igor

Re: [sqlite] database AND table already exist?

2012-07-20 Thread Black, Michael (IS)
] database AND table already exist? Black, Michael (IS) <michael.bla...@ngc.com> wrote: > table_info() will be faster than doing "select *" I would think in most all > cases. To check the existence of a table, you don't need to actually run the select statement - just prepare

Re: [sqlite] database AND table already exist?

2012-07-20 Thread Igor Tandetnik
Black, Michael (IS) wrote: > table_info() will be faster than doing "select *" I would think in most all > cases. To check the existence of a table, you don't need to actually run the select statement - just prepare it and check for errors. -- Igor Tandetnik

Re: [sqlite] database AND table already exist?

2012-07-20 Thread Black, Michael (IS)
ectorate Advanced GEOINT Solutions Operating Unit Northrop Grumman Information Systems From: sqlite-users-boun...@sqlite.org [sqlite-users-boun...@sqlite.org] on behalf of Arbol One [arbol...@gmail.com] Sent: Friday, July 20, 2012 5:51 AM To: SqLite Subject: EXT :[sqlite] database AND table alre

Re: [sqlite] database AND table already exist?

2012-07-20 Thread Simon Slavin
On 20 Jul 2012, at 11:51am, Arbol One wrote: > Is there a way to find out if a certain database AND table already exist? > > In my C++ program I would like to query SQLite3 to find out if a database > already exists and also if a particular table exists in that database. Is

Re: [sqlite] database AND table already exist?

2012-07-20 Thread Donald Griggs
Darn. I didn't mean to quote the table name: (though double quotes or brackets are alllowed). Sorry for the noise. SELECT 'anything' FROM MyTableInQuestion LIMIT 0; ___ sqlite-users mailing list sqlite-users@sqlite.org

Re: [sqlite] database AND table already exist?

2012-07-20 Thread Donald Griggs
On Fri, Jul 20, 2012 at 6:51 AM, Arbol One wrote: > Is there a way to find out if a certain database AND table already exist? > > I am using std i/o methods to check for the existing SQLite3 file > containing the database, ==> I think that's the standard method. but I

[sqlite] database AND table already exist?

2012-07-20 Thread Arbol One
Is there a way to find out if a certain database AND table already exist? In my C++ program I would like to query SQLite3 to find out if a database already exists and also if a particular table exists in that database. Is there a way to do this? I am using std i/o methods to check for the