Qlik Community

Ask a Question

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
On Demand Webinar: See Why Thousands of QlikView Users Have Switched to Qlik Sense. REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
kkarlste
Contributor II
Contributor II

if Skript

Hi

I want multiplication -1 if toimintoalue >= 006.


This bold skript is a new.

If I comment this bold skript this works ok


//FUNCTIONALAREAS

FunctionalArea:

LOAD "FKBER Functional Area" as TOIMINTOALUE,

if("FKBER Functional Area" >= '006',"TURNOVER Sales of the period"  *-1),

// "TURNOVER Sales of the period" *

    "TXTMD Medium description"  as ToimintoSelite,

    "FKBER Functional Area"&'  '&"TXTMD Medium description" as FunctionalAreaSort, //13.10.

    if("FKBER Functional Area" > '009','Toimihenkilöt',if("FKBER Functional Area" = '006', 'Palkansaajat')) as FuncAreaGroup,

    if(FunctionalAreaLevel = 'CB0', 'SI CB', if(FunctionalAreaLevel = 'CB1', 'CU CB', if(FunctionalAreaLevel = 'CB2', 'DI CB', if(FunctionalAreaLevel = 'CB3', 'CO CB', FunctionalAreaLevel)))) as FunctionalAreaLevel,

    Turnover,

    CB0,

    CB1,

    CB2,

    CB3,

    AUC;

SQL SELECT *

FROM ISSQlikView.dbo."tb_src_SAP_MasterData_Functional_Area_2017";

ERROR MESSAGE

ERROR.JPG

14 Replies
prma7799
Master III
Master III

TURNOVER Sales of the period this field is missing in your  Database table tb_src_SAP_MasterData_Functional_Area_2017

ahaahaaha
Master
Master

Hi,

Try

if("FKBER Functional Area" >= '006',"Turnover Sales of the period"  *-1),

kkarlste
Contributor II
Contributor II

and now I skipt this Turnover

if("FKBER Functional Area" >= '006',"Sales of the period"  *-1),

and this error

Field not found - <Sales of the period>

SQL SELECT *

FROM ISSQlikView.dbo."tb_src_SAP_MasterData_Functional_Area_2017"

prma7799
Master III
Master III

first Load full table into in qvd Like

Test:

SQL SELECT *

FROM ISSQlikView.dbo."tb_src_SAP_MasterData_Functional_Area_2017";

Store Test into  [FolderPath\Test.qvd(qvd)];


then check your filed name withe  Test table .

kkarlste
Contributor II
Contributor II

SQL.JPG

arvind_patil
Partner
Partner

Hi Kalle,

It may be filed name has changed in base data.

first load full table and check the name its vary from your previous one.

Thanks,

Arvind Patil

ahaahaaha
Master
Master

QlikView don't find field [Sales of the period] in your SQL base. You need to determine how the required field is named in the SQL base.

prma7799
Master III
Master III

remove SQL word from select statement and execute query 

fvelascog72
Partner
Partner

Hi,

Don´t write SQL at the beginning. Just SELECT.

Cheers.