how can u retrieve the data from null values using
applicaion program.

Answers were Sorted based on User's Feedback



how can u retrieve the data from null values using applicaion program...

Answer / avinash

The null indicator would be assigned a value of -1 if the
fetched column has a null value.

Is This Answer Correct ?    15 Yes 0 No

how can u retrieve the data from null values using applicaion program...

Answer / prachi

whenever you are retreving the data from null coloumn,
first you need to declare the null indicator in the working
storage section. and use this variable when you are
fecthing the data from null coloumn.

Is This Answer Correct ?    9 Yes 0 No

how can u retrieve the data from null values using applicaion program...

Answer / bhavani

When we retrieve data from a nullable field, we need to
have a null indicator declared in the working storage.

WS-NULL-INDICATOR s9(04) comp

And after you have fetched the value for that column,

we need to check the value of the null indicator.

It can have the following values

-2 - Exceptional condition
-1 - Null Value is present in that field
0 - Not null

Is This Answer Correct ?    9 Yes 0 No

Post New Answer

More DB2 Interview Questions

What is a bind card?

0 Answers  


Explain about cursor stability?

0 Answers  


What are simple, segmented and partitioned table spaces ?

1 Answers   TCS,


My sql statement select avg(salary) from emp yields inaccurate results. Why?

0 Answers  


what is the use of commit ? and what is the syntax?

2 Answers   Deloitte,


assume ther are 5000 records in a database and want to fetch using cursor. cursor fetches only 3000 records and fetch is not happening for remaining 2000 records. why it happens and how to rectify it

1 Answers   TCS,


what is consistency token

3 Answers  


How do you Load a table ?? and what is Load replace ?

2 Answers   Xansa,


i know the stpes 2 create an executable CICS/DB2 cobol code. 1. DB2 Precompiler converts the SQL Statements into COBOL API statements and creates another member with Acess plans. CodeA results in CodeB (code with API calls) & CodeC ( Access Plans ) 2.Code B is compiled/linked 2 create an exceutable.(codeE) 3.Now CodeC is binded to the database on which CodeE will be run. Can somebody provide me the sample JCLs for precompile/compile/link/bind.

0 Answers  


What is the SQL query to select, delete and get count of duplicate rows in DB2?

2 Answers  


in the CURSOR declare statement, if i am using an where clause and trying to compare the value with a host-varialble. EXEC SQL DECLARE C1 CURSOR FOR SELECT DEPTNO, DEPTNAME, MGRNO FROM DEPARTMENT WHERE ADMRDEPT = :ADM-DEPT Where would i need to provide value to this host-variable in the where clause. how could i pass value to this host-variable to check it.

2 Answers   iGate,


What are the various locking levels available?

3 Answers  


Categories