How we create a tables in db2,what is the process/syntax to
create a table with example plz?
Answers were Sorted based on User's Feedback
Answer / dba
Its very much similar as we sue in other DB
Syntax: CREATE TABLE EMPLOYEE(EMP_ID CHAR(10), NAME VARCHAR(20))
The syntax is usful only in command center
But from GUI its more easier to create table
| Is This Answer Correct ? | 14 Yes | 5 No |
Answer posted by Dba is correct.
But in real time schenario we should be more specific.
eg:
CREATE TABLE SCHEMA.TABLENAME
(column1 DATATYPE,
column2 DATATYPE,
column3 DATATYPE)
IN tablespace_name
INDEX IN index_tablespace;
so try to follow this syntax (u can have more options with
this command like u can even specify the tablespace name wr
do u want to store ur LONG object 'LONG IN
long_tablespace' )
Cheers,
Ratheesh Nellikal
| Is This Answer Correct ? | 6 Yes | 0 No |
Can I use LOCK TABLE on a view?
How can the firstname and the lastname from the emp table be concatenated to generate complete names?
How many databases can be created inside an instance in db2 ?
when i am trying to update a table having 1000 rows. the program abends.how we will come to know the last successful updated row was. we are not using any commit operations
Say CUST Table contains records like: CUSTNO CUSTNAME CUSTLOC 100 ABC SSS 200 XYZ 300 PQR 400 MNO WWW 500 CVV ------------- ------------- Now write a query to retrieve all records with CUSTLOC no data.
What are db2 tables?
When is the results table for the query in a DECLARE CURSOR statement created?
Parm value passed is PARM=(10,20). how do code linkage section and how would you add these two passes values and show result in cobol program.
What are the full forms of spufi and dclgen and why are they used?
In my table having 100 Rec. How can I delete the 7th row?? (we don't know what is data inside the table)
What is the role of data manager in the db2 database?
How to fetch the last row from the table in SQL (db2)?