INTERACT FORUM

More => Old Versions => JRiver Media Center 26 for Windows => Topic started by: Ferdi on August 22, 2020, 07:29:33 am

Title: Expression Language - Bug reading brackets? [solved - user error]
Post by: Ferdi on August 22, 2020, 07:29:33 am
I am trying to build a field that shows me

I use this to achieve that: IfElse(isequal([Rating], 0, 2),[Name],1,[Name] ([Rating]))

Output is correct when a rating exists, but includes a closing bracket if no rating exist. For example:
Is that a bug or a user error?
Title: Re: Expression Language - Bug reading brackets?
Post by: marko on August 22, 2020, 07:33:17 am
User error :)
brackets are a part of the expression language, so, those that you want to be part of your output must be escaped, like so...

IfElse(isequal([Rating], 0, 2),[Name],1,[Name] /([Rating]/))

https://wiki.jriver.com/index.php/Expression_Language#Expression_Language_Syntax
Title: Re: Expression Language - Bug reading brackets? [solved - user error]
Post by: Ferdi on August 22, 2020, 07:35:09 am
Thanks for quick reply and help of fixing this (like, within a minute?)!

(and thanks to zybex for Zelda https://yabb.jriver.com/interact/index.php/topic,125975.0.html)
Title: Re: Expression Language - Bug reading brackets? [solved - user error]
Post by: zybex on August 22, 2020, 03:05:17 pm
You're welcome  8)