[sqlite] Escape table and column names

2012-05-16 Thread marco
Hello, I would like to receive a definitive answer about what is the recommended way to escape table and column names. SQLite supports single quotes, double quotes and square brackets (for mySQL compatibility) … but I haven't yet found the official or recommended way. Anyone have an answer? What

Re: [sqlite] Escape table and column names

2012-05-16 Thread Petite Abeille
On May 16, 2012, at 12:28 PM, ma...@sqlabs.net ma...@sqlabs.net wrote: Anyone have an answer? http://www.sqlite.org/lang_keywords.html What about if table name or column name contains that escape character? Do I need to escape it in another way? http://sqlite.org/faq.html#q14

Re: [sqlite] Escape table and column names

2012-05-16 Thread Jean-Christophe Deschamps
What about if table name or column name contains that escape character? Do I need to escape it in another way? http://sqlite.org/faq.html#q14 This FAQ topic doesn't apply here. We're talking about schema names or keywords, while FAQ#14 is literal escaping a single quote. Given that we

Re: [sqlite] Escape table and column names

2012-05-16 Thread Simon Slavin
On 16 May 2012, at 11:56am, Petite Abeille petite.abei...@gmail.com wrote: On May 16, 2012, at 12:28 PM, ma...@sqlabs.net ma...@sqlabs.net wrote: Anyone have an answer? http://www.sqlite.org/lang_keywords.html What about if table name or column name contains that escape character? Do

Re: [sqlite] Escape table and column names

2012-05-16 Thread Baruch Burstein
On Wed, May 16, 2012 at 2:25 PM, Simon Slavin slav...@bigfraud.org wrote: On 16 May 2012, at 11:56am, Petite Abeille petite.abei...@gmail.com wrote: On May 16, 2012, at 12:28 PM, ma...@sqlabs.net ma...@sqlabs.net wrote: Anyone have an answer?

Re: [sqlite] Escape table and column names

2012-05-16 Thread Petite Abeille
On May 16, 2012, at 1:15 PM, Jean-Christophe Deschamps wrote: This FAQ topic doesn't apply here. We're talking about schema names or keywords, while FAQ#14 is literal escaping a single quote. create table foobar ( baz ); select * from onetwo; select * from sqlite_master;

Re: [sqlite] Escape table and column names

2012-05-16 Thread Jean-Christophe Deschamps
This FAQ topic doesn't apply here. We're talking about schema names or keywords, while FAQ#14 is literal escaping a single quote. create table foobar ( baz ); select * from onetwo; select * from sqlite_master; table|foobar|foobar|9|CREATE TABLE foobar ( baz ) I knew this particular

Re: [sqlite] Escape table and column names

2012-05-16 Thread Baruch Burstein
On Wed, May 16, 2012 at 2:47 PM, Jean-Christophe Deschamps j...@antichoc.net wrote: This FAQ topic doesn't apply here. We're talking about schema names or keywords, while FAQ#14 is literal escaping a single quote. create table foobar ( baz ); select * from onetwo; select * from

Re: [sqlite] Escape table and column names

2012-05-16 Thread Jay A. Kreibich
On Wed, May 16, 2012 at 01:47:01PM +0200, Jean-Christophe Deschamps scratched on the wall: This FAQ topic doesn't apply here. We're talking about schema names or keywords, while FAQ#14 is literal escaping a single quote. create table foobar ( baz ); select * from onetwo; select *

Re: [sqlite] Escape table and column names

2012-05-16 Thread Jean-Christophe Deschamps
At 13:55 16/05/2012, you wrote: ´¯¯¯ Those all work. You are getting an error because you didn't supply any column in the table `--- Oops, that's what happens when you try doing too many things at the same time. Nonetheless, SQLite version 3.7.11 2012-03-20 11:35:50 Enter .help for