In which column of which DB2 catalog would you find the
length of the rows for all tables?

Answers were Sorted based on User's Feedback



In which column of which DB2 catalog would you find the length of the rows for all tables?..

Answer / daphne

I assume that you mean "Column length" (Field length) for
all the fields of all the tables.

This can be found in SYSIBM.SYSCOLUMNS. The column name is
LENGTH.

If you want to find the column lengths of a particular
table then the query would be

Select NAME, LENGHT from SYSIBM.SYSCOLUMS where TBNAME =
<tablename>

Is This Answer Correct ?    1 Yes 0 No

In which column of which DB2 catalog would you find the length of the rows for all tables?..

Answer / vat

'RECLENGTH' column of SYSIBM.SYSTABLES would have the
record/row length of the table.

It's format: 8 + n + l where
8 accounts for 6 header bytes and 2 ID map entry bytes
n = 0 if there is no edit proc otherwise 10
l = Sum of max. col lengths (Add 1 byte for Null indicator
for nullable columns, 2 bytes for Varchar columns, 4 bytes
for LOB column)

and, RECLENGTH is 0 for auxilary tables, views and aliases

Is This Answer Correct ?    1 Yes 0 No

Post New Answer

More DB2 Interview Questions

Generally if I want to select the names starting with c I need to use c% But how could I code to select the data which contains % as a part of data.

5 Answers  


cursor with hold explain ?

1 Answers   Verizon,


What is a DB2 catalog?

2 Answers  


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

3 Answers   IBM,


what happend with out using Commit,when closing cursor and program?

5 Answers   CSC,






When Can you be sure that a query will return only one row?

4 Answers   IBM,


What is the error code -803 ?

3 Answers  


What is a predicate?

1 Answers  


what is main use of table space and index object? please its urgent

5 Answers   CA, Cap Gemini, CGI, CTS, EDS, HTC, IBM, Satyam, Syntel, TCS, Wipro,


How would you move a tablespace (using STOGROUP) to a different DASD volume allocated to that tablespace?

1 Answers  


What is CHECK PENDING ?

5 Answers  


How and when does the db2 enforces the unique key?

0 Answers  


Categories