Ejemplo n.º 1
0
        public void ColumnsListSimpleRaw()
        {
            ColumnsListSimple c = new ColumnsListSimple(global::SqlBuilder.Format.MsSQL);

            c.Append("a", "b", "c");
            c.AppendAlias("last_name", "l");
            c.Raw("(SELECT NOW())");
            c.Raw("(SELECT 'abc')", "lll");
            c.Append("d");
            string result = c.GetSql("tbl");
            string sql    = "[tbl].[a], [tbl].[b], [tbl].[c], [tbl].[last_name] as 'l', (SELECT NOW()), (SELECT 'abc') as 'lll', [tbl].[d]";

            Assert.AreEqual(sql, result);
        }