Quantcast
Channel: Answers by "ChandlerDBA"
Viewing all articles
Browse latest Browse all 6

Answer by ChandlerDBA

$
0
0
That's a big question to ask. Firstly, I agree with Usman - sounds like an OLAP system. Materialised Views could be excellent too - although you need to be aware of the penalty of keeping them up to date (making them "on commit refresh" can cause an absolutely massive performance hit on inserts and updates, but you should be able to use a "fast" or "complete" refresh model here following each data load). Taking just one of the subjects, if you have partitioning licensed then it is a very efficient way to manage data as you can simply drop off old partitions when they are no longer required. You can even swap them out of your Fact table and swap them into an Archive table if you design it well. You need to think carefully about your partition (and possibly sub-partition) keys. You need to pick a column or columns which are queried frequently and will allow "partition elimination". Date is usually up there, and possibly a sub partition by transaction type for you. I would look to partition into as small a logical chunk as reasonable. You look like daily partitioning might be a good idea. A few hundred is very managable and normal. Subpartitioned by, say, 20 transaction types and you have less than 10,000 partitions. That's not unusual. (I know one site which does 30,000 partition swaps per day). If you are querying by a day or two, then Oracle will automatically exclude 364 of the partitions and not consider them. By a subpartition of status, you might only be reading 50,000 rows instead of 50,000,000. That can provide considerable performance benefits. You also need to think about your indexing strategy, and also the statistics gathering strategy. Do you need global indexes across all partitions or can you get away with partition level indexes (which confers some benefits). As for gathering stats, this can be a minefield and you need to look at how you get the good-enough stats on each partition and at what point. Geting that right will really help your query optimisation. I think Doug Burns did some good blog posts on this (google his website.) HTH @ChandlerDBA

Viewing all articles
Browse latest Browse all 6




Latest Images