Could you please let me no the query for below

I have table name xyx under this there is column name called employee name which starts from 100th column ends 120th column,now i want to replace only column from 101 to 104 which contains ABCS to replace with PQRS for all records which comes beetween 101 to 104 ..how to write query for this..

Answer Posted / devika

update XYZ
set empname(2,4) = 'PQRS'
where substr(empname(2,4))='ABCS'

Is This Answer Correct ?    3 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How can you validate Sql errors during cursor operation in db2 pgms and where do you code?

1813


How to get the ddl of a table in db2?

759


What is the clustering index in the db2 database?

651


What is the cobol picture clause of the db2 data types date, time, timestamp?

705


What is the purpose of rollback and commit?

677






What is the physical storage length of the data types: date, time, timestamp in the db2 database?

756


What is the difference between dbm cfg and db cfg file in db2 ?

1104


What is schema in db2?

666


What are db2 objects?

717


What are the rules for db2 programming?

728


What is nvl in db2?

727


What is plan in cobol db2?

686


How do you stop a db2 database in linux?

640


Before you give the explain statement, what are the prerogatives?

653


Why db2 is called db2?

670