コード例 #1
0
ファイル: User.cs プロジェクト: nutsukae/E-library
        public DataSet CheckUsernamePassword(string Username, string Password)
        {
            DBTool dbTool = new DBTool ();

            string GetUserDetail = string.Format("SELECT * FROM tb_user WHERE username = '******' and [password] = '{1}' and status = '1'", Username, Password);
            return dbTool.ExecuteDataSet(GetUserDetail);
        }
コード例 #2
0
ファイル: SubCategory.cs プロジェクト: nutsukae/E-library
        public DataSet GetList(string categoryid)
        {
            string SQL = "SELECT * FROM mst_subcategory WHERE categoryid = "+categoryid;

            DBTool dbTool = new DBTool();

            try
            {
                return dbTool.ExecuteDataSet(SQL);
            }
            catch (Exception)
            {
                return null;
            }
        }
コード例 #3
0
ファイル: Category.cs プロジェクト: nutsukae/E-library
        public DataSet GetList()
        {
            string SQL = "SELECT * FROM mst_category where status = 1 ORDER BY [name]";

            DBTool dbTool = new DBTool();

            try
            {
                return dbTool.ExecuteDataSet(SQL);
            }
            catch (Exception)
            {
                return null;
            }
        }