public void CanConnectToDb2AndExecuteAReader() { var Db2Database = new DatabaseSyntheticConfigSettings(this.configurationSource).GetDatabase("Db2Test").BuildDatabase(); DbConnection connection = Db2Database.CreateConnection(); Assert.IsNotNull(connection); Assert.IsTrue(connection is iDB2Connection); connection.Open(); DbCommand cmd = Db2Database.GetSqlStringCommand("Select * from Region"); Db2Database.ExecuteReader(cmd); }
public void CanConnectToOracleAndExecuteAReader() { var oracleDatabase = new DatabaseSyntheticConfigSettings(this.configurationSource).GetDatabase("OracleTest").BuildDatabase(); DbConnection connection = oracleDatabase.CreateConnection(); Assert.IsNotNull(connection); Assert.IsTrue(connection is OracleConnection); connection.Open(); DbCommand cmd = oracleDatabase.GetSqlStringCommand("Select * from Region"); cmd.CommandTimeout = 0; }