After update how do u know how many records got updated
Answers were Sorted based on User's Feedback
Answer / svj
Using SQL Cursor Attribute,'SQL%ROWCOUNT' which gives
no.of rows affected by the most recentSQL statement (an
integer value), one can know no.of records got updated.
For Example :
VARIABLE rows_updated VARCHAR(30)
DECALRE
v_dept_no departments.department_id%TYPE := 20
BEGIN
UPDATE employees
SET salary = salary + 1000
WHERE department_id = v_dept_no;
: rows_updated := (SQL%ROWCOUNT || 'rows updated.');
END;
/
PRINT rows_updated
Is This Answer Correct ? | 5 Yes | 1 No |
Answer / pkd
Except sql%rowcount,using returning clause with count()
function
Is This Answer Correct ? | 1 Yes | 1 No |
how many outer joins are used in a single sql query? is there any limitations for using of outer joins?
2 Answers BOB Technologies, Cap Gemini, IBM,
How to connect asp pages to oracle servers?
does the query needs a hint to access a materialized view?
How do we know whether an index is created on a table ???
How to add a new column to an existing table in oracle?
What is cluster Key ?
What is a cognitive schema?
What is meant by recursive hints ?
What is dynamic proxy?
Explain the use of parfile option in exp command.
Explain a synonym?
What are the different oracle database objects?