Suppose we have a query for update

update table1
set col1 = 'val1'
where col2=(select .... from ...)

suppose the subquery does not return any record, what will
happen to update?



Answer Posted / santosh kumar d

If the col2 field having any null value then that value to
be updated.
If col2 doesn't have any null value then record remains same
nothing will be updated.

Is This Answer Correct ?    4 Yes 6 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Suppose pgm A calling Pgm B .Pgm B has some Db2 program. at the time of compilation should plan and package will be created for both A and B or only B? What is the concept?

6866


What is the difference between cursor and select statement?

617


List out the buffer pools in db2

634


Why do we bind in db2?

634


what is utility for parm lib

1886






What is concurrency?

711


When do you specify the isolation level?

612


what is db2 restart?

1695


What is explain in db2?

586


What is check constraint. Explain with example.

650


What is the difference between "db2ilist" and "db2 get instance" commands in DB2 Database Server?

716


How to find schema of a table in db2?

574


Explain how can you do the explain of a dynamic sql statement?

656


What is reorg?

619


What is query_cache_limit?

549