简体   繁体   中英

Oracle SQL problem with declare variable from table

I have problem with make variable from table.

DECLARE
 liczba1 PLS_INTEGER;
 
 BEGIN
Select liczba1 := MAX(EMPLOYEE_ID) FROM PRACOWNICY;
 
 END;

That is the problem

ORA-00923: FROM keyword not found where expected

I don't have any idea why it's not working

I think you want into :

SELECT MAX(EMPLOYEE_ID) INTO liczba1 FROM PRACOWNICY

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM