-
Notifications
You must be signed in to change notification settings - Fork 29
docs: add kb on how to restrict new sql connections in wrd #1846
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
DimitarNikolovv06
merged 6 commits into
master
from
petodoro/restrict-new-connections-kb
Oct 9, 2025
Merged
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
f16e3c7
docs: add kb on how to restrict new sql connections in wrd
petar-i-todorov b5004e2
fix title casing
petar-i-todorov 06bc1dd
Update knowledge-base/disable-build-new-data-connections-wrd.md
petar-i-todorov 51e6892
Update knowledge-base/disable-build-new-data-connections-wrd.md
petar-i-todorov ad9cb51
Update knowledge-base/disable-build-new-data-connections-wrd.md
petar-i-todorov 4a15fb0
Update disable-build-new-data-connections-wrd.md
DimitarNikolovv06 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
--- | ||
title: How to Disable "Build new data connections" in the SqlDataSource Wizard of the Web Report Designer | ||
description: Learn how to restrict the "Build new data connections" option in the "Choose data connection" window of the SqlDataSource wizard of the Web Report Designer while allowing users to select from existing data connections. | ||
type: how-to | ||
page_title: How to Disable "Build New Data Connections" in Web Report Designer | ||
meta_title: How to Disable "Build New Data Connections" in Web Report Designer | ||
slug: restricting-build-new-data-connections-report-designer | ||
tags: reporting, reportdesigner, datasource, connections, middleware | ||
res_type: kb | ||
--- | ||
|
||
## Environment | ||
|
||
<table> | ||
<tbody> | ||
<tr> | ||
<td> Product </td> | ||
<td> Reporting </td> | ||
</tr> | ||
<tr> | ||
<td> Version </td> | ||
<td> 19.2.25.1001 </td> | ||
</tr> | ||
</tbody> | ||
</table> | ||
|
||
## Description | ||
|
||
I need to prevent users from creating new database connections in the Web Report Designer's SqlDataSource component while still allowing them to select from pre-configured existing connections. | ||
|
||
## Solution | ||
|
||
To stop users from creating new SQL database connections, use a middleware to intercept the `/api/reportdesigner/connectionspermissions` request and modify the response. By returning an empty JSON or an object with all values set to `false`, you can disable the "Build new data connections" option. | ||
|
||
````C# | ||
app.Use(async (context, next) => | ||
{ | ||
if (context.Request.Path.Equals("/api/reportdesigner/connectionspermissions")) | ||
{ | ||
context.Response.ContentType = "application/json"; | ||
await context.Response.WriteAsync("{}"); // Return empty JSON to disable "Build new connections". | ||
return; | ||
} | ||
|
||
await next(); | ||
}); | ||
```` | ||
|
||
## See Also | ||
|
||
* [Web Report Designer Overview]({%slug web-report-designer/overview%}) | ||
* [SqlDataSource Wizard Overview]({%slug telerikreporting/designing-reports/report-designer-tools/web-report-designer/tools/sqldatasource-wizard%}) |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.