dbTalk Databases Forums  

Limit timeframe of data processed by a cube

microsoft.public.sqlserver.olap microsoft.public.sqlserver.olap


Discuss Limit timeframe of data processed by a cube in the microsoft.public.sqlserver.olap forum.



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

Default Limit timeframe of data processed by a cube - 07-27-2006 , 11:59 AM






I have a cube created that looks at some metrics from a customer's
database. All fine and good, except it catches ALL the data in the DB,
when what I actually want is just the data in the last 7 days. Is there
a way to design the cube to grab only this data? If it takes a little
longer to process it shouldn't be a problem, as we are going to
schedule it to process late at night.

Thanks.


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

Default RE: Limit timeframe of data processed by a cube - 07-27-2006 , 12:32 PM






Hi,

You could a view to include the only last 7 days of data in your DB, and
build your cube from the view.

"Wannabe_Kiwi" wrote:

Quote:
I have a cube created that looks at some metrics from a customer's
database. All fine and good, except it catches ALL the data in the DB,
when what I actually want is just the data in the last 7 days. Is there
a way to design the cube to grab only this data? If it takes a little
longer to process it shouldn't be a problem, as we are going to
schedule it to process late at night.

Thanks.



Reply With Quote
  #3  
Old   
Jéjé
 
Posts: n/a

Default Re: Limit timeframe of data processed by a cube - 07-27-2006 , 12:52 PM



using the entreprise edition, you can create partitions.
1 partition for the history, 1 partition by month (or week) for the current
year.
then you can process 1 partition only instead of everything.

the standard edition don't support the partitions.
in this casem you can use the incremental loading.
you do a standard process of the cube, and, every day (or week...), you'll
do an incremental process to add only new rows in the cube
(but don't send 2 times the same rows, this cause the value to be counted 2
times)
you have to keep the last date/time sent in the cube and when you'll do the
incremental process you'll execute a query like select * from table where
insertdate > lastdate



"Wannabe_Kiwi" <amkessel (AT) gmail (DOT) com> wrote

Quote:
I have a cube created that looks at some metrics from a customer's
database. All fine and good, except it catches ALL the data in the DB,
when what I actually want is just the data in the last 7 days. Is there
a way to design the cube to grab only this data? If it takes a little
longer to process it shouldn't be a problem, as we are going to
schedule it to process late at night.

Thanks.




Reply With Quote
  #4  
Old   
Wannabe_Kiwi
 
Posts: n/a

Default Re: Limit timeframe of data processed by a cube - 07-27-2006 , 01:10 PM



They're using SQL Analysis 2000 Enterprise Edition, by the way.

The view idea I will keep in mind, but I don't want to add the extra
load to the server.

Partitions is where I'm thinking. Is there a way to do a logical window
as opposed to the static ones I see in the Analysis Manager (e.g. one
partition each for week1, week2, etc)?

Thanks!

Jéjé wrote:
Quote:
using the entreprise edition, you can create partitions.
1 partition for the history, 1 partition by month (or week) for the current
year.
then you can process 1 partition only instead of everything.

the standard edition don't support the partitions.
in this casem you can use the incremental loading.
you do a standard process of the cube, and, every day (or week...), you'll
do an incremental process to add only new rows in the cube
(but don't send 2 times the same rows, this cause the value to be counted2
times)
you have to keep the last date/time sent in the cube and when you'll do the
incremental process you'll execute a query like select * from table where
insertdate > lastdate



"Wannabe_Kiwi" <amkessel (AT) gmail (DOT) com> wrote in message
news:1154019577.059490.124390 (AT) p79g2000cwp (DOT) googlegroups.com...
I have a cube created that looks at some metrics from a customer's
database. All fine and good, except it catches ALL the data in the DB,
when what I actually want is just the data in the last 7 days. Is there
a way to design the cube to grab only this data? If it takes a little
longer to process it shouldn't be a problem, as we are going to
schedule it to process late at night.

Thanks.



Reply With Quote
  #5  
Old   
Wannabe_Kiwi
 
Posts: n/a

Default Re: Limit timeframe of data processed by a cube - 07-27-2006 , 01:43 PM



