Hi,
I have some assembly files which need to be copied from production to datalist.Then assembly files needs to be stored in sql CLR.
Could anyone help on this.
Thanks,
Prasant
Store assembly files to Sql server 2005
1 Answer
Know the answer? Post it. Somebody with the same question will find it here.


Josip Juric118 reputationPosted Dec 7, 2010, 5:53 AM EST
For this problem is this procedure: First you need load your asembly files by using System.IO.BinaryReader class in memory: FileStream fs=new FileStream(@"myAssembly file name", FileMode.Open, FileAccess.Read); BinaryReader br=new BinaryReader(fs); byte[] assembly; assembly = br.ReadBytes((int)fs.Length); Then you insert data in sqlDataBase using ordinary sqlCommand(if you don't know sqlCommand's yust say).