Categories:
.NET (357)
C (330)
C++ (183)
CSS (84)
DBA (2)
General (7)
HTML (4)
Java (574)
JavaScript (106)
JSP (66)
Oracle (114)
Perl (46)
Perl (1)
PHP (1)
PL/SQL (1)
RSS (51)
Software QA (13)
SQL Server (1)
Windows (1)
XHTML (173)
Other Resources:
How To Assign a Table Row to a RECORD Variable
How To Assign a Table Row to a RECORD Variable? - Oracle DBA FAQ - Working with Database Objects in PL/SQL
✍: FYIcenter.com
If you have a table, and want to assign a data row of that table to a RECORD variable, you need to define this RECORD variable to match the table column structure, then use the SELECT ... INTO statement to assign a data row that RECORD variable. The script below shows you how to do this:
CREATE OR REPLACE PROCEDURE FYI_CENTER AS
manager employees%ROWTYPE;
BEGIN
SELECT * INTO manager FROM employees
WHERE employee_id = 100;
DBMS_OUTPUT.PUT_LINE('My manager = ' ||
manager.first_name || ' ' || manager.last_name);
END;
/
My manager = Steven King
2007-04-27, 5328👍, 0💬
Popular Posts:
What will be printed as the result of the operation below: main() { char s1[]="Cisco"; char s2[]="sy...
How To Avoid the Undefined Index Error? - PHP Script Tips - Processing Web Forms If you don't want y...
Once I have developed the COM wrapper do I have to still register the COM in registry? Yes.
How To List All Values of Submitted Fields? - PHP Script Tips - Processing Web Forms If you want lis...
What Is a CAPTION Tag/Element? - XHTML 1.0 Tutorials - Understanding Tables and Table Cells A "capti...