Re: [sqlite] Proper way to escape table name and column name

2011-06-07 Thread Paul Linehan
2011/6/6 Jean-Christophe Deschamps :

>>What is the official way to escape table name that contains a space
>>and column name that contain a spaces?

> You can use square brakets or double-quotes:

> [This is a long name for a small table]
> "This is a long name for a small table as well"


Or, what you can also do is use table names such as

no_special_chars

and/or

do_not_distinguish_between_caps_and_lower_case_in_designing_system

?


Paul...


-- 

lineh...@tcd.ie

Mob: 00 353 86 864 5772
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] Proper way to escape table name and column name

2011-06-06 Thread Richard Hipp
On Mon, Jun 6, 2011 at 6:14 AM, Jean-Christophe Deschamps
wrote:

>
> >What is the official way to escape table name that contains a space
> >and column name that contain a spaces?
>
> You can use square brakets or double-quotes:
>
> [This is a long name for a small table]
> "This is a long name for a small table as well"
>
>
Double-quotes is the official (portable) SQL way of quoting identifiers.
Square bracket quoting is provided by SQLite for compatibility with SQL
Server.


> ___
> sqlite-users mailing list
> sqlite-users@sqlite.org
> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
>



-- 
D. Richard Hipp
d...@sqlite.org
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] Proper way to escape table name and column name

2011-06-06 Thread Jean-Christophe Deschamps

>What is the official way to escape table name that contains a space 
>and column name that contain a spaces?

You can use square brakets or double-quotes:

[This is a long name for a small table]
"This is a long name for a small table as well"

___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


[sqlite] Proper way to escape table name and column name

2011-06-06 Thread Marco Bambini
What is the official way to escape table name that contains a space and column 
name that contain a spaces?
Thanks a lot.
--
Marco Bambini
http://www.sqlabs.com








___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users