I have base64string (image logo), which I want to insert in db. In database the column type is varbinary. my query is
update Organization set MobileLogo='gjdgfkjgk...' where orgId=1676
The below error I am getting
Msg 257, Level 16, State 3, Line 1 Implicit conversion from data type varchar(max) to varbinary(max) is not allowed. Use the CONVERT function to run this query.
Code to convert image to base64
string imagePath = @"C:\Users\arvind.ch\Downloads\Icons\SISClient_iCons\Enrich.png";
string imgBase64String = GetBase64StringForImage(imagePath);
Here I want to store the image-
I need to have sql query to inset it to db not C# code. The URL's given above is all about C#