SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


The SQLCLR Impact


The SQLCLR Impact

Author
Message
Steve Jones
Steve Jones
SSC Guru
SSC Guru (150K reputation)SSC Guru (150K reputation)SSC Guru (150K reputation)SSC Guru (150K reputation)SSC Guru (150K reputation)SSC Guru (150K reputation)SSC Guru (150K reputation)SSC Guru (150K reputation)

Group: Administrators
Points: 150033 Visits: 19449
Comments posted to this topic are about the item The SQLCLR Impact

Follow me on Twitter: @way0utwest
Forum Etiquette: How to post data/code on a forum to get the best help
My Blog: www.voiceofthedba.com
ian.pettman
ian.pettman
Grasshopper
Grasshopper (21 reputation)Grasshopper (21 reputation)Grasshopper (21 reputation)Grasshopper (21 reputation)Grasshopper (21 reputation)Grasshopper (21 reputation)Grasshopper (21 reputation)Grasshopper (21 reputation)

Group: General Forum Members
Points: 21 Visits: 30
We have found no need to impliment clr, For us, SQL is about returning SETS and although it takes a mind flip to stop thinking procedurally and start with set based solutions only, it usually results in a substantial increase in performance. Materialised views are far more beneficial.
seatedElephant
seatedElephant
SSC-Enthusiastic
SSC-Enthusiastic (197 reputation)SSC-Enthusiastic (197 reputation)SSC-Enthusiastic (197 reputation)SSC-Enthusiastic (197 reputation)SSC-Enthusiastic (197 reputation)SSC-Enthusiastic (197 reputation)SSC-Enthusiastic (197 reputation)SSC-Enthusiastic (197 reputation)

Group: General Forum Members
Points: 197 Visits: 382
We have a data warehouse and reporting system running on SQL Server 2008R2 and we have not touched CLR yet. All our needs have been met via the 'traditional' T-SQL route with reporting implemented in SSRS.

Dave Morris Alien

"Measure twice, saw once"
call.copse
call.copse
SSCertifiable
SSCertifiable (5.7K reputation)SSCertifiable (5.7K reputation)SSCertifiable (5.7K reputation)SSCertifiable (5.7K reputation)SSCertifiable (5.7K reputation)SSCertifiable (5.7K reputation)SSCertifiable (5.7K reputation)SSCertifiable (5.7K reputation)

Group: General Forum Members
Points: 5685 Visits: 2013
In my experience it is a very occasionally useful part of the toolkit. I can think of two times it has been used in anger over the 8 odd years it has been available to me, and I cannot even remember what they were - perhaps something to do with regular expressions on one occasion.

The problem for me is that the use cases I can think of can generally be accomplished some other way, and the skills needed to make such functionality working are thus not really worth maintaining. Meaning, it leaves a mess that is perhaps slightly difficult for others to come to grips with when they come across it. Perhaps this is testament to how much functionality is actually covered by SQL Server OOTB.
P Jones
P Jones
SSCrazy
SSCrazy (2.9K reputation)SSCrazy (2.9K reputation)SSCrazy (2.9K reputation)SSCrazy (2.9K reputation)SSCrazy (2.9K reputation)SSCrazy (2.9K reputation)SSCrazy (2.9K reputation)SSCrazy (2.9K reputation)

Group: General Forum Members
Points: 2920 Visits: 1525
We're another "never used it" shop - there's always been another way so we haven't needed clr.
dUros
dUros
Old Hand
Old Hand (384 reputation)Old Hand (384 reputation)Old Hand (384 reputation)Old Hand (384 reputation)Old Hand (384 reputation)Old Hand (384 reputation)Old Hand (384 reputation)Old Hand (384 reputation)

Group: General Forum Members
Points: 384 Visits: 130
We use function made in VB.NET for write file from T-SQL directly to disk, usualy XML. :-)

Regards
freekk
freekk
SSC Rookie
SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)SSC Rookie (34 reputation)

Group: General Forum Members
Points: 34 Visits: 96
I have used CLR assemblies occasionally, sometimes to use regular expressions and sometimes for very specific ends. For example I've written an assembly for parsing compacted integers from AS400. I think for these very specific ends it's a very useful extension to Sqlserver. I agree with a previous poster set-based approach to data is preferred. Especially programmers should not misuse CLR assemblies to wire in procedural code as they sometimes also do in stored procedures. A very good apply of CLR's in my opinion is to bypass the use of xp_cmdshell as it can be dressed up with additional security and limits the extent of the code to the functions of the CLR only. I prefer file operations to be done by CLR's also because you have much more control over file formats, encoding etc. In my opinion CLR's have a very limited place but are potentially a very powerful addition to Sqlserver.
Gary Varga
Gary Varga
One Orange Chip
One Orange Chip (27K reputation)One Orange Chip (27K reputation)One Orange Chip (27K reputation)One Orange Chip (27K reputation)One Orange Chip (27K reputation)One Orange Chip (27K reputation)One Orange Chip (27K reputation)One Orange Chip (27K reputation)

Group: General Forum Members
Points: 27621 Visits: 6555
Only used in a prototype. A number of different options were considered. SQLCLR was not selected in the end. I am sure that there are some valid uses, however, there always seems to be another way. Some DBAs seem to think that opening up an instance like this would be opening the door to .NET developers. I would probably agree (says the .NET developer) ;-)

Gaz

-- Stop your grinnin' and drop your linen...they're everywhere!!!
bjorn 80987
bjorn 80987
Grasshopper
Grasshopper (16 reputation)Grasshopper (16 reputation)Grasshopper (16 reputation)Grasshopper (16 reputation)Grasshopper (16 reputation)Grasshopper (16 reputation)Grasshopper (16 reputation)Grasshopper (16 reputation)

Group: General Forum Members
Points: 16 Visits: 14
We've used it in a few cases, for specialized aggregates or to split an object into rows, but we don't access tables from within any CLR code I've seen. In most cases we've used it to significantly improve performance, in a few to make code more readable and maintainable. In the latter case, with one specific aggregate, we've had mixed performance results - one line of CLR code vs a 40 element expression, for a small (<100000 say) data set no difference in performance, but for large ones SQL sometimes generates a slower plan using the CLR - so its treating native aggregates differently from CLR ones in some circumstances.
richardoz
richardoz
Forum Newbie
Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)

Group: General Forum Members
Points: 8 Visits: 116
We have several assemblies that we built for performing some needed string manipulation like regular expressions, with enhanced lookups on the replacement expressions. We have also built several Aggregate functions that perform complex attribute weighting based on a configuration parameter. Together those two assemblies have saved us hundreds of hours and also kept our code more concise and maintainable. We have not needed to author any CLR stored procedures -- most of this kind of logic gets written in our app server layers.

Cheers

R. Oz.
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search