Re: [sqlite] Altering a table when field(column) names are unknown

2006-07-25 Thread John Newby
PROTECTED]> To: sqlite-users@sqlite.org Sent: Monday, July 24, 2006 5:29:16 AM Subject: [sqlite] Altering a table when field(column) names are unknown http://www.sqlite.org/faq.html#q13 Hi, the above link goes to an FAQ on the SQLite website stating that the ALTER TABLE command has limited functionalit

Re: [sqlite] Altering a table when field(column) names are unknown

2006-07-24 Thread Clark Christensen
knowing both the old and new schemas. -Clark - Original Message From: John Newby <[EMAIL PROTECTED]> To: sqlite-users@sqlite.org Sent: Monday, July 24, 2006 5:29:16 AM Subject: [sqlite] Altering a table when field(column) names are unknown http://www.sqlite.org/faq.html#q13 Hi,

Re: [sqlite] Altering a table when field(column) names are unknown

2006-07-24 Thread Jens Miltner
Am 24.07.2006 um 15:09 schrieb Martin Jenkins: This is all good when the fields(columns) are known in advance, but how would I attempt doing this without knowing the name of the fields? You need to recast your problem into one where the field names ARE known. ;) Just issue a "pragma table

Re: [sqlite] Altering a table when field(column) names are unknown

2006-07-24 Thread Martin Jenkins
This is all good when the fields(columns) are known in advance, but how would I attempt doing this without knowing the name of the fields? You need to recast your problem into one where the field names ARE known. ;) Just issue a "pragma table_info(table_name)" as shown below in an sqlite shell

[sqlite] Altering a table when field(column) names are unknown

2006-07-24 Thread John Newby
http://www.sqlite.org/faq.html#q13 Hi, the above link goes to an FAQ on the SQLite website stating that the ALTER TABLE command has limited functionality and recommends creating a temp table and copying everything there, dropping the original table, re-creating it with the desired changes and cop