Re: Simple stored procedure examples?
От | Mikko Partio |
---|---|
Тема | Re: Simple stored procedure examples? |
Дата | |
Msg-id | 454CBCB3.7000808@paprikalaatikko.be обсуждение исходный текст |
Ответ на | Re: Simple stored procedure examples? (novnov <novnovice@gmail.com>) |
Ответы |
Re: Simple stored procedure examples?
|
Список | pgsql-general |
> novnov wrote: >> Thanks to both of you for responding. I should have included the code for >> my own attempt, at #1 which is just as you suggest: >> >> update item set itemname = 'fox'; >> >> I've tried single, and double quoting the table and field names; call caps >> to the UPDATE etc, exactly matching the capitalization of the table and >> field names (really Item and ItemName). >> >> I wonder if "Item" is a reserved word in pgsql? >> >> I think you haven't quoted the field names correctly. dun=# CREATE TABLE "Item" (id int4, "ItemName" text); CREATE TABLE dun=# INSERT INTO "Item" VALUES(1,'aaa'); INSERT 0 1 dun=# UPDATE "Item" SET "ItemName" = 'fox'; UPDATE 1 dun=# SELECT * FROM "Item"; id | ItemName ----+---------- 1 | fox (1 row) If you want to have case-sensitive names, you have to have double quotes. MP
В списке pgsql-general по дате отправления: