Reference: Query Designer Properties

 

For the latest documentation on Visual Studio 2017, see Visual Studio 2017 Documentation.

You can modify the appearance and behavior of a query by setting the value of properties in the Properties window. The following tables describe each property.

General

Name Description
Number of Results Returned Indicates whether the query returns one row or multiple rows. Select one of the following values:

- Many if you intend for this query to return a collection of rows (For example: a collection of customers).
- One if you intend for this query to return only one row (For example: a customer). If no data matches the conditions of the query, the query returns null or Nothing in Visual Basic. If more than one row of data matches the conditions of the query, an InvalidOperationException is thrown.
Name The name of the query.
Is Optional Indicates whether a parameter value is required or optional. Select one of the following values:

- True if you want the query to exclude filter conditions that use the parameter when the value of the parameter is null.
- False if you want the query to include filter conditions that use the parameter when the value of the parameter is null. Each row of data will be tested for the presence of a null value.

Applies to query parameters only.
Source The data source of the query (For example: the Customers entity set).
Return Type The entity that the query returns when the query is executed.

Appearance

Name Description
Description The text that appears as a tooltip.
Display Name The name that appears on the screen.

See Also

Reference: Screen Designer Properties
Reference: Data Designer Properties
Queries: Retrieving Information from a Data Source