1
Good evening, everyone,
I’m trying to make a select within an ORACLE database, only I’m not getting it. Below is an example of code I’m trying to generate.
CREATE OR REPLACE PROCEDURE TRAZNOMES IS
BEGIN
SELECT * FROM EMP;
END;
/
I’m very grateful, in case you could try to help me.
Sincerely yours.
What do you want to do with this select? Take a specific value, loop it?
– Daniel Mendes
I want to read all the fields that exist in this table.
– Frederico Halley
All fields and records?
– Daniel Mendes
The fields in the table are EMPNO, ENAME, JOB, MGR, HIREDATE, SAL, COMM, DEPTNO
– Frederico Halley
That’s right, all fields and records.
– Frederico Halley
There are many introductory tutorials about plsql, read one of them , it seems to me that vocêuma FUNCTION , tip a "select" in pl-sql needs to return one and only line, otherwise use cursors. This one sounds good https://www.docsity.com/pt/programando-prodedualmente-em-pl-sql/4733270/
– Motta