Hi @Peter_1985 ,
Welcome to Microsoft Q&A!
You could save your barcodes as datatype CHAR(<number of characters>) and not VARCHAR as VARCHAR is characters can vary in length and CHAR data does not.
If you're using actual product barcodes and they're really strings of 13 digits, a char(13) would probably be the most appropriate data type to store this data.
If you must store the graphical representation of the barcode for whatever reason, use a VARBINARY(MAX) field - gives you up to 2 GB of binary storage.
Best regards,
Melissa
If the answer is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.