Esempio n. 1
0
 public object GetValue(string spname, params object[] paraValues)
 {
     if (paraValues != null)
     {
         SqlParameter[] commandParameters = SqlDbParameterCache.GetSpParameterSet(ConnectionString, spname, false);
         DbHelperUtil.AssignParameterValues(commandParameters, paraValues);;
         return(GetValue(spname, CommandType.StoredProcedure, commandParameters));
     }
     else
     {
         return(GetValue(spname, CommandType.StoredProcedure, (DbParameter)null));
     }
 }
Esempio n. 2
0
 public DataSet GetDataSet(string spName, params object[] paraValues)
 {
     if (paraValues != null)
     {
         SqlParameter[] commandParameters = SqlDbParameterCache.GetSpParameterSet(ConnectionString, spName, false);
         DbHelperUtil.AssignParameterValues(commandParameters, paraValues);;
         return(GetDataSet(spName, commandParameters));
     }
     else
     {
         return(GetDataSet(spName, (DbParameter[])null));
     }
 }
Esempio n. 3
0
 public int ExcuteSP(string spName, DataRow dataRow)
 {
     if (dataRow != null)
     {
         SqlParameter[] commandParameters = SqlDbParameterCache.GetSpParameterSet(ConnectionString, spName, false);
         DbHelperUtil.AssignParameterValues(commandParameters, dataRow);;
         return(ExcuteSP(spName, commandParameters));
     }
     else
     {
         return(ExcuteSP(spName, (DbParameter[])null));
     }
 }