Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
What is the DB2 equivalent of DESC(in Oracle)?

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> HomeWorks & Requests
View previous topic :: :: View next topic  
Author Message
Anand78

New User


Joined: 06 Mar 2006
Posts: 50
Location: PUNE

PostPosted: Thu May 17, 2007 3:04 pm    Post subject: What is the DB2 equivalent of DESC(in Oracle)?
Reply with quote

what is the DB2 equivalent of DESC(in Oracle)?
Back to top
View user's profile Send private message

Devzee

Active Member


Joined: 20 Jan 2007
Posts: 684
Location: Hollywood

PostPosted: Thu May 17, 2007 4:51 pm    Post subject:
Reply with quote

I'm not sure whether there is an equivalent of DESC in DB2.

Here is what I think, DESC gives Table description right. So to get the table description which is nothing but list of columns etc, you can query the SYSIMB.SYSCOLUMNS for that table.
Back to top
View user's profile Send private message
pravinjose

New User


Joined: 05 Aug 2007
Posts: 2
Location: Hyderabad

PostPosted: Wed Sep 19, 2012 9:37 am    Post subject: Reply to: What is the DB2 equivalent of DESC(in Oracle)?
Reply with quote

The DESCRIBE TABLE statement obtains information about a table or view.

Invocation
This statement can only be embedded in an application program, SQL function, SQL procedure, or trigger. It is an executable statement that cannot be dynamically prepared. It must not be specified in Java.

Syntax

>>-DESCRIBE TABLE--variable------------------------------------->

.-INCLUDING IMPLICITLY HIDDEN COLUMNS-.
>--+-------------------------------------+---------------------->
'-EXCLUDING IMPLICITLY HIDDEN COLUMNS-'

.-SQL-. .-LOCAL--.
>--+-USING--+-----+--DESCRIPTOR--+--------+--SQL-descriptor-name-+-><
| '-GLOBAL-' |
'-INTO----descriptor-name----+-------------------------+------'
'-USING--+-NAMES--------+-'
+-SYSTEM NAMES-+
+-LABELS-------+
+-ANY----------+
+-BOTH---------+
'-ALL----------'

Description
variable
Identifies the table or view to describe. When the DESCRIBE TABLE statement is executed:
•The name must identify a table or view that exists at the application server.
•The variable must be a character-string or Unicode graphic-string variable and must not include an indicator variable. It cannot be a global variable.
•The table name that is contained within the variable must be left-justified and must be padded on the right with blanks if its length is less than that of the variable.
•The name of the table must be in uppercase unless it is a delimited name.
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


Joined: 22 Apr 2006
Posts: 6258
Location: Mumbai, India

PostPosted: Wed Sep 19, 2012 10:20 am    Post subject:
Reply with quote

pravinjose - You're replying nearly 5 years after the original question was posted... icon_smile.gif
Back to top
View user's profile Send private message
pravinjose

New User


Joined: 05 Aug 2007
Posts: 2
Location: Hyderabad

PostPosted: Wed Sep 19, 2012 12:16 pm    Post subject: Reply to: What is the DB2 equivalent of DESC(in Oracle)?
Reply with quote

Ya icon_smile.gif , I came across this post today only. Thought that it might be useful for someone who views this post in the future.

I was actually trying to find what woud be the Oracle equivalent for AS/400 Physical files which contains multiple File members.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> HomeWorks & Requests All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Need help with Oracle Dynamic SQL: Me... Anoop Chandran1984 COBOL Programming 1 Sat Feb 13, 2016 7:27 am
No new posts Oracle Gateway software for Download ... nans1979 COBOL Programming 2 Wed Aug 20, 2014 12:09 am
This topic is locked: you cannot edit posts or make replies. Referral Walk-In For Oracle Solutions... pradeepon4u Mainframe Jobs 0 Tue Jan 28, 2014 4:02 pm
No new posts moving date from host variable to ora... rohanthengal DB2 5 Fri Jan 17, 2014 10:14 pm
No new posts EQUIVALENT OF COBOL INSPECT IN REXX pshongal CLIST & REXX 2 Fri Nov 22, 2013 10:44 am

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us