public T SelectOne <T>(string sql) where T : BasicObj { SqlConnection conn = cm.GetConnection(); QuerySingle querySingle = new PreparedSelectSingle(); T t1 = querySingle.SelectOne <T>(conn, sql); cm.CloseConn(conn); return(t1); }
public T SelectOne <T>(T t) where T : IdentityObj { SqlConnection conn = cm.GetConnection(); QuerySingle querySingle = new PreparedSelectSingle(); T t1 = querySingle.SelectOne <T>(conn, t); cm.CloseConn(conn); return(t1); }