What do you mean by NOT NULL WITH DEFAULT? When will you
use it?
Answers were Sorted based on User's Feedback
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 |
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 |
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 |
Is there any advantage to denormalizing DB2 tables?
what is the process of precompiler?
what is the syntax for FOR UPDATE CLAUSE in cursor declaration and how can u update using cursor? is it possible to update multiple rows at a time.
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
What is an alias?
What is a db2 cursor?
What is lock escalation?
Why PS file called Physical seqential file?How to sore data in sequential file and ESDS file? What is the use of DBRM,PLAN,package and Collection.
Which one allows duplicate values Union or Union All ?
What is the maximum size of a char data type in db2?
Explain transactions, commits and rollbacks in DB2.
What is cloudant database?