Viewing 5 posts - 46 through 50 (of 50 total)
Hi
The tables first need to be joined. The rows to be excluded can be filtered using a where clause or by specifying the criteria in the join itself.
from table2
join table1...
March 5, 2011 at 6:20 am
Hi
Why is there an extra 7 in the code?
I would use the ffg script to get midnight a week ago:
select dateAdd(dd,datediff(dd,0,getdate()-7),0)
but if I wanted to keep everything from this...
March 4, 2011 at 2:46 pm
How is it that your application or SQL knows who is running the query? Are you checking SUSER_NAME(), USER_NAME() as explained above?
March 2, 2011 at 1:03 pm
Hi
Just wondering if there is a way to link the 2 tables? Is EmployeeNumber the primary key? I'm sure its a fairly easy update script if the 2 tables were...
March 2, 2011 at 12:42 pm
The nested example is a good example as an explanation.
In the real world we would change the ORDER BY clause for one of the select statements. For instance, when...
February 28, 2011 at 1:52 pm
Viewing 5 posts - 46 through 50 (of 50 total)
This website stores cookies on your computer.
These cookies are used to improve your website experience and provide more personalized services to you, both on this website and through other media.
To find out more about the cookies we use, see our Privacy Policy