Page 1 of 1

Find view's definition in DB2.

Posted: Fri Dec 04, 2015 12:01 am
by LearnMainframe
Hi,

Does someone know of a possible way to find the definition of a view? I did check in the sysibm.sysviews table and there I was not able to get a meaningful definition.

Re: Find view's definition in DB2.

Posted: Fri Dec 04, 2015 4:42 pm
by nicc
Find the program/SELECT that creates the view.

Re: Find view's definition in DB2.

Posted: Sat Dec 05, 2015 12:56 am
by Akatsukami
What information are you seeking?

Re: Find view's definition in DB2.

Posted: Thu Dec 10, 2015 2:24 pm
by LearnMainframe
I need to know the DDL for the view and the description of the columns used in the view definition.

Re: Find view's definition in DB2.

Posted: Tue Mar 08, 2016 12:28 pm
by LearnMainframe
This SQL query has worked for me:

Code: Select all

SELECT * FROM SYSIBM.SYSVIEWS 
WHERE NAME LIKE '%Z4_UID%' 
AND     CREATOR = 'CAPN'