What do you mean by NOT NULL WITH DEFAULT? When will you
use it?

Answers were Sorted based on User's Feedback



What do you mean by NOT NULL WITH DEFAULT? When will you use it?..

Answer / s

NOT NULL WITH DEFAULT indicates that the column cannot
contain a NULL, if a user doesnt enter a value, DB2
generates the default.

Is This Answer Correct ?    20 Yes 1 No

What do you mean by NOT NULL WITH DEFAULT? When will you use it?..

Answer / kumar

Using 'NOT NULL WITH DEFAULT' you can also specify you own
values. INTEGER, SMALLINT will assigned with zero, CHAR,
VARCHAR will be assigned with spaces. DATE, TIME, TIMESTAMP
will be assigned with system DATE, TIME & TIMESTAMPE values
respectively.

As the table is declared with 'NOT NULL WITH DEFAULT',
there is no chance of getting the null values during data
fetch.

Is This Answer Correct ?    15 Yes 2 No

What do you mean by NOT NULL WITH DEFAULT? When will you use it?..

Answer / shankar

when we specified NOT NULL WITH DEFAULT in the query ,the
database will set the default values to that key eg. system
date ,time.

Is This Answer Correct ?    9 Yes 10 No

Post New Answer

More DB2 Interview Questions

What value the host varible will contain , if null indicator value is -2 ? Will it contain the truncated value or nothing will move ?

3 Answers   Cap Gemini,


Assuming that a site's standard is that pgm name = plan name, what is the easiest way to find out which Will precompile of an DB2-COBOL program bomb, if DB2 is down?

1 Answers  


wht is d/f b/w inner join and outer join ? d/f group by and order by having by ?

2 Answers  


What is a DB2 catalog?

2 Answers  


Q3. How will you fetch duplicate values from a DB2 table?

2 Answers   RBS,






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.

0 Answers   ITC Infotech, Syntel,


What is the use of db2 optimizer?

0 Answers  


what's the error code for Unique Index Violation?

2 Answers  


DB2 can implement a join in three ways using a merge join, a nested join or a hybrid join. Explain the differences?

0 Answers  


Under what circumstances will DB2 allow an SQL statement to update more than one primary key value at a time?

1 Answers  


How can you split a table in to exactly half?

7 Answers   HSBC,


What is db2 bind process?

0 Answers  


Categories