Hi guys,
can anyone tell me how can i store pdf files and images in sql databse.
Thanks
sadhawan
0
Light Poster
Recommended Answers
Jump to PostYou will need to read the file in to a byte array; try using
System.IO.File.ReadAllBytes(filename);
Then pass this as a parameter to a varbinary(MAX) column in you DB.
Don't forget to store the filename and extension; if you store them seperately you will later be able to sort/filter on file …
All 2 Replies
Reply to this topic
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.