dbTalk Databases Forums  

MQTs

comp.databases.ibm-db2 comp.databases.ibm-db2


Discuss MQTs in the comp.databases.ibm-db2 forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Damir
 
Posts: n/a

Default MQTs - 12-11-2010 , 09:22 AM






Greetings,
how can I find out what MQTs are defined on a particular table?

Regards,
Damir

Reply With Quote
  #2  
Old   
Damir
 
Posts: n/a

Default Re: MQTs - 12-11-2010 , 09:29 AM






OK, first problem solved, I can get the list of MQTs with:

select * from syscat.tables where type = 'S';

So, how do I find the statement text for each MQT?

Damir


---
"Damir" <damirwilder (AT) yahoo (DOT) com> wrote

Quote:
Greetings,
how can I find out what MQTs are defined on a particular table?

Regards,
Damir


Reply With Quote
  #3  
Old   
Willem Fischer
 
Posts: n/a

Default Re: MQTs - 12-11-2010 , 10:22 AM



On Dec 11, 4:29*pm, "Damir" <damirwil... (AT) yahoo (DOT) com> wrote:
Quote:
OK, first problem solved, I can get the list of MQTs with:

select * from syscat.tables where type = 'S';

So, how do I find the statement text for each MQT?

Damir

---"Damir" <damirwil... (AT) yahoo (DOT) com> wrote in message

news:ie051q$k23$1 (AT) ss408 (DOT) t-com.hr...







* *Greetings,
how can I find out what MQTs are defined on a particular table?

Regards,
* *Damir
Try the following:
select text from syscat.views where viewname='MYMQT';

Reply With Quote
  #4  
Old   
Lennart Jonsson
 
Posts: n/a

Default Re: MQTs - 12-11-2010 , 11:59 PM



On 2010-12-11 16:29, Damir wrote:
Quote:
OK, first problem solved, I can get the list of MQTs with:

select * from syscat.tables where type = 'S';

So, how do I find the statement text for each MQT?
Reading your original question I thought you where interested in what
mqt's that are dependent on a particular table. If that is the case you
can find out via syscat.tabdep:

select tabschema, tabname
from syscat.tabdep
where (bschema, bname) = (?, ?)

/Lennart

[...]

Reply With Quote
Reply




Thread Tools
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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.