/*
exec sp_configure 'show advanced options', 1;
go
reconfigure;
go
exec sp_configure 'Ole Automation Procedures', 1;
go
reconfigure;
go
*/
declare
@obj int
, @response nvarchar(4000)
exec sp_OACreate 'MSXML2.XMLHTTP', @obj out;
exec sp_OAMethod @obj, 'open', NULL, 'get',
'https://호출할 API 주소',
'false'
exec sp_OAMethod @obj, 'send'
exec sp_OAMethod @obj, 'responseText', @response output
select @response
exec sp_OADestroy @obj
출처 : http://databaser.net/moniwiki/wiki.php/SQLServer%EC%97%90%EC%84%9CHTTPCall%ED%95%98%EA%B8%B0
'Program > DB' 카테고리의 다른 글
SQL Server에서 텔레그램(Telegram) API 호출 (0) | 2019.12.12 |
---|---|
SQL Server 에서 문자를 UTF-8로 변환 (0) | 2019.12.12 |
SQL Server Lock Memory Release(해제) 방법 (0) | 2019.09.27 |
cannot be run because the ssis subsystem failed to load. the job has been suspended (0) | 2018.07.18 |
sql server 로그 파일 축소 (0) | 2017.12.06 |