This field is required.
Only these extensions are allowed(.jpg, .JPG, .jpeg, .JPEG, .gif, .GIF, .png, .PNG)
Tags cannot contain the characters ' /, \\, #, ?, or ; >,< '
Only these extensions are allowed(.zip,.ZIP,.pdf,.PDF,.qvf,.QVF,.qvw,.QVW)
Discussion Board for collaboration related to QlikView App Development.
Hi I'm trying to change a data value from one text to another. I've tried below but it doesn't seem to work:
If(Field = 'A', 'B', Field) as Field
Any ideas how I can change the text? thanks!
The problem is that you are trying to transform where the sql statement is made and at that point it does not accept qlik transformations.
as Youssef is explaining, this transformation must be done in the LOAD instruction so you should have something close to this:
If(Field = 'A', 'B', Field) as Field;
sql select Field from dbo.table;
If(Field = 'A', 'B', Field) as Field,
sql select * from dbo.table;
i hope it works for you !!!
View solution in original post
you're trying to load using your DB engine or Qlik engine ?
1. loading using your DB engine, you should use your ENGINE SYNTAX, for SQL DB for example, you should use SQL SELECT and continue the transformation using it's specific syntax.
2. with Qlik engine, you should use LOAD statement
So if you're using Qlik engine, just replace SELECT with LOAD
table: LOAD *, If(Field = 'A', 'B', Field) as Field; SQL SELECT * FROM
Try using case statement
Case WHEN Field = 'A' THEN 'B' ELSE Field END as Field