Exemple #1
0
        public int FindCount(int productID)
        {
            string commandText = string.Format("select count(*) from ProductCirculationRecord where ProductCirculationRecord.productID = {0}", productID);
            int    result      = DbHelperAccess.executeQueryNum(commandText);

            return(result);
        }
Exemple #2
0
        public int FindCountByIDs(int[] ids)
        {
            if (ids == null || ids.Length == 0)
            {
                return(0);
            }
            StringBuilder sb = new StringBuilder("select count(*) from ProductSKU where ");

            for (int i = 0; i < ids.Length; i++)
            {
                sb.AppendFormat("ID={0} or ", ids[i]);
            }
            int num = DbHelperAccess.executeQueryNum(sb.ToString());

            return(num);
        }