RE: [sqlite] getting table column names and types programaticly
Pragma table_info(tablename). For God's name, do read the documentation, somebody spent good time to write it! > -Original Message- > From: Gerry Snyder [mailto:[EMAIL PROTECTED] > Sent: Friday, March 25, 2005 1:19 AM > To: sqlite-users@sqlite.org > Subject: Re: [sqlite] getting table column names and types > programaticly > > Jim Dodgen wrote: > > Anyone know how I can query the field names and types for a > given table? > > Jim, > > select sql from sqlite_master where type="table" and name="gigo" > > will get something like: > > create table gigo(a,b,c) > > which includes the field names, and would include the types > if I had used any. > > Gerry > > >
Re: [sqlite] getting table column names and types programaticly
> Anyone know how I can query the field names and types for a given table? pragma table_info(tablename)
Re: [sqlite] getting table column names and types programaticly
Jim Dodgen wrote: Anyone know how I can query the field names and types for a given table? Jim, select sql from sqlite_master where type="table" and name="gigo" will get something like: create table gigo(a,b,c) which includes the field names, and would include the types if I had used any. Gerry
[sqlite] getting table column names and types programaticly
Anyone know how I can query the field names and types for a given table?