I get a base 64 string from a XML file which I want to insert into my SQL Server database. Which field type have the field in my database to be? varbinary(MAX)? Do I have to convert the base 64 string to another format before inserting into my database?
Best regards
Since it’s a string and a string is a string is a string, you should be able to put it into a
VARCHAR(x)orVARCHAR(MAX)field without any problems.The “sized”
VARCHAR(x)has a max. length of 8000 characters, whileVARCHAR(MAX)tops out at 2 GB (2**31-1 byte) of size.