on ‎2019 May 13 2:49 PM
I'm looking at updating a Flag of all products in a warehouse, warehouseId is a non unique key field, I tried
# Looking to update all products display flags of warehouse 231 to false
# Query where clause equivalent - where warehouseId = 231
UPDATE Product[batchmode=true];itemType(code)[unique=true];warehouseId;displayFlag[default='false'] ;Product;231;
The above impex updates all products to warehouseId 231, how can I update the displayFlag of all products belonging to a particular warehouseId?
PS: In my project, there is only online product catalog, no staging.
Request clarification before answering.
I'd try adding the unique qualifier to the warehouseId as well, like so:
UPDATE Product[batchmode=true;itemType(code)[unique=true];warehouseId[unique=true];displayFlag
;Product;231;
essentially any attributes that form the "where" part of your query need to be identified as unique when updating in batch mode.
Nice explainer here: https://help.sap.com/viewer/d0224eca81e249cb821f2cdf45a82ace/1811/en-US/1c8f5bebdc6e434782ff0cfdb0ca...
In theory - as implemented above the impex would have set all warehouseIds to 231 AND set displayFlag to false since batchmode will update all non-unique fields
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
| User | Count |
|---|---|
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.