September 2, 2009 at 1:51 pm
Jack Corbett (9/2/2009)
Hey, I stumped Gail! Wasn't intentional but when TEXT/NTEXT/IMAGE was mentioned I wondered about Filestream.
Looks like the answer is 'No'
-- Document is a varbinary(max) Filestream column
Create Index idx_TestingFileStreamInclude ON Production.Document (rowguid) INCLUDE (Document)
Msg 1999, Level 16, State 1, Line 1
Column 'Document' in table 'Production.Document' is of a type that is invalid for use as included column in an index.
A normal varbinary(max) is perfectly valid as an include
Create Index idx_TestingVarbinaryInclude ON Production.ProductPhoto (ThumbnailPhotoFileName) INCLUDE (ThumbNailPhoto)
Works fine.
I looked in Books Online, both under filestream and under Create Index, limitation wasn't mentioned anywhere I looked. Didn't hunt too much, easier to try it out.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
September 2, 2009 at 2:41 pm
Gail,
Thanks for looking it up. I didn't think you could. I think I might have read something about in Paul Randal's blog.
Jack Corbett
Consultant - Straight Path Solutions
Check out these links on how to get faster and more accurate answers:
Forum Etiquette: How to post data/code on a forum to get the best help
Need an Answer? Actually, No ... You Need a Question
September 2, 2009 at 7:50 pm
%^$^&%#&
Forgot all about the 24 hrs of SQL. Sounds like the presenters did a good job.
Wayne
Microsoft Certified Master: SQL Server 2008
Author - SQL Server T-SQL Recipes
September 3, 2009 at 8:10 am
I love this one.
Q: Can I use this syntax in SQL?
A: No
Q: Why not?
__________________________________________________
Against stupidity the gods themselves contend in vain. -- Friedrich Schiller
Stop, children, what's that sound? Everybody look what's going down. -- Stephen Stills
September 3, 2009 at 9:31 am
Hey Jack,
FILESTREAM support is pretty patchy - the list of core features that don't support it, or support it with caveats is long indeed.
Quite apart from the fact that the data is stored on the file system, the datasize could exceed the 2GB maximum, and FILESTREAM data never makes it to buffer pool anyway (which would make integration with the indexing system tough!) I'm not sure what the case for using it would be anyway. Data which averaged 1MB or more in size wouldn't be a great choice for an INCLUDE: you'd get better performance streaming from the file system. Data which averages 256MB or less might be a different story in some edge cases, but then you wouldn't use FILESTREAM in the first place - just plain varbinary(max).
Paul
Paul White
SQLPerformance.com
SQLkiwi blog
@SQL_Kiwi
September 3, 2009 at 9:37 am
Shall I ? , i feel mean , but at the same time it is quite simple.
http://www.sqlservercentral.com/Forums/Topic781960-338-1.aspx
--edit : Fix URL
September 3, 2009 at 9:38 am
Dave Ballantyne (9/3/2009)
http://www.sqlservercentral.com/Forums/Topic781960-338-1.aspx%5B/url%5D%5B/quote%5D
I get a Page Not Found error from that address.
- Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
Property of The Thread
"Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon
September 3, 2009 at 9:42 am
GSquared (9/3/2009)
Dave Ballantyne (9/3/2009)
Shall I ? , i feel mean , but at the same time it is quite simple.http://www.sqlservercentral.com/Forums/Topic781960-338-1.aspx%5B/url%5D%5B/quote%5D
I get a Page Not Found error from that address.
I think this is the url: http://www.sqlservercentral.com/Forums/Topic781960-338-1.aspx#bm782245
September 3, 2009 at 9:45 am
GSquared (9/3/2009)
Dave Ballantyne (9/3/2009)
Shall I ? , i feel mean , but at the same time it is quite simple.http://www.sqlservercentral.com/Forums/Topic781960-338-1.aspx
I get a Page Not Found error from that address.
Sorry the was a CRLF after the URL marker....
http://www.sqlservercentral.com/Forums/Topic781960-338-1.aspx
September 3, 2009 at 9:51 am
Dave Ballantyne (9/3/2009)
Shall I? I feel mean ,but at the same time it is quite simple.http://www.sqlservercentral.com/Forums/Topic781960-338-1.aspx
Yikes!!!!
Paul White
SQLPerformance.com
SQLkiwi blog
@SQL_Kiwi
September 3, 2009 at 9:53 am
Lynn Pettis (9/3/2009)
GSquared (9/3/2009)
Dave Ballantyne (9/3/2009)
Shall I ? , i feel mean , but at the same time it is quite simple.http://www.sqlservercentral.com/Forums/Topic781960-338-1.aspx%5B/url%5D%5B/quote%5D
I get a Page Not Found error from that address.
I think this is the url: http://www.sqlservercentral.com/Forums/Topic781960-338-1.aspx#bm782245
Although he seems a bit confused, I vote no. You've already handed him the answer earlier in the thread, he just hasn't tried it. Perhaps reference him to your earlier suggestion again, without explicit code?
---------------------------------------------------------
How best to post your question[/url]
How to post performance problems[/url]
Tally Table:What it is and how it replaces a loop[/url]
"stewsterl 80804 (10/16/2009)I guess when you stop and try to understand the solution provided you not only learn, but save yourself some headaches when you need to make any slight changes."
September 3, 2009 at 10:11 am
Paul White (9/3/2009)
Hey Jack,FILESTREAM support is pretty patchy - the list of core features that don't support it, or support it with caveats is long indeed.
Quite apart from the fact that the data is stored on the file system, the datasize could exceed the 2GB maximum, and FILESTREAM data never makes it to buffer pool anyway (which would make integration with the indexing system tough!) I'm not sure what the case for using it would be anyway. Data which averaged 1MB or more in size wouldn't be a great choice for an INCLUDE: you'd get better performance streaming from the file system. Data which averages 256MB or less might be a different story in some edge cases, but then you wouldn't use FILESTREAM in the first place - just plain varbinary(max).
Paul
Thanks Paul.
It all makes sense, but it would be nice to have it documented somewhere, especially since TEXT/NTEXT/IMAGE are mentioned.
Jack Corbett
Consultant - Straight Path Solutions
Check out these links on how to get faster and more accurate answers:
Forum Etiquette: How to post data/code on a forum to get the best help
Need an Answer? Actually, No ... You Need a Question
September 3, 2009 at 10:30 am
Jack Corbett (9/3/2009)
It all makes sense, but it would be nice to have it documented somewhere, especially since TEXT/NTEXT/IMAGE are mentioned.
Oh I agree. But don't hold your breath for Books Online to be updated - I've waited three years so far for PARSENAME to be documented as non-deterministic...link - and that's with a written acknowledgement that it is incorrectly stated as always deterministic, and would be changed 'in the next BOL refresh'. Sigh.
Paul White
SQLPerformance.com
SQLkiwi blog
@SQL_Kiwi
September 3, 2009 at 10:54 am
Paul, I'd raise this issue again, and actually I'll make a note of it. They do update things, but it's a big book. I'm not surprised things fall through the cracks.
Viewing 15 posts - 7,846 through 7,860 (of 66,712 total)
You must be logged in to reply to this topic. Login to reply