473,800 Members | 2,541 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Use of MQTs

At one of the clinets I am working with, we are having a debate about
the use of MQTs or go with traditional way of creating aggregate
tables and populating them. I would go with the MQTs instead of the
traditional way.

Does anyone has any input as to which way is better from an apporach
point of view which would result that is better for an organization.

Any feedback is appreciated.

Thanks,
Suresh
Nov 12 '05 #1
5 4271
AK
is it DSS or OLTP?
do you plan to use REFRESH IMMEDIATE or REFRESH DEFERRED?
Nov 12 '05 #2
This is a DSS. And as an alternative to an MQT, they are planning to
go with an explicit aggregate table and maintain it manually. We need
to refresh the data once a day. So, REFRESH DEFERRED...
ak************@ yahoo.com (AK) wrote in message news:<46******* *************** ****@posting.go ogle.com>...
is it DSS or OLTP?
do you plan to use REFRESH IMMEDIATE or REFRESH DEFERRED?

Nov 12 '05 #3
my*****@gmail.c om (Suresh) wrote in message news:<ef******* *************** ****@posting.go ogle.com>...
This is a DSS. And as an alternative to an MQT, they are planning to
go with an explicit aggregate table and maintain it manually. We need
to refresh the data once a day. So, REFRESH DEFERRED...


I've got a warehouse with quite a few explicitely created summary
tables. I think that there's probably a value in both MQTs and
manually-managed summary tables. In my case I had a lot of SQL that
MQT's didn't support:
- declared temp tables
- order by (in order to get top X values)
- processes external to database (involving extraction, data mining
function, and reloading)
- UDFs
- I think that there were a few other restrictions as well at the
time that have been addressed in various fixpacks since 8.1.0.

Additionally, most of the access to these summary tables was by a
custom-developed application. This simple application was able to be
coded directly against the summary tables. While that involved a bit
of education of the programmers - it didn't involve *any* work in
trying to figure out why DB2 was or wasn't rewriting a query properly.
Plus - some queries would never be eligible for rewrite anyway.

In my case manual summary tables have worked fine. However, I am
planning to implement some MQTs for an adhoc environment that I've
got. In this environment it isn't practical to educate the users or
customize the application to support a dozen summary tables - so DB2's
rewriting of queries is really the best choice.

buck
Nov 12 '05 #4
Thanks for your response.
I understand in cases where MQTs can not be created, an explicit
summary table can be used.
But, the argument is that DB2 optimizer does something goofy in the
way it selects the MQT when querying the base tables. And it is a lot
of maintenance for a DBA. But it is my understanding that you can
create an MQT and disable the optimizer not to select MQT when
querying the base tables as a start.

But, instead of maintaining a explict summary table and make sure it
is loaded properly, why not use an MQT and load it deferred and use
the MQT directly when querying.

-Suresh

bu*********@yah oo.com (Buck Nuggets) wrote in message news:<66******* *************** ****@posting.go ogle.com>...
my*****@gmail.c om (Suresh) wrote in message news:<ef******* *************** ****@posting.go ogle.com>...
This is a DSS. And as an alternative to an MQT, they are planning to
go with an explicit aggregate table and maintain it manually. We need
to refresh the data once a day. So, REFRESH DEFERRED...


I've got a warehouse with quite a few explicitely created summary
tables. I think that there's probably a value in both MQTs and
manually-managed summary tables. In my case I had a lot of SQL that
MQT's didn't support:
- declared temp tables
- order by (in order to get top X values)
- processes external to database (involving extraction, data mining
function, and reloading)
- UDFs
- I think that there were a few other restrictions as well at the
time that have been addressed in various fixpacks since 8.1.0.

Additionally, most of the access to these summary tables was by a
custom-developed application. This simple application was able to be
coded directly against the summary tables. While that involved a bit
of education of the programmers - it didn't involve *any* work in
trying to figure out why DB2 was or wasn't rewriting a query properly.
Plus - some queries would never be eligible for rewrite anyway.

