You can put this validation logic into "Create" method of \Nop.Admin\Controllers\ProductController.cs. Load a product by specified SKU ("_productService.GetProductBySku" method). If it already exists, then show a warning to a store owner.
P.S. Please do not duplicate forum topics (deleted)
I guess I don't understand...the SKU field allows any user input, whether you use the "manage inventory by attribute" or not, so you can easily supply unique SKU values for each product and/or their attribute combinations...
Or, are you looking for a way to automatically GENERATE random/unique SKU values for your inventory?
Or maybe you just want a method to ensure that you have not duplicated any SKU values for the products in your inventory? If so, New York's suggestion leads to a solution..otherwise, just use SSMS to query your products/productattributes tables.
Sir i just want to add logic in my controller so that whenever any duplicate SKU value will be inserted in the Sku field, it will generate a popup("Duplicate SKU not allowed") and then if any user add duplicate value, it will not be saved.