Boa tarde,
preciso dar um update com um subselect porém não estou conseguindo…
preciso setar todos status como 1 na tabela TR_SEQUENCER_QLT_REP e meu script da erro.
Qual seria a sintaxe correta?
Segue o script
UPDATE TR_SEQUENCER_QLT_REP
SET SEQ_STATUS = 1
( SELECT *
FROM TR_PO_ASSOCIATE_REC TPOREC
INNER JOIN TR_SEQUENCER_QLT_REP TSEQQREP
ON ((TPOREC.SEQUENCER_QLT_REP_ID = TSEQQREP.ID_SEQUENCER_QLT_REP))
INNER JOIN TR_REC_QLT_REPORT TRQREP
ON ((TSEQQREP.QLT_REC_REP_ID = TRQREP.ID_REC_QLT_REPORT))
INNER JOIN TR_ITEM_RECEIVED TIREC
ON ((TRQREP.ITEM_RECEIVED_ID = TIREC.ID_ITEM_RECEIVED))
INNER JOIN TR_STUFF TSTFF
ON ((TIREC.STUFF_ID = TSTFF.ID_STUFF))
INNER JOIN TR_P_O_MAN_PROD_LOT_DTL TPOLPD
ON ((TPOLPD.ID_P_O_MAN_PROD_LOT_DTL = TPOREC.PO_PROD_LOT_DTL_ID))
INNER JOIN TR_P_O_MANAGE_LOT_PROD TRPOLP
ON ((TRPOLP.ID_P_O_MANAGE_LOT_PROD = TPOLPD.P_O_MANAGE_LOT_PROD_ID))
WHERE (TSEQQREP.SEQ_STATUS = 4 AND TPOLPD.IDENTIFY_CODE is null )
Obrigado!!