In my case manual summary tables have worked fine. However, I am
planning to implement some MQTs for an adhoc environment that I've
got. In this environment it isn't practical to educate the users or
customize the application to support a dozen summary tables - so DB2's
rewriting of queries is really the best choice.

buck

Nov 12 '05 #5
my*****@gmail.c om (Suresh) wrote in message news:<ef******* *************** ***@posting.goo gle.com>...
But, instead of maintaining a explict summary table and make sure it
is loaded properly, why not use an MQT and load it deferred and use
the MQT directly when querying.


Well, extra and unnecessary dependencies I suppose. My explicit
summary tables are very easy to manage and publish from. And - have
no dependencies on underlaying tables - which are tweaked about every
few months - either due to large data quality conversions or to major
feature upgrades.

buck
Nov 12 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
4804
by: Paul Reddin | last post by:
Hi, I am trying to investigate if some of our fairly complex views couldn't be materialised with MQT's. Unfortunately the error message returned when the fullselect is invalid is as shown at the bottom of this post. This message does little/nothing to help me(the user) understand what
17
1966
by: p175 | last post by:
If I have ESE 8.2.5, I assume v9 will be able to take such an installation and upgrade same without problems ? I'm investigating whether we can also use Express C as a development / test environment for same but am now reading that what I thought were key elements of DB2 are not supported in Express C, for example: MQT (Summary Tables) MDC tables
3
2309
by: jefftyzzer | last post by:
Friends, Say I have the following UDF: CREATE FUNCTION GET_MONTH(P_DATE DATE) RETURNS INTEGER INHERIT SPECIAL REGISTERS SPECIFIC GET_MONTH DETERMINISTIC BEGIN ATOMIC
2
5409
by: hello_db2 | last post by:
hello, db2advis gave me error like execution started at timestamp 2006-11-15-09.51.37.046473 Using the default table space name USERSPACE1 Recommending indexes... Recommending MQTs... Recommending Multi-Dimensional Clusterings... Found 6 user defined views in the catalog table
9
17562
by: Veeru71 | last post by:
Can someone point me to good documentation on 'WITH clause" ? (I couldn't get much out of Queries section from SQL Reference manual). We are getting better performance when we explicity use global temp tables to store intermediate results than using "WITH cluase" in our queries. Where does DB2 store the intermediate results if the query uses "WITH clause" ? Thanks
2
3425
by: jefftyzzer | last post by:
Friends: I've been working on tuning a fairly complex--and certainly vexing-- query. Several days ago I created an MQT which aided the query and dropped its cost from 3.4 million timerons to around 650,000, enabling the query to run in cir. 15 mins. For a variety of reasons, I've recently created another MQT on a different set of tables than those covered by the other one, which I've since dropped. Using this new MQT the query's cost...
1
1531
by: BD | last post by:
Hi there. I'm attempting to implement MQTs to improve performance on some nasty SQL. In the Oracle world, if I recall, materialized views must use tables as underlying objects - ie., they cannot be based on views. Does the same hold in db2 (8.2 LUW, 8 z/OS)?
3
3410
by: BD | last post by:
I'm doing some cross-platform development, under LUW 8.2 (Windows) for z/OS 8. I have some fairly complex queries which address some rather large tables. One query takes approximately 30 seconds to complete, once the result set has been loaded into buffer caches. The initial run of the query is about 2 minutes.
11
3446
by: peter | last post by:
I am trying to get a SQL stored procedure to use user maintained MQT implicitly which raises questions on when they are used or not used. In theory you would expect the stored procedure to pick up the MQT at the time it is bound on the creation of the static SQL. This raises the question on how you stop it or start it using a MQT as there is no option on the bind. What happens when it is rebound? What happens if the plan is made invalid...
0
9551
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10504
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10274
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10251
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9085
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7576
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6811
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5469
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
3
2945
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.