If you are unable to create a new account, please email support@bspsoftware.com

 

** RESOLVED ** Case Statment: UDA-SQL-0358 Line 3: Syntax error near "=". Error

Started by locus, 01 Oct 2014 04:57:12 AM

Previous topic - Next topic

locus

Hi Folks,

I see this issue mentioned elsewhere but always as a filter it seems.

When trying to add this statement as a query calculation in RS, if nothing in the report references it, it validates in isolation.

CASE WHEN([Data Item 1] IN (1,2)) THEN (CASE WHEN([Data Item2] <= [Data Item3])
THEN ([Data Item 1] = 1)
ELSE ([Data Item 1] = 2)
END)
ELSE ([Data Item 1]= 3)
END



When referenced in the report by other objects, this error

UDA-SQL-0358 Line 3: Syntax error near "=".

Syntax looks OK to me.
The same happens if I add as a query item in Framework manager and try to test it.

Any ideas? Database is Informix. Running BI 10.2.1

Locus

MFGF

Quote from: locus on 01 Oct 2014 04:57:12 AM
Hi Folks,

I see this issue mentioned elsewhere but always as a filter it seems.

When trying to add this statement as a query calculation in RS, if nothing in the report references it, it validates in isolation.

CASE WHEN([Data Item 1] IN (1,2)) THEN (CASE WHEN([Data Item2] <= [Data Item3])
THEN ([Data Item 1] = 1)
ELSE ([Data Item 1] = 2)
END)
ELSE ([Data Item 1]= 3)
END



When referenced in the report by other objects, this error

UDA-SQL-0358 Line 3: Syntax error near "=".

Syntax looks OK to me.
The same happens if I add as a query item in Framework manager and try to test it.

Any ideas? Database is Informix. Running BI 10.2.1

Locus

Yup. It doesn't like your assignation (eg [Data Item 1] = 3)

Perhaps try:

CASE WHEN([Data Item 1] IN (1,2)) THEN (CASE WHEN([Data Item2] <= [Data Item3])
THEN (1)
ELSE (2)
END)
ELSE (3)
END
Meep!