Beispiel #1
0
        public void TestExists()
        {
            var classicWay = Exists.InTable("table").Where("1", Is.DifferentWith, "1");
            var dbalWay    = new Table("table", "colA", "colB").Exists().Where("1", Is.DifferentWith, "1");

            Assert.AreEqual(classicWay.Sql, dbalWay.Sql);
        }
Beispiel #2
0
        public void Test()
        {
            var exists = Exists.InTable("test").Where("a", Is.GreaterThan, "b");

            Assert.AreEqual("SELECT EXISTS (SELECT 1 FROM test WHERE a > @" + Math.Abs("b".GetHashCode()) + ")", exists.Sql);
        }