If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > DB2 > Mqt Sql!!

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 11-06-07, 02:09
rajinbits rajinbits is offline
Registered User
 
Join Date: Nov 2007
Posts: 26
Mqt Sql!!

Hello Guys,
In our DB, we are having a MQT defined on 2 tables. Now from where can I get the SQL used for creating the MQT ?

Thanks
Rajesh
Reply With Quote
  #2 (permalink)  
Old 11-06-07, 02:23
guyprzytula guyprzytula is offline
Registered User
 
Join Date: Jun 2006
Posts: 471
have you checked db2look output
__________________
Best Regards, Guy Przytula
DB2 UDB LUW certified V6/7/8
Reply With Quote
  #3 (permalink)  
Old 11-06-07, 02:32
rajinbits rajinbits is offline
Registered User
 
Join Date: Nov 2007
Posts: 26
No...could you please tell me how to use it??? thanks
Reply With Quote
  #4 (permalink)  
Old 11-06-07, 03:47
stolze stolze is offline
Registered User
 
Join Date: Jan 2007
Location: Jena, Germany
Posts: 2,662
Code:
$ db2look -d <dbname>
Also check "db2look -h" for further options.
__________________
Knut Stolze
IBM DB2 Analytics Accelerator
IBM Germany Research & Development
Reply With Quote
  #5 (permalink)  
Old 11-06-07, 08:31
guyprzytula guyprzytula is offline
Registered User
 
Join Date: Jun 2006
Posts: 471
at least db2look -d dbname -e -l -o outfile
__________________
Best Regards, Guy Przytula
DB2 UDB LUW certified V6/7/8
Reply With Quote
  #6 (permalink)  
Old 11-06-07, 10:41
ARWinner ARWinner is offline
Registered User
 
Join Date: Jan 2003
Posts: 3,575
Try:

select text from syscat.views where viewschema = 'MySchema' and viewname = 'MyMQT'

Andy
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On