I'm actually looking into using DSO (Decision Support Objects) to
create a little program to be run every night that would create a
partition for the last seven days and process the cube.

Is there an easier way?

Wannabe_Kiwi wrote:
Quote:
They're using SQL Analysis 2000 Enterprise Edition, by the way.

The view idea I will keep in mind, but I don't want to add the extra
load to the server.

Partitions is where I'm thinking. Is there a way to do a logical window
as opposed to the static ones I see in the Analysis Manager (e.g. one
partition each for week1, week2, etc)?

Thanks!

Jéjé wrote:
using the entreprise edition, you can create partitions.
1 partition for the history, 1 partition by month (or week) for the current
year.
then you can process 1 partition only instead of everything.

the standard edition don't support the partitions.
in this casem you can use the incremental loading.
you do a standard process of the cube, and, every day (or week...), you'll
do an incremental process to add only new rows in the cube
(but don't send 2 times the same rows, this cause the value to be counted 2
times)
you have to keep the last date/time sent in the cube and when you'll dothe
incremental process you'll execute a query like select * from table where
insertdate > lastdate



"Wannabe_Kiwi" <amkessel (AT) gmail (DOT) com> wrote in message
news:1154019577.059490.124390 (AT) p79g2000cwp (DOT) googlegroups.com...
I have a cube created that looks at some metrics from a customer's
database. All fine and good, except it catches ALL the data in the DB,
when what I actually want is just the data in the last 7 days. Is there
a way to design the cube to grab only this data? If it takes a little
longer to process it shouldn't be a problem, as we are going to
schedule it to process late at night.

Thanks.



Reply With Quote
  #6  
Old   
Jéjé
 
Posts: n/a

Default Re: Limit timeframe of data processed by a cube - 07-27-2006 , 02:44 PM



yes, you can manage the partitions using DSO scripts.
in AS2000 when you create a partition, you have to specify the slice of the
cube associated to the partition.
so a moving window is difficult to manage.

I recommand to create 1 partition by week for the current year (and 1
partition by year for the history)
precreate these partitions (1 time creation process) if your time dimension
allready contain the weeks of the year. (generally the time dimension is
prefilled and contain future dates)
Then in your DSO script you'll just process the partition of the week.
Nothing more to do every night!!!

you can found some example on the web to manage partitions using DSO
scripts.
and also look at the API documentation in the BOL.


"Wannabe_Kiwi" <amkessel (AT) gmail (DOT) com> wrote

I'm actually looking into using DSO (Decision Support Objects) to
create a little program to be run every night that would create a
partition for the last seven days and process the cube.

Is there an easier way?

Wannabe_Kiwi wrote:
Quote:
They're using SQL Analysis 2000 Enterprise Edition, by the way.

The view idea I will keep in mind, but I don't want to add the extra
load to the server.

Partitions is where I'm thinking. Is there a way to do a logical window
as opposed to the static ones I see in the Analysis Manager (e.g. one
partition each for week1, week2, etc)?

Thanks!

Jéjé wrote:
using the entreprise edition, you can create partitions.
1 partition for the history, 1 partition by month (or week) for the
current
year.
then you can process 1 partition only instead of everything.

the standard edition don't support the partitions.
in this casem you can use the incremental loading.
you do a standard process of the cube, and, every day (or week...),
you'll
do an incremental process to add only new rows in the cube
(but don't send 2 times the same rows, this cause the value to be
counted 2
times)
you have to keep the last date/time sent in the cube and when you'll do
the
incremental process you'll execute a query like select * from table
where
insertdate > lastdate



"Wannabe_Kiwi" <amkessel (AT) gmail (DOT) com> wrote in message
news:1154019577.059490.124390 (AT) p79g2000cwp (DOT) googlegroups.com...
I have a cube created that looks at some metrics from a customer's
database. All fine and good, except it catches ALL the data in the DB,
when what I actually want is just the data in the last 7 days. Is
there
a way to design the cube to grab only this data? If it takes a little
longer to process it shouldn't be a problem, as we are going to
schedule it to process late at night.

Thanks.




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.