Skip to content

878261: Modify Querybuilder UG Content for Import-Export, Lock and Clone Samples #2833

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
merged 1 commit into from
Mar 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion ej2-asp-core-mvc/query-builder/clone-group-rule.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ documentation: ug

# Clone Group/Rule in ##Platform_Name## Query builder control

Query Builder allows you to clone rules as well as groups. The Clone options will create an exact replica of a rule or group next to the original. You can use `ShowButtons` to enable/disable these buttons.
The Query Builder functionality extends to cloning both individual rules and entire groups. Utilizing the Clone options will generate an exact duplicate of a rule or group adjacent to the original one. This feature enables users to replicate complex query structures effortlessly. The `ShowButtons` function offers users the ability to toggle the visibility of these cloning buttons, providing convenient control over the cloning process within the Query Builder interface.

{% if page.publishingplatform == "aspnet-core" %}

Expand Down
58 changes: 32 additions & 26 deletions ej2-asp-core-mvc/query-builder/import-export.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,17 +8,21 @@ publishingplatform: ##Platform_Name##
documentation: ug
---

# Import export in ##Platform_Name## Query builder control
# Importing and Exporting in ##Platform_Name## Query builder control

Importing allows you to view or edit the predefined conditions which is available in JSON or SQL. You can import the conditions either initial rendering or post rendering.
Importing facilitates the viewing or editing of predefined conditions available in JSON, SQL, and MongoDB query formats, while exporting enables obtaining the created rules in the query builder as JSON, SQL, and MongoDB queries.

## Importing

### Importing from JSON
Importing enables users to bring predefined conditions into the system for viewing or editing, available in formats such as JSON, SQL, and MongoDB query. It facilitates the quick incorporation of pre-defined rules or parameters into workflows, streamlining the setup process by importing directly from external sources or saved configurations.

### Importing from JSON Object

Importing from JSON enables users to bring predefined conditions encoded in JSON format into the system. This feature streamlines the process by providing a standardized format for importing data, ensuring compatibility, and ease of use.

#### Initial Rendering

To apply conditions initially, you can define the `Rule`. Here, you can import structured JSON object by defining the `Rule` property.
To initially apply conditions, you can establish the `Rule` by importing a structured JSON object and defining its properties.

{% if page.publishingplatform == "aspnet-core" %}

Expand Down Expand Up @@ -70,13 +74,13 @@ You can set the conditions from structured JSON object through the `setRules` me
{% endtabs %}
{% endif %}

### Importing From SQL Query

Importing from SQL involves integrating predefined conditions or data stored in a SQL database into the Query Builder. This enables the direct integration of SQL queries, thereby improving workflow efficiency and data accuracy within the application. SQL importing supports various types, including Inline SQL, Parameter SQL, and Named Parameter SQL.

### Importing From SQL
#### Importing from Inline SQL Query

#### Importing from Inline SQL

You can set the conditions from Inline SQL query through the `setRulesFromSql` method.
Importing from Inline SQL involves integrating SQL queries directly into the Query Builder. This method streamlines the process by enabling users to input SQL statements directly into the application for analysis, manipulation, or further processing within the Query Builder. Conditions can be set from Inline SQL queries using the `setRulesFromSql` method.

{% if page.publishingplatform == "aspnet-core" %}

Expand All @@ -101,9 +105,9 @@ You can set the conditions from Inline SQL query through the `setRulesFromSql` m
{% endtabs %}
{% endif %}

#### Importing from Parameter SQL
#### Importing from Parameter SQL Query

You can set the conditions from Parameter SQL query through the `setParameterizedSql` method.
Importing from Parameter SQL involves integrating SQL queries with parameters directly into the Query Builder. This method allows users to input SQL statements containing parameters, which can be dynamically filled in during execution. It streamlines the process by enabling flexible and customizable querying within the application. Conditions can be set from Parameter SQL queries using the `setParameterizedSql` method.

{% if page.publishingplatform == "aspnet-core" %}

Expand All @@ -128,9 +132,9 @@ You can set the conditions from Parameter SQL query through the `setParameterize
{% endtabs %}
{% endif %}

#### Importing from Named Parameter SQL
#### Importing from Named Parameter SQL Query

You can set the conditions from Named Parameter SQL query through the `setParameterizedNamedSql` method.
Importing from Named Parameter SQL involves integrating SQL queries with named parameters directly into the Query Builder. This method enables users to input SQL statements containing named parameters, providing flexibility and customization during execution. It streamlines the process by allowing dynamic parameter assignment within the application's query environment. Conditions can be set from Named Parameter SQL queries using the `setParameterizedNamedSql` method.

{% if page.publishingplatform == "aspnet-core" %}

Expand All @@ -155,9 +159,9 @@ You can set the conditions from Named Parameter SQL query through the `setParame
{% endtabs %}
{% endif %}

### Importing from MongoDB
### Importing from MongoDB Query

