Viewing 15 posts - 2,116 through 2,130 (of 6,036 total)
Paul White (2/23/2013)
I do wonder why anyone would covert a 16-byte uuid to a 36-character string though.
I wonder where do you find someone who would not... :crazy:
:hehe:
February 25, 2013 at 6:16 pm
My argument was based on the use of triggers to implement business logic and to do the sort of data integrity checking that should be enforced by keys and constraints....
February 19, 2013 at 6:16 pm
jfogel (2/19/2013)
February 19, 2013 at 6:05 pm
1. Revise the code to implement the best practices.
2. Make sure you have appropriate indexes in place and your code in trigger uses it.
Having these conditions fulfilled you should not...
February 18, 2013 at 5:50 pm
Jeff Moden (9/25/2012)
Michael Valentine Jones (9/25/2012)
You can use the function on the link below to find the age:Age Function F_AGE_IN_YEARS
Any chance of making it NOT a scalar function?
SELECT DATEDIFF(yy, 0,...
February 17, 2013 at 6:59 pm
You should put the whole initial query into the derived table, except for ORDER BY clause:
USE ICP;
GO
DECLARE @beginDatum Datetime
DECLARE @eindDatum Datetime
SELECT dtSums.Tijdsduur, dtSums.WrapUp, dtSums.OnHold, dtSums.Tijdsduur - dtSums.WrapUp - dtSums.OnHold AS...
February 17, 2013 at 3:11 pm
Should be really way simpler
SELECT
dob,
[day],
DATEDIFF(yy, 0, [day] - dob) Years,
DATEDIFF(MM, 0, [day] - dob)%12 Months,
DATEDIFF(dd, DATEADD(mm, DATEDIFF(mm, 0, [day] - dob), 0), [day] - dob) days
FROM (
SELECT...
February 14, 2013 at 9:48 pm
Or you can create a view on top of the table with those FLOAT columns converted to VARCHAR and set up an INSTEAD OF INSERT, UPDATE trigger on it -...
February 14, 2013 at 5:10 pm
dwain.c (1/15/2013)
February 13, 2013 at 7:06 pm
Try to build a "full select" query to include all sequential references from the "root" table to the smallest "seed":
SELECT *
FROM Table1 A
LEFT JOIN Table2 B ON B.Col = A.Key
LEFT...
February 13, 2013 at 6:57 pm
ohpenot (2/13/2013)
That is exactly what i was looking for.
Not sure about that.
Did you try to run it?
It won't work if those columns in dbo.Tablebase are of FLOAT data type.
Table...
February 13, 2013 at 5:32 pm
Pete-600513 (1/19/2013)
Thank you very much. I thought there might be an easy way with the max function
You were right.
SELECT DT.max_score, A.name, a.dob
FROM dbo.Exam A
INNER JOIN (SELECT MAX(score) max_score
FROM dbo.Exam
) DT...
February 13, 2013 at 5:07 pm
momba (2/5/2013)
February 12, 2013 at 7:37 pm
This modification will make sure you include only actually existing tables and do not miss any of them:
declare @SQLCmd nvarchar(max), @Params nvarchar(max), @DiscDate datetime ;
SET @DiscDate = '20090630';
set @Params =...
February 12, 2013 at 7:22 pm
Update Test
Set UpdateField = case when MinDuration < 12 then Right else Left end
from Test
February 7, 2013 at 8:24 pm
Viewing 15 posts - 2,116 through 2,130 (of 6,036 total)