Runs a scalar-valued Transact-SQL query against a target instance of SQL Server. Only one column can be specified in a SELECT ...

Runs a scalar-valued Transact-SQL query against a target instance of SQL Server. Only one column can be specified in a SELECT statement; additional columns beyond the first are ignored.  The resulting query should return only one row; additional rows beyond the first are ignored. If the query returns an empty set or NULL, then the condition expression built around ExecuteSQL will evaluate to false. ExecuteSql supports the On Demand and On Schedule evaluation modes. A SELECT statement can use the following variables, which will be substituted at run time by using ADO.NET parameter substitution:
@@ObjectName - corresponds to the name field in sys.objects. The variable will be replaced with the name of the current object.
@@SchemaName - corresponds to the name field in sys.schemas. The variable will be replaced with the schema for the current object if the current object belongs to a schema.