Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Help with syntax in load statement

Hi Everyone,

I am new to this and first post so hello all

Please could someone help with the syntax for this script

Existing code:

LOAD

    BWKEY & '_' & mid(MATNR, findoneof(MATNR, '123456789')) as [Product Plant ID] ,     // Modified in v1.2

    LBKUM         as [Stock Quantity],

    VPRSV          as [Price Control Indicator], //Add in v2.71

What I want to add but do not know best syntax:

VERPR          as [Item Current MAP] where VPRSV = V

STPRS          as [Item Current MAP] where VPRSV = S

please could someone help me with this?

thanks!

1 Solution

Accepted Solutions
Not applicable
Author

Simple if statement should do. See below-

LBKUM         as [Stock Quantity],

VPRSV          as [Price Control Indicator], //Add in v2.71

if(VPRSV='S','STPRS',if(VPRSV='V','VERPR')) as [Item Current MAP]

Cheers,

Shyam

View solution in original post

2 Replies
Not applicable
Author

Simple if statement should do. See below-

LBKUM         as [Stock Quantity],

VPRSV          as [Price Control Indicator], //Add in v2.71

if(VPRSV='S','STPRS',if(VPRSV='V','VERPR')) as [Item Current MAP]

Cheers,

Shyam

Not applicable
Author

Hi Shyam,

Thanks very much for your help!

Rob