Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hey all
I would have a field with Articlenumber. I would like to concat those articlenumbers according to my current selection in order to use it in Set Analysis. For this purpose i'll have to delimit the fields like 'X', 'Y', 'Z'. Any idea how to go about this?
all the best
Sebastian
Hi
Its a little easier if you put it in a variable, but you should be able to do this:
=sum({<[Article Number]={"$(=chr(39) & Concat([Article Number], chr(39) & ',' & chr(39)) & chr(39))"}>} ....
with the variable defined above:
=sum({<[Article Number]={"$(vConcatArticle)"}>} ....
HTH
Jonathan
Hi Sebastian,
Can you please provide a sample to understand your exact requirement?
Hi
In script:
concatArticle:
LOAD chr(39) & Concat(ArticleNumber, chr(39) & ',' & chr(39)) & chr(39) As concatArticle
Resident Data
Where ......(some conditions if required)
Let vConcatArticle = Peek('concatArticle');
Drop Table concatArticle;
or from front end:
Set vConcatArticle = =chr(39) & Concat(ArticleNumber, chr(39) & ',' & chr(39)) & chr(39)
(double == sign is not a typo)
HTH
Jonathan
Hi Jonathan,
Your solution is delivering exactly what i want if i put the term =chr(39) & Concat([Article Number], chr(39) & ',' & chr(39)) & chr(39) into a textbox.
Unfortunately, if I want it to use it in SetAnalysis it won't work:
=sum({<[Article Number]={chr(39) & Concat([Article Number], chr(39) & ',' & chr(39)) & chr(39)}>}[MSEG.Menge Wareneingang Gutteile])
I tried it like this, because i didn't exactly understand your front end solution with the Set vConcatArticle...
Could you maybe rephrase how to first create the variable and then use it in the Set?
Thank you very much!
Hi
Its a little easier if you put it in a variable, but you should be able to do this:
=sum({<[Article Number]={"$(=chr(39) & Concat([Article Number], chr(39) & ',' & chr(39)) & chr(39))"}>} ....
with the variable defined above:
=sum({<[Article Number]={"$(vConcatArticle)"}>} ....
HTH
Jonathan
Hi
Sebastian Schuler wrote:
I tried it like this, because i didn't exactly understand your front end solution with the Set vConcatArticle...
I always define variables like that in my load script. Use the Set expression as a line in your load script exactly like this:
Set vConcatArticle = =chr(39) & Concat(ArticleNumber, chr(39) & ',' & chr(39)) & chr(39);
Or define it in the variable overview as
=chr(39) & Concat(ArticleNumber, chr(39) & ',' & chr(39)) & chr(39)
(the leading = is important)
HTH
Jonathan
Hi Jonathan
Finally i got it. Your Solution was almost right. I just had to leave away the quotation marks. When i wrote it like this, it worked:
=sum({<[Article Number]={$(vConcatArticle)}>}
Thanks again!!
cheers
Sebastian