Esempio n. 1
0
        public bool checkTableIsExist(string tablename)
        {
            string sql = "if object_id( '" + tablename + "') is not null select 1 else select 0";

            try
            {
                int i = DBHelperSQL.ExecuteScalar(sql);
                if (i > 0)
                {
                    return(true);
                }
                else
                {
                    return(false);
                }
            }
            catch
            {
                return(false);
            }
        }