public void CheckQueryWithoutWhereClauses()
        {
            const string sql = @"SELECT BusinessEntityID, FirstName, LastName
                                FROM Testoffset";

            var visitor = new UnboundedResultSetVisitor();
            RunTSqlFragmentVisitor.AnalyzeFragmentVisitorBase(sql, sql.ComputeHash(), visitor);

            Assert.IsTrue(visitor.IsSuspected);
        }
        public void CheckQueryHasTopKeyword()
        {
            const string sql = @"SELECT Top 3 BusinessEntityID, FirstName, LastName
                                FROM Testoffset";

            var visitor = new UnboundedResultSetVisitor();
            RunTSqlFragmentVisitor.AnalyzeFragmentVisitorBase(sql, sql.ComputeHash(), visitor);

            Assert.IsFalse(visitor.IsSuspected);
        }
        public void CheckQueryHasOffsetFetch()
        {
            const string sql = @"SELECT BusinessEntityID, FirstName, LastName
                                FROM Testoffset
                                ORDER BY BusinessEntityID
                                OFFSET 3 ROWS
                                FETCH First 3 ROWS only";

            var visitor = new UnboundedResultSetVisitor();
            RunTSqlFragmentVisitor.AnalyzeFragmentVisitorBase(sql, sql.ComputeHash(), visitor);

            Assert.IsFalse(visitor.IsSuspected);
        }