Viewing 15 posts - 6,631 through 6,645 (of 7,597 total)
SELECT
'20130701' AS Date, Year,
6 AS JulyMaxhours,
SUM(6) AS Total_Hours,
KindOfDay, Month
FROM Auxiliary.Calendar
WHERE (KindOfDay =...
March 19, 2013 at 11:46 am
It's easy enough to generate the code for 00 to 99 based on the pattern for 00, so it's not really "manual" coding.
I figured on a (very broad) average of...
March 19, 2013 at 11:42 am
Not sure I fully understand, but maybe:
SELECT Date, Year, CASE DATEPART(mm, date) WHEN 07 THEN 6 END AS JulyMaxhours, KindOfDay, Month,
SUM(CASE WHEN DATEPART(mm, date) = 07 THEN 6 ELSE 0...
March 19, 2013 at 11:13 am
CREATE PROCEDURE [dbo].[GetExtractSiteExtractFileBatchPreviousSuccessInd]
@BatchStatusCd NVARCHAR(5)
,@ExtractSiteCd NVARCHAR(10)
,@ExtractAsOfDate DATETIME
AS
RETURN (
SELECT CASE
...
March 19, 2013 at 11:09 am
Maybe consider records to "match" if the SSN, first name and birth date all match. My reasoning: last name can change (marriage, etc.), and middle name may not be...
March 19, 2013 at 10:56 am
Or, depending on your specific needs, you could add your own logging/pseudotrace code to the proc itself, and trigger it with an optional parameter:
CREATE PROCEDURE dbo.proc_name
@...,
...
March 19, 2013 at 10:48 am
You don't really need SSMS to generate the statement. [And of course you don't try to make the change using SSMS, as SSMS will rebuild the entire table foe...
March 19, 2013 at 8:59 am
winmansoft, you should also be aware of the 14-byte-per-row overhead that READ_COMMITTED_SNAPSHOT requires. Anytime a row is updated, or a new row is inserted, the 14 bytes will be...
March 18, 2013 at 4:40 pm
brettstahlman (3/18/2013)
Lynn Pettis (3/16/2013)
brettstahlman (3/16/2013)
Lynn Pettis (3/16/2013)
brettstahlman (3/16/2013)
opc.three (3/16/2013)
March 18, 2013 at 2:22 pm
Could you go to NUMERIC(19,6)? That should work fine, and I think it will be just a metadata change.
March 18, 2013 at 10:28 am
This is off the wall, but did "AUTO_CLOSE" somehow get set on for that db?
That's a longshot, since even if it did it should auto_open when you reference it, but...
March 15, 2013 at 3:47 pm
Interesting.
SSMS is probably internally running a query / stored proc to get the list of databases. Obviously the "SET ROWCOUNT" is affecting the code it uses as well.
I guess...
March 15, 2013 at 3:32 pm
For certain UPDATE statements, SQL must instead actually do a DELETE and an INSERT instead of an UPDATE. So, the result is normal for SQL.
If you need to see...
March 15, 2013 at 3:26 pm
Or, another possibility (with no character conversions/manipulation):
SELECT
ColA, ColB,
DATEADD(SECOND, ColB % 100, DATEADD(MINUTE, ColB % 10000 / 100, DATEADD(HOUR, ColB /...
March 15, 2013 at 3:22 pm
I thought my query might meet the stated requirement while knocking out the second table scan :-).
If OP does need to list the alternate supplier(s), then yes, I think some...
March 15, 2013 at 8:22 am
Viewing 15 posts - 6,631 through 6,645 (of 7,597 total)