Viewing 15 posts - 6,241 through 6,255 (of 6,486 total)
Well - we're now talking about two distinct concepts: High availability and "load balancing". In many ways - the two have opposing priorities, so talking about them as if they...
September 25, 2007 at 9:25 am
derived table is the name of the game.
select e.empid, e.empname, e.salary, da.avgsalary, e.deptid
from
edtl inner join
(select deptid, avg(salary) as avgsalary from edtl group by deptid) da
on e.deptid=da.deptid
where e.salary<da.avgsalary
September 25, 2007 at 9:04 am
You want to look into what protocols are enabled on the SQL server, and set up the client Network Utility for SQL to match on the new Vista machine. ...
September 25, 2007 at 9:00 am
I'd be curious to know if they would have had better response if they were ask to pay something. There's a HUGE bias against anything "free" (based no doubt...
September 25, 2007 at 8:48 am
...well - they DO talk about the concept of setting up "Federated Databases", so as to partition load across multiple SQL servers. Not automated, and does take a fair...
September 25, 2007 at 8:32 am
You can use these for your filtering parameters. Not that this makes a HUGE assumption that no call is ever >24 hours (which you seem to be making, since...
September 25, 2007 at 8:17 am
A Join will work a LOT better than a correlated sub-query. If you have a reasonable sized table you'd see a difference trying to run this:
select d1.Id, d1.theDate,
isnull(datediff(hour, d2.theDate, d1.thedate),0)
from...
September 25, 2007 at 7:11 am
Select s.sessionnumber, sum(datediff(dd,s.startdate,s.enddate)*a.rate) as TotalOwed,
min(isnull(p.totpaid, 0)) as TotalPaid, sum(datediff(dd,s.startdate,s.enddate)*a.rate)-min(isnull(p.totpaid, 0)) as Balance
from sessions s inner join accounts a on s.sessionnumber=a.sessionnumber
left join (select sessionnumber, sum(amountpaid) Totpaid from payments group by sessionnumber) p
on...
September 25, 2007 at 7:03 am
Ahmad -
I can't tell what the actual question/issue is. There simply isn't enough info to tell. Are you looking to have the values on the same line? It would...
September 25, 2007 at 6:43 am
By the way - if you should simply flip the CASE syntax around so that you can express it as an IN as opposed to a NOT IN, it actually...
September 24, 2007 at 4:20 pm
Understood Lynn - I noticed OP had calculation backwards. I should have specified WHO the comment was directed at. I haven't figured out the quote thingie in the new version...
September 24, 2007 at 3:23 pm
For what it's worth - that's the INVERSE of a percentage.
Percent of total = group total/Grand total (NOT Grand total/Group Total).
Might as well save you the pain before an accounting...
September 24, 2007 at 3:07 pm
Try creating a DB of the same name, with empty files in the same places, etc...
Shut SQL down and replace the new files with the corrupted ones. Start SQL,...
September 24, 2007 at 2:19 pm
This should give you correct results, but won't be the fastest thing on the planet on your large dataset.
Indexing could help quite a bit, and/or a computed column with...
September 24, 2007 at 1:42 pm
Performance-wise, you might care to revert back to the "case" syntax for creating your pivot table (i.e. the SQL 2000 "way" for pivoting tables) and adding in the WITH ROLLUP option...
September 24, 2007 at 10:06 am
Viewing 15 posts - 6,241 through 6,255 (of 6,486 total)