Viewing 15 posts - 2,851 through 2,865 (of 4,087 total)
Jeff Moden (12/29/2015)
drew.allen (12/29/2015)
None of the newer date/time data types support decimal math.
I consider that to be a major failure on the part of Microsoft. I'll never understand why...
December 29, 2015 at 2:47 pm
Your client may be limiting the number of characters returned. It may limit either the total returned or the amount returned per column. For instance, SSMS limits output...
December 29, 2015 at 11:37 am
Ed Wagner (12/28/2015)
charipg (12/28/2015)
is it correct ?SELECT * FROM tablename(nolock) where
startdate >= Getdate() -6
and enddate <= Getdate()
The GETDATE() returns a datetime, on which you can do integer math.
Just...
December 29, 2015 at 11:28 am
titsiros (12/26/2015)
December 28, 2015 at 9:30 am
BrainDonor (12/24/2015)
Sometimes a query may perform better if it uses sub-queries instead of CTEs
I hope you have some references to back this up. To the best of my knowledge,...
December 24, 2015 at 7:36 am
Just as an FYI, the AUTO and RAW options for XML give you very little flexibility. If you need your XML in a specific format, you are usually best...
December 23, 2015 at 8:12 am
You really should add a PARTITION BY clause to the query unless your database is limited to exactly one player. Once you have more than one player, all of your...
December 22, 2015 at 3:06 pm
stevennjuki (12/22/2015)
The column cl_a has values (1,2,3,4,5,6)
And for simplicity let's say the total rows to be fetched when computing the sums is only 3 and not...
December 22, 2015 at 2:46 pm
ChrisM@Work (12/22/2015)
December 22, 2015 at 1:23 pm
Perhaps this is too obvious, but does removing "FETCH NEXT 10 ROWS ONLY" give you the results that you want?
Drew
December 22, 2015 at 1:17 pm
I'm guessing that the actual issue is that he was inadvertently using integer division, since COUNT returns an integer.
Drew
December 21, 2015 at 2:53 pm
It looks like you're trying to recreate the windowed functions that already exist in T-SQL. Try the following instead:
SELECT STDEVP(basis) OVER(ORDER BY basis ROWS BETWEEN UNBOUNDED PRECEDING AND CURRENT...
December 16, 2015 at 10:14 am
Unfortunately that doesn't fit the format that we both posted a link to. In fact, I'm beginning to think that this is homework, because you have used the number...
December 14, 2015 at 2:48 pm
You don't say whether the items are in a separate table. (They probably should be, but that doesn't mean that they are.) It would help if you followed Forum...
December 14, 2015 at 1:56 pm
drooten (12/3/2015)
Mike01 (4/16/2012)
To avoid confusion for testing, use a day greater than 12.[/code]
Excellent suggestion Mike01!
After all, testing with a date such as 01/01/2015 is useless if you want to be...
December 4, 2015 at 9:48 am
Viewing 15 posts - 2,851 through 2,865 (of 4,087 total)