SQL Tricks & Tips Flashcards
NO SQL means:
Not Only Sequel
In T-SQL, what command will return only the first 1000 rows of a SELECT query?
top 1000
Which type of join will only return results where the condition is true?
inner
What type of filter condition can you use to return rows with a date value within a range?
between
What must you also include in a SELECT statement when performing an aggregation?
group by
Which function in T-SQL allows you to perform an aggregation across a range of rows?
Which SELECT clause can you use to test if the outer queries value is present in the sub-query
exists
To calculate a running total, what range should you use in your OVER clause?
rows unbounded preceding
In T-SQL, what date function will return the last day of a given month?
eomonth
Which clause do you use to create a common table expression in T-SQL?
with
Besides the rank() function, what t-sql method can you use to return a ranking of results?
row_number