From: | "Gemeinschaft Studienarbeit Datenbanken" <oodbms(at)floppy(dot)org> |
---|---|
To: | "PostgreSQL SQL Mailing List" <pgsql-sql(at)hub(dot)org> |
Subject: | Another nut to crack with insertion into tables... *sigh* |
Date: | 1998-09-27 20:46:12 |
Message-ID: | 199809272146.1239275.6@onyx |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-sql |
insert into Rollenspiel
(Name, HerstellerID, Erscheinungsdatum,
Bestellnummer, Preisempfehlung,
Beschreibung,
Computertyp, Datentraegertyp,
System, AnzahlCharaktere, Typ,
Cluebook, SpielstandEditor)
values
('Might & Magic I', (select HerstellerNummer from Hersteller
where Name like '%Blueborg%'), '17.03.1986',
'role01', '29,50',
'{"Einfach irgendeine Beschreibung halt..."}',
'{"PC", "Mac", "c64", "Atari"}', '{"Diskette", "CD"}',
'Freies System', 6, 'Fantasy',
'{"Solution to Might & Magic Series", "The Might & Magic I Solution"}',
'{"http://www.mightandmagic.de/I/editors.html"}');
ERROR: parser: parse error at or near "select"
The question is: why?
spiele=> select HerstellerNummer from Hersteller;
herstellernummer
----------------
1
2
30
31
32
4
5
6
7
8
66
70
99
17
88
(15 rows)
Doing this from psql plainly yields the wanted result:
spiele=> select HerstellerNummer from Hersteller where Name like '%Blueborg%';
herstellernummer
----------------
7
(1 row)
Pointers to FAQs, solutions, help, donuts greatly appreciated ;-)
From | Date | Subject | |
---|---|---|---|
Next Message | Stan Thomas | 1998-09-28 07:08:29 | subscribe |
Previous Message | Herouth Maoz | 1998-09-27 12:53:53 | Timespan conversion |