Level 2 Sprint 3 INV01 Allow Override of Shipping Method


In the INV01 Module we are asked to add the following 4 line items:


Override Shipping Method

Override Method

Final Shipping Method

Final Shipping Time Weeks


The format for Override Method & Final Shipping Method are both "Shipping Method". (List) 

In previous activities, I was told to utilize the "Shipping Methods" List.  I just want to make sure that I should be using the same list and perhaps there is a typo in the training.


Best Answer

  • JussiLi
    Answer ✓

    Line item formats are correct. 

    After the start "IF NOT Override Shipping Method OR ISBLANK (Override Method)" you have THEN and ELSE statements. Do both line items that are mentioned after THEN and ELSE have 'Shipping Methods' format?


  • JussiLi

    Hi @bleeds ,


    You should use the same list. There seems to be a typo in sprint instructions. 




  • bleeds

    Appreciate the response @JussiLi 


    The reason I asked is because I'm recieving the follwoing error when attempting to create the Final Shipping Method formula.


    "Datatypes do not match for the 'if' function: LIST: Shipping Methods, BOOLEAN


    My formula contains IF/THEN and isblank.


    The logic is basically IF Override shipping boolean is not selected then use the "Shipping Method" line item ELSE use the override method.


    Am I missing something in the formula to combine lists and booleans while using IF?

  • JussiLi

    @bleeds ,


    The logic in your formula is correct. It is missing one part (see following picture), but it's not the reason for error message. 


    I think format of one line item is incorrect which is causing error. 



  • bleeds

    Thanks again for the quick response and apologies I did include the isblank(Override method) within the formula.


    Within the formula I'm using below line items and formats.


    Shipping method - Format: Shipping Methods

    Override Shipping Method - Format: Boolean

    Override method - Format: Shipping Methods

    Final Shipping Method - Format: Shipping Methods


    These seem to be correct based on the instructions?

  • bleeds

    Thanks for the help!


    I was using "Override Shipping method" as opposed to "Override Method".  These naming conventions are super similar.

  • @bleeds 


    Hi I am having a similar issue with trying to add in the formula for the Final Shipping Method line item. I have this so far:


    IF NOT Override Shipping Method OR ISBLANK (Override Method) THEN Shipping Method ELSE 0


    However this is coming up as an error, any idea why? Any help would be great, thanks!

  • Hi @ifeldman,


    it is showing the error because you are using the ELSE value as a number instead of a Boolean


    Too late to the party, but I am also stuck at the same thing and trying to figure it out now. 


    If anyone can answer this please do tell me whether I need to change the actual formula for the "Shipping Method" line item. If yes, then using what logic.


    Thank you! 

  • @aftabkhan 

    I encountered similar error for constructing formula of Final Shipping Method but the 3rd point helped me figured out the correct formula of Final Shipping Method line item:


    • Start the formula: IF NOT Override Shipping Method OR ISBLANK (Override Method).

      here you need to put your line items exactly (for example a/c to activity Override Shipping Method is actually Override Shipping Method?) and also apply THEN , ELSE statements with correct arguments to complete this formula.

      Hope this helps.
  • Hi @mohdtazeem  I am struggling to correct the Final Shipping Method line item formula using the steps provided, so far I have the following - but this keeps returning an invalid error


    IF NOT Override Shipping Method? OR ISBLANK (Override Method) THEN Shipping Method ELSE 0


    Thanks in advance,

  • Hi @zainrehman please check and see if you are using the correct line items to construct the formula (there might be a typo because in prior steps and now line items name may slightly be different,  e.g. Override Shipping Method is Override Shipping Method? ). Also cross check line items format which you should have already set correctly.


    If you still  face any error, please post screenshots of error, your module and test steps so it can be more helpful to understand and help further 😊 


  • Hi @mohdtazeem i figured it was showing the error because I was using the ELSE value as a number instead of a Boolean - I changed this and it worked

  • @mohdtazeem and @zainrehman


    Can either of you further explain your logic below? 


    IF NOT Override Shipping Method? OR ISBLANK(Override Method) THEN Shipping Method ELSE 0


    ELSE "0" is a number, how can that be changed to boolean?