QueryStringBuilder
Constructs a Query String from various parameters
- Stored Procedure
- SQL Server Compatibility: 2008, 2012, 2014, 2016, 2017
EXEC SQLHTTP.net.QueryStringBuilder @QueryString, @Profile, @QuerySegment1_Name, @QuerySegment1_Value, [@QuerySegment2_Name], [@QuerySegment2_Value] … @QuerySegment20_Name], [@QuerySegment20_Value]
Name | Type | Description |
---|---|---|
@QueryString | nvarchar(MAX) | Required. Output parameter. The Query String constructed by executing this stored procedure |
@Profile | nvarchar(100) | Required. The Profile under which Authorization Parameters were saved |
@QuerySegment1_Name | nvarchar(MAX) | Required. First QueryString parameter name to be appended to @QueryString. |
@QuerySegment1_Value | nvarchar(MAX) |
Required. First QueryString parameter value to be appended to @QueryString. A value beginning with # will be retrieved as an AuthParam of the provided Profile. See example below. |
@QuerySegment2_Name | nvarchar(MAX) | Optional. Second QueryString parameter name to be appended to @QueryString. |
@QuerySegment2_Value | nvarchar(MAX) |
Optional. Second QueryString parameter value to be appended to @QueryString. A value beginning with # will be retrieved as an AuthParam of the provided Profile. See example below. |
. . . |
||
@QuerySegment20_Name | nvarchar(MAX) | Optional. Twentieth QueryString parameter name to be appended to @QueryString. |
@QuerySegment20_Value | nvarchar(MAX) |
Optional. Twentieth QueryString parameter value to be appended to @QueryString. A value beginning with # will be retrieved as an AuthParam of the provided Profile. See example below. |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 |
DECLARE @QueryString nvarchar(MAX) EXEC SQLHTTP.net.QueryStringBuilder @QueryString OUTPUT, 'My Box', --Profile 'response_type', 'code', --First QuerySegment Name/Value pair 'client_id', '#ClientID' --Second QuerySegment Name/Value pair --Third QuerySegment Name/Value pair for a parameter that should not be encoded SET @QueryString = @QueryString + '&redirect_uri=' COLLATE SQL_Latin1_General_CP1_CI_AS + SQLHTTP.net.AuthParam('My Box', 'RedirectURL') SELECT @QueryString |
1 2 3 4 |
-------------------------------------------------------------------------------------------- ?response_type=code&client_id=ks910ja026rt5eb&redirect_uri=http%3a%2f%2flocalhost%3a53200 |
- AuthListener
- AuthParam
- AuthParamRemove
- AuthParamsClear
- AuthParamSet
- BasicAuthHeader
- FormDataBuilder
- HttpQueueActivity
- HttpRequest
- HttpSession
- IsUrlValid
- OAuthHeader
- QueryStringBuilder
- RaiseHttpError
- RequestHeaderRemove
- RequestHeaders
- RequestHeaderSet
- RequestPartAdd
- ResponseHeaders
- UrlBuilder
- UrlProperty