Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Save an extra $150 Dec 1–7 with code CYBERWEEK - stackable with early bird : Register for Qlik Connect
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

I need help on Script

I am new to Qlikview and how to push the values into the script and i attached my .QVW file.

Thanks for the help

Advance,

1 Solution

Accepted Solutions
Not applicable
Author

Hi,

Add the below script on top of your FACT load as preceding load.

Load *,

if(IATP<Day7Forecast,IATP-Day7Forecast,0) as [1 Wk loss Units],

if(IATP<Day7Forecast,(IATP-Day7Forecast)*Avg12MonthsSalesPrice,0) as [1 Wk loss Dollers];

LOAD CONO&ITNO as Item_Key,

CONO as Company,

     DIVI as Division,

     WHLO as Warehouse,

     //Warehouse,

     StyleSizeColor,

     Style  as Style_FACT,

     Size AS Size_FACT ,

     Color,

     [Make/Buy Code] as Make_buy_FACT,

     PFence,

     LTime,

     PctTTM,

     SizeRank,

     ATPDate,

     ITNO,

     STQT,

     ALQT,

     IATP,

     ADFI,

     Avg12MonthsSalesPrice,

     Avg12MonthSalesQtyPerSale,

     CurrentForecast,

     Day7Forecast,

     Day14Forecast,

     Day21Forecast,

     Day28Forecast,

     Day56Forecast,

     Day84Forecast,

     Day112Forecast

FROM

[..\..\QVD\ATP\ATPFuture.qvd]

(qvd);

View solution in original post

7 Replies
Not applicable
Author

sorry what do you mean when you say "push"?

Not applicable
Author

Sorry I confused before.I have ATP chart  and i have one week loss Units and one week loss Dollars in my expression

how can i calculate the values of  expressions script it self.

Thanks for the Help in Advance

sasikanth
Master
Master

Hi Venkat

Didn`t get your requirement , can you plese explain us a bit briefly ...

Not applicable
Author

Hi SasiKanth,

                         As i mention above i have different expressions in my chart.My question was how to put the those expressions in to my Script editor.




Thanks for the help,

Advance.

Not applicable
Author

Hi,

Add the below script on top of your FACT load as preceding load.

Load *,

if(IATP<Day7Forecast,IATP-Day7Forecast,0) as [1 Wk loss Units],

if(IATP<Day7Forecast,(IATP-Day7Forecast)*Avg12MonthsSalesPrice,0) as [1 Wk loss Dollers];

LOAD CONO&ITNO as Item_Key,

CONO as Company,

     DIVI as Division,

     WHLO as Warehouse,

     //Warehouse,

     StyleSizeColor,

     Style  as Style_FACT,

     Size AS Size_FACT ,

     Color,

     [Make/Buy Code] as Make_buy_FACT,

     PFence,

     LTime,

     PctTTM,

     SizeRank,

     ATPDate,

     ITNO,

     STQT,

     ALQT,

     IATP,

     ADFI,

     Avg12MonthsSalesPrice,

     Avg12MonthSalesQtyPerSale,

     CurrentForecast,

     Day7Forecast,

     Day14Forecast,

     Day21Forecast,

     Day28Forecast,

     Day56Forecast,

     Day84Forecast,

     Day112Forecast

FROM

[..\..\QVD\ATP\ATPFuture.qvd]

(qvd);

sasikanth
Master
Master

hi

if you are calculating values based on the fields that are from diffrent tables then you cannot calculate these expressions in script unless if you go for concatinate or join

if from same table , then

TAB:

LOAD

"your expresssion" as <Alias-name>,

"your expression" as <Alias-name>,

.

.

.

.

From ....................................

..................................(qvd);

Not applicable
Author

Thanks a lot for your help Guys.