Hi
Just for info.
Actual query in Oracle (below)
--
MERGE INTO relDocumentTypeMetaDataName t
USING (SELECT ? as DocumentTypeID, ? as DocumentContextID, ? as
MetaDataNameID, ? as DocumentAbstractionIndexID FROM DUAL) s
ON (t.MetaDataNameID = s.MetaDataNameID AND t.D
On Wed, Jun 29, 2016 at 2:07 AM, Sridhar N Bamandlapally <
sridhar@gmail.com> wrote:
> Hi
>
> Please go through below case
>
> postgres=# CREATE TABLE emp (id INTEGER unique, ename VARCHAR);
> CREATE TABLE
> postgres=# INSERT INTO emp VALUES (null, 'aaa');
> INSERT 0 1
> postgres=# INSERT INTO
Hi
The actual statement is MERGE INTO NOT MATCHED, which in PG
migrated to WITH - INSERT
however, yes, the SQL-statement in previous does not work in other
databases too, I was wrong
Thanks, thanks again
Sridhar
OpenText
On Wed, Jun 29, 2016 at 11:58 AM, Tom Lane wrote:
> Sridhar N Bamandla
Sridhar N Bamandlapally writes:
> postgres=# CREATE TABLE emp (id INTEGER unique, ename VARCHAR);
> postgres=# INSERT INTO emp VALUES (null, 'aaa');
> ...
> postgres=# INSERT INTO emp SELECT * FROM (SELECT 5::integer id,
> 'eee'::varchar ename) nr WHERE id NOT IN (SELECT id FROM emp);
> INSERT 0 0