Can you create a SQL Update statement in Matillion?

876 Views Asked by At

I'm trying to create an UPDATE statement in the SQL component in Matillion however I get a syntax error at SET.

UPDATE matchingmanufacturernofulllast2
SET "matchingmanufacturernofulllast2.available" = 'f'
where listprice is not null 



ERROR: syntax error at or near "SET"
  Position: 88

Does Matillion sql component have the ability to use the sql UPDATE syntax?

Regards Conteh

2

There are 2 best solutions below

0
On BEST ANSWER

Use the SQL orchestration component for DDL. The SQL transformation component is for Select only.

https://documentation.matillion.com/docs/2107012

0
On

One option to create an update statement with a where clause in Matillion is to use the calculator component in conjuction with a case expression

CASE
WHEN ("listprice" is not null)
THEN 'F'
END