============================================================================
POSTGRESQL BUG REPORT TEMPLATE
============================================================================
Your name : Andrea Girotto
Your email address : [EMAIL PROTECTED]
System Configuration
---------------------
Architecture (example: Intel Pentium) : AMD K6 450MHz
Operating System (example: Linux 2.0.26 ELF) : RedHat 6.0 (krnl 2.2.14)
PostgreSQL version (example: PostgreSQL-6.4.2) : PostgreSQL-6.4.2
Compiler used (example: gcc 2.8.0) :postgresql-6.4.2-3.i386.rpm
Please enter a FULL description of your problem:
------------------------------------------------
I think that DELETE (and UPDATE) with inheritance fails (example
follows).
DELETE * FROM tablea*;
ERROR: parser: parse error at or near "*"
UPDATE tablea* SET a_field='How do you do' WHERE a_field='Hello';
ERROR: parser: parse error at or near "*"
The Tutorial says:
Many of the commands that we have already discussed (select, update
and delete) support this "*" notation, as do others, like alter.
Please describe a way to repeat the problem. Please try to provide a
concise reproducible example, if at all possible:
----------------------------------------------------------------------
CREATE TABLE tablea (
a_field TEXT
);
CREATE TABLE tableb (
b_field TEXT
) INHERITS (tablea); -- inheritance!
INSERT INTO tablea (a_field) VALUES ('Hello');
INSERT INTO tableb (a_field, b_field) VALUES ('Hi', 'world');
SELECT * FROM tablea*; -- everything's OK
DELETE FROM tablea*;
UPDATE tablea* SET a_field='How do you do' WHERE a_field='Hello';
If you know how this problem might be fixed, list the solution below:
---------------------------------------------------------------------
It seems a parser's problem.