How to handle null values in db2

Answer Posted / yuvaevergreen

IN DCLGEN,
>>"INDICATOR VARS .. ===> NO" indicates the presence of
null variables for the fields in the tables.
>>indicator variable should be declared of type s9(4) comp.
77 DAY-IND PIC S9(4) BINARY.
Move -1 to the indicator variable and use in sql.
exec sql
insert into employee(name)
values(:ws-name:ws-name-ind)
end-exec;
ws-name-ind is the indicator variable which inserts null in
the field ws-name.

Is This Answer Correct ?    3 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How does db2 sample database connect?

561


Cursors can be declared in both working-storage & procedure division, agreed. But is there any difference? If could you please suggest what is the difference

730


I HAVE 500 ROW TO UPDATE I WOULD LIKE TO USE ROLLBACK ALONG WITH COMMIT.WHAT IS THE SYNTAX TO CODE COMMIT AND ROLLBACK FOR EVERY 100 ROWS.AND HOW THE CURSOR ROLLBACK TO THE LAST COMMITTING POINT.

2744


Is ibm db2 open source?

573


Explain the function of data manager.

626






What is null indicator in cobol db2?

571


If anyone has IBM Certification Dumps pls forward to me & also let me know what are the Certification Codes that are available in DB2

1567


What is db2 look?

565


What is null in db2?

567


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

634


What is the use of db2?

574


What is the use of db2 optimizer?

601


Which isolation level provides highest data integrity?

586


What are host variables in db2?

611


What is dbrm?

630