Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
panipat1990
Creator II
Creator II

Caluclate 80-20% in backend

Dear Team,

i stuck a requirement. i have three field item number Branch QTY. For this i am sharing data.

Requirment is:my Branch Field contain Delhi,Mumbai,Hydrabad,Banglore,

I want to caluclate Which qty exist in Delhi is divided in 80% in D1 AND 20% D2

Same For Mumbai IN 80% IN M1 AND 20%M2

Same For Hydrabad IN 80% IN H1 AND 20%H2

  Same For BangloreIN 80% IN B1 AND 20%B2 

1 Solution

Accepted Solutions
balar025
Creator III
Creator III

Hi,

You have to make 2 load of same data file. One for 80% and second for 20% as below

Load *,

left(State,1)&1 as Store,

Qty*0.8 as QtyNew

Resident Data;

Load *,

left(State,1)&2 as Store,

Qty*0.2 as QtyNew

Resident Data;

It will autoconcate your data.

Regards,

Ravi

View solution in original post

11 Replies
prat1507
Specialist
Specialist

Hi Can you please be  a little more clear as to where you need D1, D2,.....?

Regards
Pratyush

panipat1990
Creator II
Creator II
Author

Store 80% in D1 And Store 20% in D2 Of Total QTY IF branch is delhi

kusumanchir
Creator
Creator

Hi Gourav,

Please find the attached app and let me know if it is an expected output.

balar025
Creator III
Creator III

Hi,

You have to make 2 load of same data file. One for 80% and second for 20% as below

Load *,

left(State,1)&1 as Store,

Qty*0.8 as QtyNew

Resident Data;

Load *,

left(State,1)&2 as Store,

Qty*0.2 as QtyNew

Resident Data;

It will autoconcate your data.

Regards,

Ravi

panipat1990
Creator II
Creator II
Author

Dear Sir,

But i want to make D1 D2 AND M1 M2 AND B1 B2 Field Value.

If i select Delhi then it Selected D1 D2 Same AS Mumbai,Banglore

balar025
Creator III
Creator III

below script will help you. To achieve field value.

Load *,

left(State,1)&1 as Store,

Qty*0.8 as QtyNew

Resident Data;

Load *,

left(State,1)&2 as Store,

Qty*0.2 as QtyNew

Resident Data;

It will autoconcate your data.

kusumanchir
Creator
Creator

Hi Gourav,

I have modified such a way , single columns holds the M1,M2,D1,D2...

bharani8
Creator III
Creator III

Hi.. Check the attached file.. Is this what you were looking for?

kusumanchir
Creator
Creator

Hi Gourav,

I simplified the expression used in the script. please refer to the latest attachment.