Numerical barcode is not a random number, but generated logically in the backend.
Example: 1025683256. In this number first 4 digits are category_id, last 2 digits are counter_id, middle ones are product_id.
Now when I scan the barcode, I want to search the item in database and display the item details.
So my question was should I save the barcode number in database and search the item in the database via barcode number? or just break the barcode number logic and search the item in database?