This question is locked. New answers and comments are not allowed.
I am new to OpenAccess/Data Access and am starting to use it because we have upgraded our database to store large files in FILESTREAM columns and as we already use Telerik controls I thought it might be good to use, plus Linq to SQL and Entity Framework don't seem to support FILESTREAM access via the Win32 API.
I have looked at the examples but they aren't suitable to my situation.
I am wondering if any example code can be provided to retrieve the FILESTREAM column and return a byte[] using the Win32 API? I presume I can't just get the column value using a typical Linq query like this:
using (CMSModel dc = new CMSModel(DcConfig.ConnString))
{
byte[] data = (from a in dc.CMS_tbFileVersions
where a.FileVersionId == fileId
select a.FileData).FirstOrDefault();
}
Also, how can I tell if the Win32 API is being used to retrieve the data rather than through T-SQL?
Thank you.
I have looked at the examples but they aren't suitable to my situation.
I am wondering if any example code can be provided to retrieve the FILESTREAM column and return a byte[] using the Win32 API? I presume I can't just get the column value using a typical Linq query like this:
using (CMSModel dc = new CMSModel(DcConfig.ConnString))
{
byte[] data = (from a in dc.CMS_tbFileVersions
where a.FileVersionId == fileId
select a.FileData).FirstOrDefault();
}
Also, how can I tell if the Win32 API is being used to retrieve the data rather than through T-SQL?
Thank you.