T O P I C R E V I E W |
the agony booth |
Posted - 20 February 2007 : 14:02:46 I started work on an assembly, written in C#, that could be added to MS SQL Server 2005 and return fully formatted forum posts from a stored procedure. My ultimate goal was to generate RSS directly from SQL 2005 using the FOR XML PATH directive.
Unfortunately, I just learned my hosting provider doesn't support CLR assemblies running within SQL 2005. So, I'm not going to continue work on this. But I'm sharing what I've done so far in the hopes that maybe someone will find it useful.
The C# code was original written by HuwR. I tweaked it here and there to get it to run under SQL 2005. All my modifications are marked with an "AW" comment in the code.
HOW TO USE:
- Download this zip file
- You can compile the SnitzUtility.csproj yourself within Visual C# 2005, or just copy SnitzUtility.dll from SnitzUtility/bin/Release/
- Add the SnitzUtility.dll assembly to your SQL Server using SQL Mgmt Studio
- Run the SQL script SnitzFormatStr.sql. This will create a function that calls FormatStr in the assembly
Once you do that, you can return fully formatted posts from SQL Server by calling the dbo.SnitzFormatStr function. In the SQL script is an example of how to call it. The syntax is a bit complicated right now. Maybe someone can figure out a way to streamline it a little.
< |
|
|