11 Dec 2024 10:00 AM - last edited on 12 Dec 2024 08:22 AM by MaciejNeumann
the appVersion is 3.0.1.1234 (a.b.c.d- format). but, i need to get the appVersion as a.b.c. how to achieve that in here?
actually i achived that by using this code:
data record(appVersion = "3.0.2.1102")
| fieldsAdd versionParts = splitString(appVersion, ".")
| fieldsAdd truncatedVersion = concat(versionParts[0], ".", versionParts[1],".", versionParts[2])
but, i am unable to use this on my actual use case in userSessionQuery.
Help me in this regard
15 Dec 2024 09:18 PM
One option would be to use the parse command to parse out the version, like this:
| parse appVersion, "(INT '.' INT '.' INT):truncated_version"
Could you show the query where your solution is NOT working?