Reputation: 2623
The code
SELECT some_identifier_id INTO a_someid_id FROM "SOME_IDENTIFIER" SOME_IDT
INNER JOIN "CASE" cse ON cse.customer_id = '1001'
INNER JOIN "MEASURE" m ON m.case_id = cse.case_id
WHERE SOME_IDT.some_identifier_type_code = '430101';
Gives out an "missing keyword" error. Where the problem lies?
Upvotes: 1
Views: 1331
Reputation: 116110
You can use INTO
only when you execute the query in a PL/SQL program block (either anonymous, trigger, stored proc...).
An SQL query cannot contain an INTO
clause, and it will give you this error.
-- Will fail
SELECT 1 INTO x FROM dual;
-- Will succeed
declare x int;
begin
SELECT 1 INTO x FROM dual;
end;
Upvotes: 5