DbNetSuiteVS
ExecuteSingletonQuery Method (CmdConfig)
NamespacesDbNetLink.DataDbNetDataExecuteSingletonQuery(CommandConfig)
Executes a select statement or stored procedure and reads the first row of the returned record set
Declaration Syntax
C#Visual Basic
public bool ExecuteSingletonQuery(
	CommandConfig CmdConfig
)
Public Function ExecuteSingletonQuery ( _
	CmdConfig As CommandConfig _
) As Boolean
Parameters
CmdConfig (CommandConfig)

The SQL statement and parameter values

Return Value
Returns True if a record is found otherwise False
Examples
CopyC#
DbNetData Data = new DbNetData( ConfigurationSettings.AppSettings[ "nwind" ] );
Data.Open();
CommandConfig CmdConfig = new CommandConfig("select productname from products");
CmdConfig.Params["id"] = ProductID.Value;
if ( Data.ExecuteSingletonQuery(CmdConfig) )
    ProductName.Text = Data.ReaderValue("productname"); 
Data.Close();

Assembly: DbNetLink.DbNetSuiteVS (Module: DbNetLink.DbNetSuiteVS) Version: 0.9.3317.16858 (0.9.0.0)