Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I had three fields they are Group,Min,Max from one table. I had taken Group as field in the listbox,Min & Max as expression in same listbox like followin image:
- Now i want to store Min value of A in one variable and Max value in another variable after marking A
- If i select B i want to store Min value of B in one variable and Max value in another variable.
The four variables are like this vMInA,vMaxA,vMinB,vMaxB.
How to solve this problem
Hi Mr. Nokia,
I think you forgot the stars * in the search string. It must be '*A*'
like this
=if(wildmatch(GetFieldSelections(Group),'*A*'),min({<Group= {"A"}>}Value),'')
Stefan
Sorry i forgot to give...But what is the use of * here..And also we need to give maximum size for GetFieldSelection. B'coz by default it holds 6 selections of listbox. So i given like this...
=if(wildmatch(GetFieldSelections(Group,'',50),'*A*'),min({<Group= {"A"}>}Value),'')
Thanks a lot Swuehl....
* is a wildcard, i.e. *A* would match either A, AB, BA, BAB, ....
Please note that Groupnames must be unique even in part, so if you use Group name A and AA, this will be problematic.
Stefan
if data is as following if we get any problem when i write like this
v1=if(wildmatch(GetFieldSelections(Group,'',50),'*CureLaneP*'),min({<Group= {"CureLaneP"}>}Value),'')
v2=if(wildmatch(GetFieldSelections(Group,'',50),'*CureO2LevelAvgA*'),min({<Group= {"CureO2LevelAvgA"}>}Value),'')
| CureLaneP |
| CureO2LevelAvgA |
| CureO2LevelMaxA |
| CureO2LevelMinA |
| CureTimeActualA |
| CureTimeHighIntensityA |
| CureTimeLowIntensityA |
| CureToDemoldTimeA |
| CureZone1TempAvgA |
| CureZone1TempMaxA |
| CureZone1TempMinA |
| CureZone2TempAvgA |
| CureZone2TempMaxA |
| CureZone2TempMinA |
As long as you search in wildmatch with full group names, as you did in your two examples, this should be ok.
For example, if you would have an additional group CureLanePP and you would select only this one, expressions
v1=if(wildmatch(GetFieldSelections(Group,'',50),'*CureLaneP*'),min({<Group= {"CureLaneP"}>}Value),'')
v2=if(wildmatch(GetFieldSelections(Group,'',50),'*CureLanePP*'),min({<Group= {"CureLanePP"}>}Value),'')
would result in min values v1 and v2 set, while you would expect only the min value v2.
Thus, a group name shall not be a subset / part of another group name.
Stefan