예제 #1
0
파일: QMsSql.cs 프로젝트: fence-post/sqrach
        static public int Exec(string sSql)
        {
            int nResult = 0;

            using (QMsSql s = new QMsSql())
            {
                nResult = s.Execute(sSql);
            }

            return(nResult);
        }
예제 #2
0
파일: QMsSql.cs 프로젝트: fence-post/sqrach
        static public string SqlString(string sSql)
        {
            string sResult = "";

            using (QMsSql s = new QMsSql())
            {
                s.Open(sSql);
                if (s.GetRow())
                {
                    sResult = s.GetString(0);
                }
            }

            return(sResult);
        }
예제 #3
0
파일: QMsSql.cs 프로젝트: fence-post/sqrach
        static public int SqlInt(string sSql)
        {
            int nResult = 0;

            using (QMsSql s = new QMsSql())
            {
                s.Open(sSql);
                if (s.GetRow())
                {
                    nResult = s.GetInt(0);
                }
            }

            return(nResult);
        }
예제 #4
0
파일: QMsSql.cs 프로젝트: fence-post/sqrach
        static public int SqlInt(bool useRawValues, string sql, params object[] args)
        {
            int nResult = 0;

            AddArgsToQuery(useRawValues, ref sql, args);

            using (QMsSql s = new QMsSql())
            {
                s.Open(sql);
                if (s.GetRow())
                {
                    nResult = s.GetInt(0);
                }
            }

            return(nResult);
        }