Ejemplo n.º 1
0
        /// <summary>
        /// Executes a sql xml query
        /// </summary>
        /// <param name="query"></param>
        /// <param name="xmlString"></param>
        public static void Execute(SqlXmlQuery query, ref string xmlString)
        {
            VerifySqlXmlQueryObject(query);
            ISqlQuery sqlClass = new SQLServer(GetConnectionString());

            xmlString = sqlClass.ExecuteXml(query);
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Gets the specified test as string xml
        /// </summary>
        /// <param name="adminId"></param>
        /// <returns></returns>
        public static string Get(Guid?testId)
        {
            string xml = string.Empty;

            SqlXmlQuery query = new SqlXmlQuery(SqlXmlQueryType.SqlXmlStoredProc, "TestGet");

            query.AddParameter("@TestId", testId);

            DBManager.Execute(query, ref xml);

            return(xml);
        }