Viewing 15 posts - 3,091 through 3,105 (of 9,703 total)
rkl1v09 (8/22/2014)
Hi Brandie,Due date is DATETIME and i am literally just looking for 2 months data.
Kind Regards,
R
Then instead of
WHERE DATEDIFF(MONTH,a.trans_date,a.due_date) >= 2
Try
WHERE a.due_date >= DATEADD(m,-2,CONVERT(DATE,GETDATE(),101))
This gives you every date...
August 22, 2014 at 7:38 am
ChrisM@Work (8/22/2014)
Brandie Tarvin (8/22/2014)
Chris,Why the STUFF() and the XML?
It's concatenation of values from different rows of the same column, Brandie.
Split up the email addresses onto different rows, eliminate any...
August 22, 2014 at 6:24 am
Steve,
Look at Chris's code carefully, because he makes a point I think you missed. OUTER JOINs don't work as OUTER JOINs when you explicity reference the columns in the WHERE...
August 22, 2014 at 4:52 am
djj (8/22/2014)
Brandie Tarvin (8/22/2014)
lpablo (8/22/2014)
DECLARE @Email2 VARCHAR(100)
Set @email= 'helper@sql-server-helper.com'
set @email2='fff@dd.com, helper@sql-server-helper.com,vc@.com'
SELECT case when @email2 like '%'...
August 22, 2014 at 4:46 am
Important questions. What data type is DueDate? DATE or DATETIME / SMALLDATETIME?
If a DATETIME variety, do you need everything from midnight on or are you looking for literally 2...
August 22, 2014 at 4:42 am
Aaaannnnnddddd... From the theatre of the absurd, I couldn't get PATINDEX() to work, but I did get CHARINDEX() and REPLACE() to work. I don't know why anyone would want to...
August 22, 2014 at 4:37 am
Myke85 (8/21/2014)
DECLARE @Email VARCHAR(100)
DECLARE @Email2 VARCHAR(100)
Set @email= 'helper@sql-server-helper.com'
set @email2='fff@dd.com, helper@sql-server-helper.com,vc@.com'
SELECT case when @email like...
August 22, 2014 at 4:30 am
lpablo (8/22/2014)
DECLARE @Email2 VARCHAR(100)
Set @email= 'helper@sql-server-helper.com'
set @email2='fff@dd.com, helper@sql-server-helper.com,vc@.com'
SELECT case when @email2 like '%' + @email1 +...
August 22, 2014 at 4:22 am
Bah... Crosstabs...
Luis Cazares (8/21/2014)
Are you seriously taking the advice and code from someone from the internet without testing it?
Why, yes. Yes I am.
Luis Cazares (8/21/2014)
August 22, 2014 at 4:12 am
Perry Whittle (8/21/2014)
arnipetursson (8/21/2014)
One more question.If you do not have access to server B beyond db_owner in the database,
how do you ensure that the logins (server principals) are synced?
Curious, how...
August 22, 2014 at 4:05 am
happycat59 (8/21/2014)
arnipetursson (8/21/2014)
One more question.If you do not have access to server B beyond db_owner in the database,
how do you ensure that the logins (server principals) are synced?
As db_owner, you...
August 22, 2014 at 4:03 am
Myke85 (8/21/2014)
DECLARE @Email VARCHAR(100)
DECLARE @Email2 VARCHAR(100)
Set @email= 'helper@sql-server-helper.com'
set @email2='fff@dd.com, helper@sql-server-helper.com,vc@.com'
SELECT case when @email like...
August 21, 2014 at 12:43 pm
And that's what happens when I forget how to read a post all the way through. @=)
August 21, 2014 at 11:48 am
On another note, I recently found that I can also just break the mirror from either the primary or the secondary as per this BOL note. So it all depends...
August 21, 2014 at 11:19 am
Viewing 15 posts - 3,091 through 3,105 (of 9,703 total)