0
안녕하세요. CLR 통합을 사용하여 SQL Server에서 외부 exe에 액세스하려고합니다.System.Security.SecurityException : 요청하지 못했습니다.
내 데이터베이스 TRUSTWORTHY ON
및 PERMISSION_SET = EXTERNAL_ACCESS
을 설정하고 있지만, 다음과 같은 오류를
Msg 6522, Level 16, State 1, Procedure hello, Line 0
A .NET Framework error occurred during execution of user defined routine or aggregate 'hello':
System.Security.SecurityException: Request failed.
System.Security.SecurityException:
at HelloWorldProc.HelloWorld()
helloworld.cs 코드는 무엇입니까 : 나는 우리가를 설정하려면이 오류에 대한 해결책을 가지고 있어요
using System;
using System.Data;
using Microsoft.SqlServer.Server;
using System.Data.SqlTypes;
using System.Diagnostics;
public class HelloWorldProc
{
[Microsoft.SqlServer.Server.SqlProcedure]
public static void HelloWorld()
{
SqlContext.Pipe.Send("Hello world!\n");
Process.Start(@"D:\Raja\trg.exe");
}
}
잘 작동합니다. –