Viewing 15 posts - 5,206 through 5,220 (of 14,953 total)
I would almost certainly do this using Union All instead of Joins.
select Col1, Col2, Col3
from TableA
union all
select Col1, Col2, Col3
from TableB
union all
... and so on through the tables...
You can add...
January 28, 2011 at 6:06 am
I would definitely include scheduled downtime as downtime.
If backup servers, etc., can keep things up for customers/employees/etc., then it's not downtime for the database, which is what really matters. ...
January 28, 2011 at 6:02 am
Yes, it's currently defined as adequate to know that a change was made. What happens if a row is changed five times in two minutes by four different people?
I'm...
January 27, 2011 at 1:21 pm
Like Gail, I'd be inclined to split the triggers up. SQL Server will want to have execution plans for them, and multiple internal branches generally result in expensive plans....
January 27, 2011 at 12:47 pm
;WITH MaxDates (OrderID, MaxDate) AS
(SELECT OrderID, MAX(OrderDate)
FROM MyTable
GROUP BY OrderID)
SELECT T1.*
FROM MyTable AS T1
LEFT JOIN CTE
ON T1.OrderID = CTE.OrderID
AND T1.OrderDate = CTE.MaxDate
WHERE CTE.OrderID IS NULL;
The "CTE" (Common Table Expression) picks...
January 27, 2011 at 12:33 pm
select EmpID, min(Date)
from MyTable
group by EmpID;
Does that do what you need?
January 27, 2011 at 12:19 pm
What's the "max order date"? Is that a column in a table? A variable? An input parameter?
January 27, 2011 at 11:15 am
You can, but it's not necessarily going to benefit you. The 1-file-per-CPU thing is more of an urban legend than a valid solution, in many/most cases.
Check this for details:...
January 27, 2011 at 8:15 am
You have to change to Ragged Right instead of Fixed Width. Fixed Width is for mainframe output, which doesn't use row delimiters.
January 27, 2011 at 8:11 am
SSIS does this easily. You specify which sheet to export to in your Excel Destination object in a Data Flow definition.
January 27, 2011 at 6:39 am
On the question about Query Designer, no. Microsoft pretty routinely hides their code.
It wouldn't be that hard to take an execution plan and turn it into a query in...
January 27, 2011 at 6:35 am
You can break up queries like that by doing the IsNumeric query to populate a temp table, then doing the rest of the action on the temp table, or by...
January 27, 2011 at 6:32 am
Brandie Tarvin (1/27/2011)
If so, what are your thoughts on the organization?
My employer is sponsoring membership and I'm trying to figure out whether it's worth...
January 27, 2011 at 6:20 am
GilaMonster (1/26/2011)
Stefan Krzywicki (1/26/2011)
Where the hell did January go? I think it might have been buried in snow and I missed it.
Wasn't the snow. I missed most of it too,...
January 26, 2011 at 1:51 pm
Viewing 15 posts - 5,206 through 5,220 (of 14,953 total)