I am writing a code in PL/SQL on Oracle 10g which requires a user input. I want to give a prompt for user input which I can’t to do so. It’d be great if you help!
I tried the following code, just to test if the prompt was working or not. However, the code if giving an error as "ORA-00900: invalid SQL statement"
. Can you please tell me where I’m going wrong?
ACCEPT x NUMBER PROMPT 'Please enter a value';
DECLARE
a NUMBER:=&x;
BEGIN
dbms_output.put_line(a);
END;
/
New contributor
Rose is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.