You can set the conditions from MongoDB query through the `setMongoQuery` method.
Importing from MongoDB Query involves integrating MongoDB queries directly into the Query Builder. This enables users to input MongoDB query statements directly into the application, allowing for seamless integration and manipulation of MongoDB data within the Query Builder environment. It streamlines the process by facilitating direct access to MongoDB data for analysis, filtering, and further processing within the application. Conditions can be set from Named Parameter SQL queries using the `setMongoQuery` method.

{% if page.publishingplatform == "aspnet-core" %}

Expand Down Expand Up @@ -185,17 +189,19 @@ You can set the conditions from MongoDB query through the `setMongoQuery` method

## Exporting

Exporting allows you to save or maintain the created conditions through the Query Builder. You can export the defined conditions by the following ways.
Exporting from the Query Builder allows users to preserve or store the created conditions. The defined conditions can be exported using various methods, including:

### Exporting to JSON Object

### Exporting to JSON
You can extract the established conditions in the Query Builder and convert them into a structured JSON object format using the `getRules` method. This process enables users to save or transfer the conditions for further use or analysis in other applications or systems that support JSON data.

You can export the defined conditions to structured JSON object through the `getRules` method.
### Exporting to SQL Query

### Exporting to SQL
Exporting to SQL involves converting the defined conditions within the Query Builder into SQL queries. This functionality allows users to generate SQL code representing the conditions set in the Query Builder, which can then be executed directly on a SQL database or used for further analysis and processing. SQL exporting supports various types, including Inline SQL, Parameter SQL, and Named Parameter SQL.

#### Exporting to Inline SQL
#### Exporting to Inline SQL Query

You can export the defined conditions to Inline SQL query through the `getRulesFromSQL` method.
Exporting to Inline SQL Query entails embedding the defined conditions from the Query Builder directly into SQL statements within the exported code. This method ensures that the conditions are seamlessly integrated into the SQL query syntax, enabling straightforward execution or further processing within SQL database systems. This can be achieved using the `getRulesFromSQL` method.

{% if page.publishingplatform == "aspnet-core" %}

Expand All @@ -220,9 +226,9 @@ You can export the defined conditions to Inline SQL query through the `getRulesF
{% endtabs %}
{% endif %}

#### Exporting to Parameter SQL
#### Exporting to Parameter SQL Query

You can export the defined conditions to Parameter SQL query through the `getParameterizedSql` method.
Exporting to Parameter SQL involves incorporating the defined conditions from the Query Builder into SQL queries with parameters. This method allows for dynamic value assignment during execution, enhancing flexibility and adaptability in query processing within SQL database. This can be accomplished using the `getParameterizedSql` method for exporting to Parameter SQL query.

{% if page.publishingplatform == "aspnet-core" %}

Expand All @@ -247,9 +253,9 @@ You can export the defined conditions to Parameter SQL query through the `getPar
{% endtabs %}
{% endif %}

#### Exporting to Named Parameter SQL
#### Exporting to Named Parameter SQL Query

You can export the defined conditions to Named Parameter SQL query through the `getParameterizedNamedSql` method.
Exporting to Named Parameter SQL entails integrating the defined conditions from the Query Builder into SQL queries with named parameters. This method offers enhanced readability and flexibility during execution by using named placeholders for parameter values. Named Parameter SQL facilitates easier maintenance and modification of queries, making it convenient for dynamic parameter assignment within SQL database. This can be accomplished using the method `getParameterizedNamedSql` for exporting to Named Parameter SQL query.

{% if page.publishingplatform == "aspnet-core" %}

Expand All @@ -274,9 +280,9 @@ You can export the defined conditions to Named Parameter SQL query through the `
{% endtabs %}
{% endif %}

### Exporting to MongoDB
### Exporting to MongoDB Query

You can export the defined conditions to MongoDB query through the `getMongoQuery` method.
Exporting to MongoDB Query involves converting the defined conditions within the Query Builder into MongoDB query syntax. This process allows users to generate MongoDB queries representing the conditions set in the Query Builder, which can then be executed directly on a MongoDB database or used for further analysis and processing. This can be accomplished using the `getMongoQuery` method for exporting to MongoDB query.

{% if page.publishingplatform == "aspnet-core" %}

Expand Down
2 changes: 1 addition & 1 deletion ej2-asp-core-mvc/query-builder/lock-group-rule.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ documentation: ug

# Lock Group/Rule in ##Platform_Name## Query builder control

Query Builder allows you to lock rules as well as groups. When a rule is locked, the field, operator, and value will be disabled. When a group is locked, all the elements within the group will be disabled. You can use `ShowButtons` to enable/disable these buttons.
The Query Builder provides the functionality to lock individual rules or entire groups. When a rule is locked, it prevents users from modifying its field, operator, and value, effectively disabling these components. Similarly, locking a group disables all elements contained within it. This feature offers users greater control over their query configurations, ensuring that specific rules or groups remain unchanged. Additionally, users can manage the visibility of locking buttons through the `ShowButtons` function, allowing for seamless control over the locking mechanism.

{% if page.publishingplatform == "aspnet-core" %}

Expand Down