Viewing 15 posts - 706 through 720 (of 1,193 total)
Something like this should get you close if you're actually on 2008 R2 or later:
SELECT table_name=object_name(s.object_id),
stats_name=name,
...
January 7, 2016 at 2:54 pm
For a little extra fun, you can even see that ghost records are being retained because of snapshot isolation if you run sys.dm_db_index_physical_stats using DETAILED mode. There's a handy column...
January 7, 2016 at 12:20 pm
Eric M Russell (1/7/2016)
January 7, 2016 at 10:04 am
There have been a few problems like this that seem tied to parallelism. Running with the clustered index and OPTION (MAXDOP 1) yields deterministic results again.
There was this early bug...
January 7, 2016 at 9:16 am
The immediate problem is the location of your clause that restricts the results to dates before today.
Right now it's in the NOT EXISTS subquery, which means that once rows start...
January 6, 2016 at 1:04 pm
Luis Cazares (1/6/2016)
Hugo Kornelis (1/6/2016)
sql_only (1/6/2016)
why does
DECLARE @phi DECIMAL = (SQRT(5)+1)/2
SELECT @phi;
return 2
and not 1.618
Integer math.
The data used as input in the formula are all integers, so the intermediate results...
January 6, 2016 at 9:13 am
AND in this case separates filter conditions. <='2014-12-31' by itself is not a valid condition. You need this for the last two conditions:
transaction_date>='2013-01-01' and transaction_date<='2014-12-31'
Cheers!
EDIT: Inside code tags my greater...
January 5, 2016 at 11:56 am
I'm not aware of any way to force connections to the read-only replica for particular logins.
When I've needed logins to have permissions solely on the read-only secondary, I've just created...
January 5, 2016 at 11:36 am
No need to be too sorry; we all skip over things when reading sometimes. Goodness knows I have 🙂
I'm glad it's working for you!
Cheers!
December 29, 2015 at 5:25 pm
Read my post a bit more closely 🙂
Jacob Wilkins (12/29/2015)
December 29, 2015 at 5:17 pm
There would also be duplicates if the same parent occurred on different rows in vw_csys_NurserySchool. You could just do a DISTINCT in the outer SELECT (i.e., SELECT DISTINCT females_only.*) to...
December 29, 2015 at 5:09 pm
It's still not at all clear what you're wanting.
If you could give us sample data and your expected results from that sample data, we'd probably be able to solve this...
December 29, 2015 at 3:49 pm
Phil Parkin (12/29/2015)
drew.allen (12/29/2015)
December 29, 2015 at 1:36 pm
I read the original request as requiring the invoice to have both items 111 and 222, and ONLY items 111 and 222. Is that correct?
Either way, the approach using...
December 28, 2015 at 8:55 am
It seems that's a pretty straightforward query, where you just want the sum of one column, grouped by another set of columns, and the desired result set is just the...
December 26, 2015 at 7:38 pm
Viewing 15 posts - 706 through 720 (of 1,193 total)