Checking for coincidence
-
- Posts: 37
- Joined: Fri Feb 21, 2014 9:55 am
- OLAP Product: Cognos TM1
- Version: 10.1
- Excel Version: 10
Checking for coincidence
Hello!
I have a question about the verification data on repetition
I have a cube, it has a column "Number", into it writes the number of products (string element, since the numbers happen different, for example: 10-25.15a). And have a lot of lines.
I need to check in the column "Number" that was not repeated numbers
for example, someone in line 10 wrote number "10-5a", and someone else in the line 100 wrote the same number. Then the message should appear in the next column "verification" that there are numbers that are repeated.
can have any any ideas?
I would be grateful for your help
I have a question about the verification data on repetition
I have a cube, it has a column "Number", into it writes the number of products (string element, since the numbers happen different, for example: 10-25.15a). And have a lot of lines.
I need to check in the column "Number" that was not repeated numbers
for example, someone in line 10 wrote number "10-5a", and someone else in the line 100 wrote the same number. Then the message should appear in the next column "verification" that there are numbers that are repeated.
can have any any ideas?
I would be grateful for your help
-
- Regular Participant
- Posts: 424
- Joined: Sat Mar 10, 2012 1:03 pm
- OLAP Product: IBM TM1, Planning Analytics, P
- Version: PAW 2.0.8
- Excel Version: 2019
Re: Checking for coincidence
Just a thought,Start with counter=0 then check with DIMIX(Dimname,Ele) =1 then counter=1
and manipulate code accordingly.Apologies if I am completely wrong,gurus might help.Thanks
and manipulate code accordingly.Apologies if I am completely wrong,gurus might help.Thanks
"You Never Fail Until You Stop Trying......"
-
- Posts: 37
- Joined: Fri Feb 21, 2014 9:55 am
- OLAP Product: Cognos TM1
- Version: 10.1
- Excel Version: 10
Re: Checking for coincidence
excuse me, but I can not understand what you mean,
DIMIX function applied to elements measuring, and it is necessary to check the data that we write by hand, that there is no repetition.
I wrote the formula:
[ ] = S: IF ( DB(....,'Number')@=' ', 'Ok', IF ( DB ( ..... 'Number')@= DB(....., DB(.....,'Number') ), 'repetition', ' Ok') );
But this formula is wrong to consider, always writes that data do not coincide, while writing identical data
DIMIX function applied to elements measuring, and it is necessary to check the data that we write by hand, that there is no repetition.
I wrote the formula:
[ ] = S: IF ( DB(....,'Number')@=' ', 'Ok', IF ( DB ( ..... 'Number')@= DB(....., DB(.....,'Number') ), 'repetition', ' Ok') );
But this formula is wrong to consider, always writes that data do not coincide, while writing identical data
-
- MVP
- Posts: 3241
- Joined: Mon Dec 29, 2008 6:26 pm
- OLAP Product: TM1, Jedox
- Version: PAL 2.1.5
- Excel Version: Microsoft 365
- Location: Brussels, Belgium
- Contact:
Re: Checking for coincidence
Hello
I would suggest to not do this through rules.
Use a TI process that evaluates the cells, and for example create a temporary dimension in which you insert the text entries.
Check if the entry already exists in de dimension (DIMIX function). If yes, you encounter a duplicate. If not, add to the dimension and continue.
When done, in the Epilog tab, remove that temporary dimension again.
I would suggest to not do this through rules.
Use a TI process that evaluates the cells, and for example create a temporary dimension in which you insert the text entries.
Check if the entry already exists in de dimension (DIMIX function). If yes, you encounter a duplicate. If not, add to the dimension and continue.
When done, in the Epilog tab, remove that temporary dimension again.
Best regards,
Wim Gielis
IBM Champion 2024-2025
Excel Most Valuable Professional, 2011-2014
https://www.wimgielis.com ==> 121 TM1 articles and a lot of custom code
Newest blog article: Deleting elements quickly
Wim Gielis
IBM Champion 2024-2025
Excel Most Valuable Professional, 2011-2014
https://www.wimgielis.com ==> 121 TM1 articles and a lot of custom code
Newest blog article: Deleting elements quickly
-
- MVP
- Posts: 600
- Joined: Wed Aug 17, 2011 1:19 pm
- OLAP Product: TM1
- Version: 9.5.2 10.1 10.2
- Excel Version: 2003 2007
- Location: York, UK
Re: Checking for coincidence
If
What constitutes "reasonably small" is something you will have to work out for yourself.
- you are only looking for uniqueness in the column - i.e. not across the 3rd, 4th or whatever dimensions
- there is a reasonably small number of records
What constitutes "reasonably small" is something you will have to work out for yourself.
-
- Posts: 37
- Joined: Fri Feb 21, 2014 9:55 am
- OLAP Product: Cognos TM1
- Version: 10.1
- Excel Version: 10
Re: Checking for coincidence
Maybe I have something wrong did, but in a dimension are not created the same elements
-
- Posts: 37
- Joined: Fri Feb 21, 2014 9:55 am
- OLAP Product: Cognos TM1
- Version: 10.1
- Excel Version: 10
Re: Checking for coincidence
I had in mind when I make a measurement with a TI
-
- MVP
- Posts: 3241
- Joined: Mon Dec 29, 2008 6:26 pm
- OLAP Product: TM1, Jedox
- Version: PAL 2.1.5
- Excel Version: Microsoft 365
- Location: Brussels, Belgium
- Contact:
Re: Checking for coincidence
IF you wanted to say, "in a dimension you can only insert an element once"Wirt wrote:Maybe I have something wrong did, but in a dimension are not created the same elements
then you are correct. If not, I don't understand your 2 posts above. Please be more clear and also please write more than 1 sentence per post.
Best regards,
Wim Gielis
IBM Champion 2024-2025
Excel Most Valuable Professional, 2011-2014
https://www.wimgielis.com ==> 121 TM1 articles and a lot of custom code
Newest blog article: Deleting elements quickly
Wim Gielis
IBM Champion 2024-2025
Excel Most Valuable Professional, 2011-2014
https://www.wimgielis.com ==> 121 TM1 articles and a lot of custom code
Newest blog article: Deleting elements quickly
-
- Posts: 37
- Joined: Fri Feb 21, 2014 9:55 am
- OLAP Product: Cognos TM1
- Version: 10.1
- Excel Version: 10
Re: Checking for coincidence
Sorry for the confusion
I meant that when I insert an element in the dimension using the TI, I can not insert two identical elements in one dimension. So I can not keep track of the same elements.
You wrote earlier:
<< Use a TI process that evaluates the cells, and for example create a temporary dimension in which you insert the text entries.
Check if the entry already exists in de dimension (DIMIX function) >>
I can not do "Check if the entry already exists in de dimension (DIMIX function)"
Because in the dimension can not be two identical elements.
For this reason, I wrote that did not understand your advice, how to check two identical elements in one dimension
Thank
I meant that when I insert an element in the dimension using the TI, I can not insert two identical elements in one dimension. So I can not keep track of the same elements.
You wrote earlier:
<< Use a TI process that evaluates the cells, and for example create a temporary dimension in which you insert the text entries.
Check if the entry already exists in de dimension (DIMIX function) >>
I can not do "Check if the entry already exists in de dimension (DIMIX function)"
Because in the dimension can not be two identical elements.
For this reason, I wrote that did not understand your advice, how to check two identical elements in one dimension
Thank
-
- MVP
- Posts: 3241
- Joined: Mon Dec 29, 2008 6:26 pm
- OLAP Product: TM1, Jedox
- Version: PAL 2.1.5
- Excel Version: Microsoft 365
- Location: Brussels, Belgium
- Contact:
Re: Checking for coincidence
Like I wrote, in the Metadata ta, check if the element already exists or not:
Code: Select all
If( Dimix ( 'Dimension', 'Element' ) = 0 );
#does not exist yet, add it
DimensionElementInsert( 'Dimension', '', 'Element', 'N');
Else;
# here you have the case of a duplicate value, take action ! like deleting the cell value for example
EndIf;
Best regards,
Wim Gielis
IBM Champion 2024-2025
Excel Most Valuable Professional, 2011-2014
https://www.wimgielis.com ==> 121 TM1 articles and a lot of custom code
Newest blog article: Deleting elements quickly
Wim Gielis
IBM Champion 2024-2025
Excel Most Valuable Professional, 2011-2014
https://www.wimgielis.com ==> 121 TM1 articles and a lot of custom code
Newest blog article: Deleting elements quickly