What is ALTER ?
Answers were Sorted based on User's Feedback
Answer / s
ALTER is a DDL (data definition language) statement to make
changes to the description of the table.
Is This Answer Correct ? | 3 Yes | 0 No |
Answer / om yadav
modify the structer of table.
1. add column.
2. midify column.
3. drop column.
4. add or remove constraint.
Is This Answer Correct ? | 1 Yes | 0 No |
Answer / jitendra
ALter is to change db2 table definition. for eg:
Alter tablename
add column number(11,2)
Is This Answer Correct ? | 0 Yes | 0 No |
what is the role of the cursor in db2?
SET is the ANSI standard for variable assignment, SELECT is not. SET can only assign one variable at a time, SELECT can make multiple assignments at once. If assigning from a query, SET can only assign a scalar value. If the query returns multiple values/rows then SET will raise an error. SELECT will assign one of the values to the variable and hide the fact that multiple values were returned (so you'd likely never know why something was going wrong elsewhere - have fun troubleshooting that one) When assigning from a query if there is no value returned then SET will assign NULL, where SELECT will not make the assignment at all (so the variable will not be changed from it's previous value) As far as speed differences - there are no direct differences between SET and SELECT. However SELECT's ability to make multiple assignments in one shot does give it a slight speed advantage over SET.
How can you display the current date & current 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
Can you define an Index if the table size less than 10 PAGES?
How do you check for a null value in a db2 column?
Explain packages.
What is a storage group (stogroup)?
What action db2 takes when a program aborts in the middle of a transaction?
How can you quickly find out the number of rows updated after an update statement?
Can SQL statements/queries be included in a copybook?
What is a NULL value? What are the pros and cons of using NULLS?