You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: blazor/datagrid/connecting-to-database/dapper.md
+4-4Lines changed: 4 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,7 +9,7 @@ documentation: ug
9
9
10
10
# Connecting SQL data to a Blazor DataGrid Component using Dapper
11
11
12
-
The Syncfusion<supstyle="font-size:70%">®</sup> Blazor DataGrid component supports binding data from Microsoft SQL Server using [Dapper](https://github.com/DapperLib/Dapper) and [System.Data.SqlClient](https://www.nuget.org/packages/System.Data.SqlClient/4.8.6?_src=template).**Dapper** is a lightweight object-relational mapper (ORM) that simplifies executing SQL queries and mapping results to C# domain models.
12
+
The Syncfusion<supstyle="font-size:70%">®</sup> Blazor DataGrid component supports binding data from Microsoft SQL Server using [Dapper](https://github.com/DapperLib/Dapper) and [System.Data.SqlClient](https://www.nuget.org/packages/System.Data.SqlClient/4.8.6?_src=template).**Dapper** is a lightweight object-relational mapper (ORM) that simplifies executing SQL queries and mapping results to C# domain models.
13
13
14
14
Data from SQL Server can be integrated into the Blazor DataGrid using multiple approaches:
15
15
@@ -19,11 +19,11 @@ Data from SQL Server can be integrated into the Blazor DataGrid using multiple a
19
19
20
20
This guide demonstrates two approaches for integrating SQL Server data with the Blazor DataGrid using **Dapper**:
21
21
22
-
***Remote binding via API service using UrlAdaptor**
22
+
**Using UrlAdaptor**
23
23
24
24
This approach connects the DataGrid to a REST API endpoint that returns data in the required format. The [UrlAdaptor](https://blazor.syncfusion.com/documentation/datagrid/connecting-to-adaptors/url-adaptor) handles communication between the component and the API, enabling server-side operations such as **paging**, **sorting**, and **filtering**.
25
25
26
-
***Custom binding using CustomAdaptor**
26
+
**Using CustomAdaptor**
27
27
28
28
This approach provides complete control over data operations by implementing a [CustomAdaptor](https://blazor.syncfusion.com/documentation/datagrid/connecting-to-adaptors/custom-adaptor) class. It allows overriding methods for reading, updating, inserting, and deleting data, making it suitable for scenarios requiring custom business logic or complex queries.
29
29
@@ -207,7 +207,7 @@ Access the theme stylesheet and script from NuGet using [Static Web Assets](http
207
207
208
208
5.**Configure DataGrid with UrlAdaptor**
209
209
210
-
The [SfDataManager](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Data.SfDataManager.html) component supports multiple adaptors for remote data binding. For API services, set the [Adaptor](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Adaptors.html) property to [Adaptors.UrlAdaptor](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Adaptors.html#Syncfusion_Blazor_Adaptors_UrlAdaptor) and specify the service endpoint in the [Url](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.DataManager.html#Syncfusion_Blazor_DataManager_Url) property.
210
+
The [DataManager](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Data.SfDataManager.html) component supports multiple adaptors for remote data binding. For API services, set the [Adaptor](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Adaptors.html) property to [Adaptors.UrlAdaptor](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Adaptors.html#Syncfusion_Blazor_Adaptors_UrlAdaptor) and specify the service endpoint in the [Url](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.DataManager.html#Syncfusion_Blazor_DataManager_Url) property.
Copy file name to clipboardExpand all lines: blazor/datagrid/connecting-to-database/microsoft-sql-server.md
+14-16Lines changed: 14 additions & 16 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -17,11 +17,11 @@ The Syncfusion<sup style="font-size:70%">®</sup> Blazor DataGrid component s
17
17
18
18
This guide explains two primary approaches for integrating Microsoft SQL Server data with the Blazor DataGrid:
19
19
20
-
***Remote Data Binding using UrlAdaptor**: Enables communication between the DataGrid and a remote API service connected to SQL Server. This approach is suitable when the API implements custom logic for data operations and returns results in the **result** and **count** format.
20
+
**Using UrlAdaptor**: Enables communication between the DataGrid and a remote API service connected to SQL Server. This approach is suitable when the API implements custom logic for data operations and returns results in the **result** and **count** format.
***Custom Data Binding using CustomAdaptor**: Provides full control over data operations and CRUD functionality. It allows implementing custom logic for **searching**, **filtering**, **sorting**, **paging**, and **grouping** directly in server-side code.
24
+
**Using CustomAdaptor**: Provides full control over data operations and CRUD functionality. It allows implementing custom logic for **searching**, **filtering**, **sorting**, **paging**, and **grouping** directly in server-side code.
@@ -33,12 +33,12 @@ Microsoft SQL Server is a relational database management system (**RDBMS**) deve
33
33
34
34
**Key Features**
35
35
36
-
**Relational Database Model**: Organizes data into tables with rows and columns.
37
-
**T-SQL Support**: Provides **Transact-SQL** for advanced querying and procedural programming.
38
-
**High Availability**: Features like Always On Availability Groups for failover and disaster recovery.
39
-
**Security**: Includes **encryption**, **authentication**, and **role-based access** control.
40
-
**Integration**: Works with .NET applications, Azure services, and supports REST APIs.
41
-
**Scalability**: Handles large datasets and supports both on-premises and cloud deployments.
36
+
-**Relational Database Model**: Organizes data into tables with rows and columns.
37
+
-**T-SQL Support**: Provides **Transact-SQL** for advanced querying and procedural programming.
38
+
-**High Availability**: Features like Always On Availability Groups for failover and disaster recovery.
39
+
-**Security**: Includes **encryption**, **authentication**, and **role-based access** control.
40
+
-**Integration**: Works with .NET applications, Azure services, and supports REST APIs.
41
+
-**Scalability**: Handles large datasets and supports both on-premises and cloud deployments.
42
42
43
43
For more details, refer to the official [Microsoft documentation](https://learn.microsoft.com/en-us/sql/sql-server/what-is-sql-server?view=sql-server-ver17).
44
44
@@ -216,7 +216,7 @@ N>
216
216
217
217
**Step 5: Configure DataGrid with UrlAdaptor**
218
218
219
-
Use [SfDataManager](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Data.SfDataManager.html) to connect the DataGrid to the API endpoint and set the [Adaptor](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Adaptors.html) property to [Adaptors.UrlAdaptor](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Adaptors.html#Syncfusion_Blazor_Adaptors_UrlAdaptor).
219
+
Use [DataManager](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Data.SfDataManager.html) to connect the DataGrid to the API endpoint and set the [Adaptor](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Adaptors.html) property to [Adaptors.UrlAdaptor](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Adaptors.html#Syncfusion_Blazor_Adaptors_UrlAdaptor).
220
220
221
221
{% tabs %}
222
222
{% highlight razor tabtitle="Index.razor" %}
@@ -492,20 +492,18 @@ public object Post([FromBody] DataManagerRequest DataManagerRequest)
492
492
493
493
**Key Points**
494
494
495
-
*`request.Skip` specifies the number of records to skip.
496
-
*`request.Take` specifies the number of records to retrieve.
497
-
*`PerformSkip` and `PerformTake` enable efficient server-side paging.
495
+
***request.Skip** specifies the number of records to skip.
496
+
***request.Take** specifies the number of records to retrieve.
497
+
***PerformSkip** and **PerformTake** enable efficient server-side paging.
498
498
* Custom paging logic can be added before or after applying these methods.
499
499
500
500
> **Best Practice**:
501
-
502
501
For optimal performance, apply operations in the following sequence on the server side:
The Syncfusion<supstyle="font-size:70%">®</sup> Blazor DataGrid supports **Create**, **Read**, **Update**, and **Delete** (**CRUD**) operations through the [SfDataManager](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Data.SfDataManager.html) component. API endpoints for these operations are mapped using properties such as:
506
+
The Syncfusion<supstyle="font-size:70%">®</sup> Blazor DataGrid supports **Create**, **Read**, **Update**, and **Delete** (**CRUD**) operations through the [DataManager](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Data.SfDataManager.html) component. API endpoints for these operations are mapped using properties such as:
509
507
510
508
*[InsertUrl](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.DataManager.html#Syncfusion_Blazor_DataManager_InsertUrl) – API endpoint for inserting new records.
511
509
*[UpdateUrl](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.DataManager.html#Syncfusion_Blazor_DataManager_UpdateUrl) – API endpoint for updating existing records.
@@ -628,7 +626,7 @@ public void Delete([FromBody] CRUDModel<Order> Value)
628
626
629
627
**Batch Operation:**
630
628
631
-
To perform batch updates, set the edit [Mode](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Grids.GridEditSettings.html#Syncfusion_Blazor_Grids_GridEditSettings_Mode) to **Batch** in the [GridEditSettings](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Grids.GridEditSettings.html) component and configure the [BatchUrl](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.DataManager.html#Syncfusion_Blazor_DataManager_BatchUrl) property in the [SfDataManager](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Data.SfDataManager.html).
629
+
To perform batch updates, set the edit [Mode](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Grids.GridEditSettings.html#Syncfusion_Blazor_Grids_GridEditSettings_Mode) to **Batch** in the [GridEditSettings](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Grids.GridEditSettings.html) component and configure the [BatchUrl](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.DataManager.html#Syncfusion_Blazor_DataManager_BatchUrl) property in the [DataManager](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Data.SfDataManager.html).
632
630
In batch mode:
633
631
634
632
- Use the **Add** toolbar button to insert new rows.
Copy file name to clipboardExpand all lines: blazor/datagrid/connecting-to-database/mysql-server.md
+4-4Lines changed: 4 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -15,11 +15,11 @@ The Syncfusion<sup style="font-size:70%">®</sup> Blazor DataGrid component s
15
15
- Implementing a [CustomAdaptor](https://blazor.syncfusion.com/documentation/datagrid/connecting-to-adaptors/custom-adaptor) for custom logic.
16
16
- Configuring remote data binding through adaptors such as [UrlAdaptor](https://blazor.syncfusion.com/documentation/data/adaptors#url-adaptor).
17
17
18
-
***Remote Data Binding using UrlAdaptor**
18
+
**Using UrlAdaptor**
19
19
20
20
The [UrlAdaptor](https://blazor.syncfusion.com/documentation/data/adaptors#url-adaptor) enables communication between the DataGrid and a remote API service connected to **MySQL** Server. This approach is suitable when the API implements custom logic for data operations and returns results in the **result** and **count** format.
21
21
22
-
***Custom Data Binding using CustomAdaptor**
22
+
**Using CustomAdaptor**
23
23
24
24
The [CustomAdaptor](https://blazor.syncfusion.com/documentation/datagrid/connecting-to-adaptors/custom-adaptor) provides full control over data operations and CRUD functionality. It allows implementing custom logic for **searching**, **filtering**, **sorting**, **paging**, and **grouping** directly in the server-side code.
25
25
@@ -467,7 +467,7 @@ public void Insert([FromBody] CRUDModel<Order> Value)
467
467
468
468
**Update Operation:**
469
469
470
-
To edit a row, first select desired row and click the **Edit**toolbar button. The edit form will be displayed and proceed to modify any column value as per your requirement. Clicking the **Update**toolbar button will update the edit record in the Orders table by involving the following **Post** method of an API.
470
+
To edit a row, select the required row and click the **Edit** button in the toolbar. An edit form will appear, allowing changes to any column value. After making the changes, click the **Update** button in the toolbar to save the record in the Orders table. This action triggers the following **POST** method in the API.
471
471
472
472
{% tabs %}
473
473
{% highlight c# tabtitle="OrdersController.cs" %}
@@ -529,7 +529,7 @@ public void Delete([FromBody] CRUDModel<Order> Value)
529
529
530
530
**Batch Operation:**
531
531
532
-
To perform batch updates, set the edit [Mode](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Grids.GridEditSettings.html#Syncfusion_Blazor_Grids_GridEditSettings_Mode) to **Batch** in the [GridEditSettings](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Grids.GridEditSettings.html) component and configure the [BatchUrl](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.DataManager.html#Syncfusion_Blazor_DataManager_BatchUrl) property in the [SfDataManager](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Data.SfDataManager.html).
532
+
To perform batch updates, set the edit [Mode](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Grids.GridEditSettings.html#Syncfusion_Blazor_Grids_GridEditSettings_Mode) to **Batch** in the [GridEditSettings](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Grids.GridEditSettings.html) component and configure the [BatchUrl](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.DataManager.html#Syncfusion_Blazor_DataManager_BatchUrl) property in the [DataManager](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.Data.SfDataManager.html).
533
533
In batch mode:
534
534
535
535
- Use the **Add** toolbar button to insert new rows.
0 commit comments