Viewing 5 posts - 1 through 5 (of 5 total)
try this...it should give you want you want. I'm sure it can be improved upon, but it's a starting point.
--drop table #tableA
CREATE table #tableA
(
ItemNumber int identity not null,
BreakQty1 int,BreakQty2...
September 10, 2007 at 11:18 am
Try this...
create Table #sessions
(
sessionNumber int Identity (1,1) Not Null,
roomNumber varchar (10) Not Null,
dateofStart datetime Not Null,
dateofEnd datetime Not Null,
)
create Table #Rooms
(
roomID int Identity (1,1) Not Null,
roomnumber varchar(10),
rate smallmoney,
)
--roomNumber...
September 10, 2007 at 7:18 am
This line...
Convert(varchar(25),(CAST (@PREV_MONTH AS VARCHAR(11)) + '-'+ CAST (@CURR_MONTH AS VARCHAR(11))))
...is this one causing the problem, but I'm wondering why you would want to group by static data anyway? @PREV_MONTH and...
May 2, 2006 at 5:45 am
Won't this work?
select objName=object_name(sc.id), Length=len(sc.text)
into #tmpX
from syscomments sc
where OBJECTPROPERTY(sc.id,'IsProcedure') = 1
select objName, Length=sum(length)
from #tmpX
group by objName
order by Length desc
--drop table #tmpX
April 5, 2006 at 6:57 am
Viewing 5 posts - 1 through 5 (of 5 total)