Hi All,
If I type \h insert at psql it shows me,
INSERT INTO class_name [(attr1, ...attrN)]
VALUES (expr1,..exprN) |
SELECT [DISTINCT [ON attrN]]
expr1, ...exprN
[FROM from_clause]
[WHERE qual]
[GROUP BY group_list]
[HAVING having_clause]
[ { UNION [ALL] | INTERSECT | EXCEPT } SELECT ...];
But when I tried the following query it gave the parse error
INSERT INTO EffortTable (EffortID)
VALUES (ValueForEffortID) |
SELECT MAX(EffortID) AS ValueForEffortID
FROM EffortTable
WHERE ProjectID=200;
the error is --> ERROR: parser: parse error at or near "|"
What is the syntax I should use.
Thanx in advance,
Shad.