Viewing 15 posts - 121 through 135 (of 1,473 total)
Paul White NZ (5/1/2010)
Garadin (5/1/2010)
Also, even though you have the overhead of a scalar UDF that accesses data, due to the pattern that I'm imagining this would take (Passing just...
May 3, 2010 at 2:32 pm
I'm assuming a copy/paste is out of the question? =)
What about using a data source from the excel worksheet to pull the data in?
May 3, 2010 at 2:10 pm
You had the right general idea, with a slight misunderstanding. You can't check the EXISTS first you have to check the exists for each line. Just do the...
May 3, 2010 at 2:03 pm
Garadin (5/1/2010)
What about putting a trigger on the table that stored the default values to modify the default constraints of the data table. That...
May 1, 2010 at 11:08 am
Continuing with the crazy ideas...
What about putting a trigger on the table that stored the default values to modify the default constraints of the data table. That way...
May 1, 2010 at 10:27 am
Paul White NZ (5/1/2010)
Garadin (4/30/2010)
May 1, 2010 at 10:23 am
Right, I figured as much, which is why I mentioned the where clause and the outer joins. YOu need to take the criteria out of your where clause and...
May 1, 2010 at 10:02 am
I'll admit that I scanned this, but I didn't see anyone mention a UDF as the default constraint on the column that does a lookup for the value in the...
April 30, 2010 at 10:32 pm
Why do you need such a thing? What are you trying to achieve?
April 30, 2010 at 2:04 pm
Danny Sheridan (4/30/2010)
(wish I went to college for CS or DB Development/Management :ermm:). Learn something new everyday!
You could probably count on one hand the number of regulars here...
April 30, 2010 at 2:01 pm
I'm afraid I couldn't make out enough of that to understand the question, but I will note that having criteria in your WHERE clause targeting SIPFIS and LG_086_01_GNTOTST turns those...
April 30, 2010 at 12:11 pm
Perhaps...?
UPDATE [PMReporting_CostModel]
SET [month]= MONTH(DATEADD(dd, @dateshift, CONVERT(datetime, CAST([month] AS varchar(2))+'/1/'+CAST([year] AS varchar(4)),126) AS CostModelDate)),
[year]= YEAR(DATEADD(dd, @dateshift, CONVERT(datetime, CAST([month] AS varchar(2))+'/1/'+CAST([year] AS varchar(4)),126) AS CostModelDate))
WHERE...
April 30, 2010 at 12:06 pm
A rollback inside a trigger will roll back the row that fired the trigger. However, you can use a try/catch block to catch the error and take appropriate action...
April 30, 2010 at 12:00 pm
Another method. (Thanks for the setup code Bob)
declare @sample table (RecID int, RecType int, Hierarchy int, Msg char(1))
insert into @sample
Values
(1, 5555, 10, null ),
(2, 5555, 20, null ),
(3, 5555,...
April 29, 2010 at 3:19 pm
If Dynamic SQL isn't an option, you can also use something like this:
WHERE
(@FirstName IS NULL OR FirstName LIKE @Firstname)
AND (@Lastname IS NULL...
April 29, 2010 at 3:07 pm
Viewing 15 posts - 121 through 135 (of 1,473 total)