DSO Changing Source Table on existing cube partitions -
11-12-2003
, 07:13 PM
Hi,
I am attempting to change the source fact table for existing cube partitions
using VB. My code (below) seems to do everything except change the fact
table name referenced in the column list of the SELECT statement (during
processing). I can't seem to find the right property to change on
dsoPartition object. Your assistance is appreciated. Thanks.
DSO code
================================================== =======================
' Set Partition object and lock it.
'----------------------------------
Set dsoPartition = dsoCube.MDStores(vPnName)
dsoPartition.LockObject OlapLockWrite, "RAPTOR-E: The cube partition is
locked for the cube partition maintenance process."
' Change fact table.
' Get old value for Replace below.
vNewSourceTable = """RAPTORE"".""VO_FLEX_PRE_100_C100_F""" 'TODO
vOldSourceTable = dsoPartition.SourceTable
dsoPartition.SourceTable = vNewSourceTable
dsoPartition.SourceTableAlias = vNewSourceTable
dsoPartition.FactTable = vNewSourceTable
dsoPartition.FromClause = Replace(dsoPartition.FromClause, vOldSourceTable,
vNewSourceTable) dsoPartition.JoinClause = Replace(dsoPartition.JoinClause,
vOldSourceTable, vNewSourceTable) dsoPartition.SourceTableFilter =
Replace(dsoPartition.SourceTableFilter, vOldSourceTable, vNewSourceTable)
From AS processing log:
================================================== =======================
13/11/2003 11:01:24 AM 5782 Initiating transaction in
Database 'RAPTORE_0203P12'
13/11/2003 11:01:24 AM 5782 Processing Partition
'flex_pre_100_c00' Start time: 11:01:24 AM
13/11/2003 11:01:27 AM 5782 Initializing Partition
'flex_pre_100_c00'
13/11/2003 11:01:39 AM 5782 Partition
'flex_pre_100_c00' Execute : SELECT "RAPTORE"."VO_FLEXCAB_CUST_POST_F"."
BILLED_TIME_ID", "RAPTORE"."VO_FLEXCAB_CUST_POST_F"."CUST_ID", "RAPTORE"."
VO_FLEXCAB_CUST_POST_F"."CHANNEL_ID", "RAPTORE"."VO_FLEXCAB_CUST_POST_F"."
FIN_TIME_ID", "RAPTORE"."VO_FLEXCAB_CUST_POST_F"."ORG_UNIT_I D", "RAPTORE"."
VO_FLEXCAB_CUST_POST_F"."PHYSICAL_ID", "RAPTORE"."VO_FLEXCAB_CUST_POST_F"."
PRODUCT_ID", "RAPTORE"."VO_FLEXCAB_CUST_POST_F"."REVN_GENRTG_ID ", "RAPTORE"
.."VO_FLEXCAB_CUST_POST_F"."CUST_SPORTF_ID", "RAPTORE"."
VO_FLEXCAB_CUST_POST_F"."SOURCE_ID", "RAPTORE"."VO_FLEXCAB_CUST_POST_F"."
QTY"
FROM "RAPTORE"."VO_FLEX_PRE_100_C100_F", "RAPTORE"."VO_FIN_TIME_D",
"RAPTORE"."VO_SOURCE_D"
WHERE ("RAPTORE"."VO_FIN_TIME_D"."TIME_CAL_MTH_NBR"=? ) AND ("RAPTORE"."
VO_FIN_TIME_D"."TIME_ID"="RAPTORE"."VO_FLEX_PRE_10 0_C100_F"."FIN_TIME_ID")
AND ("RAPTORE"."VO_FIN_TIME_D"."TIME_FIN_QTR_NBR"=? ) AND ("RAPTORE"."
VO_FIN_TIME_D"."TIME_FIN_YR_CODE"=?) AND ("RAPTORE"."VO_SOURCE_D"."
SOURCE_MBR_KEY_LVL02"=?) AND ("RAPTORE"."VO_SOURCE_D"."SOURCE_ID"="RAPTORE"
.."VO_FLEX_PRE_100_C100_F"."SOURCE_ID") AND ("RAPTORE"."VO_SOURCE_D"."
SOURCE_MBR_KEY_LVL01"=?)
13/11/2003 11:01:39 AM 5782 Data source provider
error: ORA-00942: table or view does not exist; Time:13/11/2003 11:01:39 AM
13/11/2003 11:01:39 AM 5782 Data source provider
error: ORA-00942: table or view does not exist; Time:13/11/2003 11:01:39 AM
13/11/2003 11:01:39 AM 5782 Processing Partition
'flex_pre_100_c00' failed. No changes have been made to the database.
13/11/2003 11:01:39 AM 5782 Rolling back transaction in
Database 'RAPTORE_0203P12'
Regards,
James Yeo |