web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Suggested Answer

Duplicate Products Due to Leading Zero in Barcode

(3) ShareShare
ReportReport
Posted on by 6

Hi all,

 

We accidentally uploaded product data from another store into our current D365 F&O environment, which created duplicate items with only one difference: the barcode.

 

Example:

 

  •  

    0788821150202 (from another store)


  •  

    788821150202 (our correct one)




  •  
  •  
 

Same product name, but different prices and transactions. The wrong one is already linked to purchase/sales orders, so deletion isn’t possible.

 

Problems:

 

  •  

    Duplicate SKUs


  •  

    Wrong item used at POS


  •  

    Pricing conflicts




  •  
  •  
 

Looking for advice on:

 

  •  

    Merging or handling duplicates safely


  •  

    Preventing this in the future


  •  

    Keeping system clean without breaking references




  •  
  •  
 

Has anyone fixed this before? Any help would be appreciated.

 

Thanks,

Ghulam Ahmed

Categories:
I have the same question (0)
  • André Arnaud de Calavon Profile Picture
    300,911 Super User 2025 Season 2 on at
    Hi Ghulam,
     
    This is a serious challenge. Are you able to restore a database back in time before the import was executed or does that have too much of impact as well?
     
    Correcting the data will be very hard. You mentioned the creation of purchase and sales orders. What is the status of these? If postings were done, do these also have wrong prices?
     
    You would need to identify all tables and records which are incorrect. Then you can check if a correction job can be written. There can be two approaches: 
    • Merging the released products
    • Replacing the wrong item on all transactions with the correct one. 
    Both will require deep testing and validating all related tables. Both approaches will require to run a consistency check with the option Correct for the inventory module to get the on-hand recalculated correctly. 
     
    In future you can prevent it by implementing additional validations on the barcode table. E.g. not allowing a leading zero or a maximum number of characters. There are barcode mask options where you can set a maximum length and it can validate a check digit. 
     
     
  • Suggested answer
    Satyam Prakash Profile Picture
    961 on at

    To resolve the duplicates, deactivate the incorrect items by stopping them in all dimensions, renaming them (e.g., “Do Not Use”), and removing them from POS, catalogs, and price lists. Keep them for historical reference, but prevent future use. Enforce barcode uniqueness, validate all imports in a staging environment, and implement checks in your data templates to avoid similar issues as we advance.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

#1
Martin Dráb Profile Picture

Martin Dráb 660 Most Valuable Professional

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 549 Super User 2025 Season 2

#3
Sohaib Cheema Profile Picture

Sohaib Cheema 307 User Group Leader

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans