Describe the bug
If there's numbers that are generated with case() function, for some reason validate()` can't validate them but instead shows "Eval comparisons only allow using two numbers or two strings.".
Expected behavior
Numerical values shouldn't be an issue for validate().
How to reproduce
| makeresults count=4
| eval row=1
| accum row
| eval pets=case(row==1, "Jontti", row==2, "Bella", row==3, "Moto", row==4, 6)
| eval validate=validate(isstr(pets), "ERROR", pets=="Jontti", "No fluffy cats")
It should generate the following table:
| _time |
row |
pets |
validate |
| 2026-03-24T11:41:19.000+02:00 |
1 |
Jontti |
|
| 2026-03-24T11:41:19.000+02:00 |
2 |
Bella |
No fluffy cats |
| 2026-03-24T11:41:19.000+02:00 |
3 |
Moto |
No fluffy cats |
| 2026-03-24T11:41:19.000+02:00 |
4 |
6 |
No fluffy cats |
Values generated with case() are automatically string values so that's why 6 doesn't get the "ERROR" label.
Screenshots
Software version
pth_10 version: 12.1.1
Desktop (please complete the following information if relevant):
Additional context
Describe the bug
If there's numbers that are generated with
case()function, for some reason validate()` can't validate them but instead shows "Eval comparisons only allow using two numbers or two strings.".Expected behavior
Numerical values shouldn't be an issue for
validate().How to reproduce
It should generate the following table:
Values generated with
case()are automatically string values so that's why 6 doesn't get the "ERROR" label.Screenshots
Software version
pth_10 version: 12.1.1
Desktop (please complete the following information if relevant):
Additional context