SQL Server 2008 Filestream Question - Anyone familiar?

Posted on 2013-09-23
Medium Priority
Last Modified: 2013-10-08
Hello all,

So I setup the filestream attribute on a server and it looks setup correct.   I have a filegroup etc.    The question I have is the setup entailed still using a varbinary(max) along with unique Guid column.  I am noticing the files get created on the filesystem itself as expected.   One of the database guys though did a length check on the content field I have which is the varbinary(max) along with filestream attribute.   The length of that field coming back through query analyzer is the same size as the physical file being stored.   So for example a 4 meg file showing the length of that content field as 4 meg as well as the file is on the server.  

Am I correct in my assumption and some reading that although the length is showing 4 meg the actual file size is not growing on the data file itself it is showing that via the filegroup down to the physical file?   I am just trying to explain that we are not duplicating the size as it does look that way if you do a length check of the content filestream field.

Thanks all.
Question by:sbornstein2
1 Comment
LVL 13

Accepted Solution

sameer2010 earned 2000 total points
ID: 39515465
I believe, DATALENGTH would give you length needed based on the actual data saved on the file server and not based on the column data.

Featured Post

Train for your Pen Testing Engineer Certification

Enroll today in this bundle of courses to gain experience in the logistics of pen testing, Linux fundamentals, vulnerability assessments, detecting live systems, and more! This series, valued at $3,000, is free for Premium members, Team Accounts, and Qualified Experts.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

     When we have to pass multiple rows of data to SQL Server, the developers either have to send one row at a time or come up with other workarounds to meet requirements like using XML to pass data, which is complex and tedious to use. There is a …
In this article we will get to know that how can we recover deleted data if it happens accidently. We really can recover deleted rows if we know the time when data is deleted by using the transaction log.
SQL Database Recovery Software repairs the MDF & NDF Files, corrupted due to hardware related issues or software related errors. Provides preview of recovered database objects and allows saving in either MSSQL, CSV, HTML or XLS format. Ensures recov…
Stellar Phoenix SQL Database Repair software easily fixes the suspect mode issue of SQL Server database. It is a simple process to bring the database from suspect mode to normal mode. Check out the video and fix the SQL database suspect mode problem.

621 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question