Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
bharatkishore
Creator III
Creator III

Load dimension in particular order

Hi All,

I have a dimension called channel and in that i have fields like a,b,c,d,e.. Now i want to load in particular order like.

e,b,c,a,d..

Can you please tell me how can i achieve it.

Thanks,

Bharat

1 Solution

Accepted Solutions
kaushiknsolanki
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi,

When you say load, do you mean while showing on frontend it should be shown in defined order?

if yes then you can use the Expression option under sorting tab.

The expression will be like this.

If(Value = 'e',1,

If(Value = 'b',2,

If(Value = 'c,3,

If(Value = 'a',4,

If(Value = 'd',5,....

Regards,

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!

View solution in original post

9 Replies
kaushiknsolanki
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi,

When you say load, do you mean while showing on frontend it should be shown in defined order?

if yes then you can use the Expression option under sorting tab.

The expression will be like this.

If(Value = 'e',1,

If(Value = 'b',2,

If(Value = 'c,3,

If(Value = 'a',4,

If(Value = 'd',5,....

Regards,

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!
effinty2112
Master
Master

Hi Bharat,

                    Try something like:

Temp:

Load

Channel,

Match(Channel,'e','b','c','a','d',..) as LoadOrder,

.

.

;

Data:

Load

Channel, //exclude LoadOrder field or else load * withNoConcatenate

.

.

Resident Temp Order by LoadOrder;

Drop Table Temp;

Cheers

Andrew

bharatkishore
Creator III
Creator III
Author

Thanks a lot...Slight confusion..

bharatkishore
Creator III
Creator III
Author

Thanks a lot Andrew..

kaushiknsolanki
Partner Ambassador/MVP
Partner Ambassador/MVP

Yes Please tell me whats the confusion.

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!
bharatkishore
Creator III
Creator III
Author

No.. i m saying that i am bit confused because  i have done this but i forget...

kaushiknsolanki
Partner Ambassador/MVP
Partner Ambassador/MVP

Okies.

Cheers..

Regards,

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!
its_anandrjs

Thanks Andrew,

What if when there is 120 values in single field and required to load in the proper order.

Regards,

Anand

effinty2112
Master
Master

Hi Anand,

                    If the load order was defined in a separate table of 120 values in the order we want we can load this first table with an autonumber field. The fact table can then be loaded as a temp table with an autonumber field on this dimension and then the facts can be loaded from this temp resident table ordered by that autonumber field.

Cheers

Andrew