Search code examples
sap-commerce-cloudimpex

How to configure customer specific pricing in SAP Hybris through impex?


I want to show the different price for a product to different customer groups in the Hybris. How to achieve this through Impex?


Solution

  • You can create UserPriceGroup and assign it to the price rows and customer/b2bunit

    INSERT_UPDATE UserPriceGroup ; code[unique=true] ; name[lang=en]
                                 ; group1            ; "Group 1"    
                                 ; group2            ; "Group 2"  
    
    INSERT_UPDATE PriceRow ; product(code, $catalogVersionStaged)[unique=true] ; currency(isocode)[unique=true] ; price  ; net[unique=true,default=false] ; ug(code)[allownull=true] ; unit(code)[default=pieces]
                           ; PRODUCT-1                                         ; CAD                            ; 90.00  ; false                          ; group1                   ;                           
                           ; PRODUCT-1                                         ; CAD                            ; 100.00 ; false                          ; group2                   ;                           
    
    UPDATE Customer ; uid[unique=true] ; Europe1PriceFactory_UPG(code)
                    ; cus1             ; group1                       
                    ; cus2             ; group2
    

    find the detailed answer here