Skip to main content
Filter by
Sorted by
Tagged with
2 votes
1 answer
378 views

We have a legacy application that uses SQL Server as its back-end. As part of some security concerns, it encrypts some fields collected from the user using (single) DES with a key & IV that is ...
-3 votes
3 answers
181 views

How can I convert below VB.net SQL CLR function to C# CLR Function for a VS SSDT SQL Project? I need to convert it to C# as it seems that built-in SSDT Project support for CLR functions is C# only? If ...
2 votes
2 answers
379 views

So I am quickly learning the ways of C# (complete noob that inherited this problem); I have written up the following code which calls a web service that returns JSON that is not always well-formed. ...
17 votes
2 answers
2k views

I noticed when trying to code a CLR procedure for SQL Server that HashSet is not allowed due to being attributed with [HostProtectionAttribute(SecurityAction.LinkDemand, MayLeakOnAbort = true)]. SQL ...
1 vote
0 answers
738 views

I created a SQL CLR stored procedure that is triggered when an INSERT happens in the database. The stored procedure then uses HttpWebRequest to make an API JSON POST. The problem is that API uses SSL ...
7 votes
3 answers
6k views

I need to load an Assembly in AWS SQL Server 2017 RDS. I am not able to find it in the documentation. Is this possible? If yes, then how? This is similar to, but not a duplicate of, "SQL Server CLR ...
0 votes
0 answers
93 views

Am trying to create a CLR function and inside am using below quartz.net code snippet public static class SqlCron { [SqlFunction(IsDeterministic = true, IsPrecise = true)] public static ...
0 votes
1 answer
717 views

After db restoring on other server the Service Broker is stopped. The restored db has a Trustworthy Off and now I set it to On to run Broker again. I understand that it is bad practice. Especially ...
3 votes
2 answers
623 views

I was using the VS 2019 to debug a SQL Server CLR C# .NET code. I got an upgrade notification from VS which I did and rebooted. I now get the error when trying to debug Unable to debug .NET code. ...
1 vote
2 answers
508 views

I've come across an undocumented Production server with the Assemblies listed below. Any ideas how to reverse engineer the DBFunctions assembly or reproduce it on another SQL Server instance?
14 votes
1 answer
5k views

Can .Net Core 3 assemblies be used in SQL CLR? And if not so, what will happen with the arrival of .Net 5? Or is it only possible to use only .Net Standard 2 and implement it as >net Framework?
0 votes
0 answers
231 views

Is there any way to implement change data capture on SQL to Azure EventHub without using exe? The code needs to run in the context of SQL Server only SQL Server Version : 2014 Tried SQL CLR with Azure ...
0 votes
2 answers
5k views

I created user defined type in C#. When I run this: EXEC sp_configure 'clr enabled', 1; RECONFIGURE; GO EXEC sp_configure 'show advanced option', '1'; RECONFIGURE; GO USE ...
5 votes
2 answers
838 views

I have written the following SQL CLR function in order to hash string values larger then 8000 bytes (the limit of input value of the T-SQL built-it HASHBYTES function): [SqlFunction(DataAccess = ...
0 votes
1 answer
608 views

I am trying to add a DLL into SQL Server: CREATE ASSEMBLY ClassLibrary1 AUTHORIZATION dbo FROM 'C:\Debug\ClassLibrary1.dll' WITH PERMISSION_SET = UNSAFE GO As you can see here my DLLs But I get this ...
1 vote
0 answers
244 views

SQL Server is missing a StringBuilder UDF(s), how do I to overcome this limitation? This is what I built to overcome the problem: You can use this in a SQL statement, notice that you need to SET the ...
0 votes
1 answer
130 views

My company is in the process of upgrading the SQL Server CLR types that are being used with our software. After Googling around, I couldn't find a definitive yes/no answer to whether or not the SQL ...
1 vote
1 answer
3k views

I created an asymmetric key 'key_clr_http_request' and if I select * from sys.asymmetric_keys I can see it: I now would like to delete it: use master DROP ASYMMETRIC KEY key_clr_http_request But as ...
1 vote
2 answers
212 views

I am trying to execute a UDF which uses a CLR assembly. Each time I try to run it I get the below error: Msg 6522, Level 16, State 1, Line 45 A .NET Framework error occurred during execution of user-...
0 votes
2 answers
889 views

I did check this but the problem doesn't appears to be with mismatch of type. I'm trying to use CLR to convert back a file from blob data. Below is the c# code converted to dll and stored using ...
1 vote
1 answer
1k views

I have a CLR stored procedure in c# that goes something like public partial class StoredProcedures { [Microsoft.SqlServer.Server.SqlProcedure] public static void DecimalToWords (decimal sum) ...
2 votes
1 answer
2k views

I need to force the usage of TLS 1.2 in SQLCLR assembly which is installed on SQL Server 2008 R2. I have read the answer explaining how to enable TLS 1.2 programatically. Unfortunately, adding System....
0 votes
0 answers
219 views

I have a custom assembly that returns the column information for whatever query is thrown at it. While I was going through & double checking the values, it appears that a few of the 'DataTypeName' ...
2 votes
1 answer
1k views

I am writing a C# SQL CLR project (or "SQL Server Database Project", as it is apparently called now) in Visual Studio 2019 and I need to call a web service from it. In VS 2017 and earlier it was ...
0 votes
2 answers
1k views

I have trouble understanding of how CLR User-Defined Aggregates work. I have to create some custom CLR aggregates with multiple parameters. The point is to get the value of the first parameter ...

1 2
3
4 5
21