Re: [gnome-db] reserved words
- From: "Murray Cumming" <murrayc murrayc com>
- To: "Andrea Zagli" <azagli inwind it>
- Cc: gnome-db-list gnome org
- Subject: Re: [gnome-db] reserved words
- Date: Wed, 13 Sep 2006 11:13:10 +0200 (CEST)
> i think that each provider must have a function to properly escape
> reserved words in sql statements
>
> for example
>
> "create table values (id integer)" crash in mysql and sqlite (not in
> postgres) because "values" is an sql reserved word; the problem is that
> mysql and sqlite escape reserved words in different ways (mysql with ``
> and sqlite with "")
Escaping is normally for special characters. Quoting should fix the use of
reserved words. For intance,
create table "values" (id integer)
The new libgda API should even remove the need to write a SQL command to
create a table - you can use libgda API for that, and then you shouldn't
have to worry about doing quoting or escaping yourself.
Murray Cumming
murrayc murrayc com
www.murrayc.com
www.openismus.com
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]