Viewing 11 posts - 1 through 11 (of 11 total)
Lynn yours worked, that is what i needed, Thanks again
March 4, 2013 at 3:01 pm
Never Mind i figured out
select
(CONVERT(varchar(6), DATEDIFF(second, minibgtime, maxendtime)/3600) + ':' +
RIGHT('0' + CONVERT(varchar(2), (DATEDIFF(second, minibgtime, maxendtime) % 3600) / 60), 2) + ':' +
RIGHT('0' + CONVERT(varchar(2), DATEDIFF(second, minibgtime, maxendtime)...
February 20, 2013 at 3:28 pm
select
datediff (Mi,Cast((minibgtime) as datetime), Cast((maxendtime) as datetime))/60) as Total_Minutes
from tablename
The above Sql Query should give me 2:30:00 instead of 150 minutes, here i have make changes in the above...
February 20, 2013 at 3:09 pm
Sorry the above has some mistakes,pls consider this
select PKG_NME, BG_DTTM, END_DTTM, PKG_STU
from
(select ST.PKG_NME, ST.BG_DTTM, ST.END_DTTM
,ST.PKG_STU
,row_number() over(partition by ST.PKG_NME order by ST.BG_DTTM desc) as LatestRun
from
dbo.VW_JOB_EXCTN_RPT ST) ST1
where (ST1.LatestRun=1 and
PKG_NME like '%EDW_IDS%FACT')or
(ST1.LatestRun=1...
February 20, 2013 at 10:34 am
select PKG_NME, BG_DTTM, END_DTTM, PKG_STU
from
(select ST.PKG_NME, ST.BG_DTTM, ST.END_DTTM
,ST.PKG_STU
,BG_DTTM = select min(ST.BG_DTTM) from
,row_number() over(partition by ST.PKG_NME order by ST.BG_DTTM desc) as LatestRun
from
dbo.VW_JOB_EXCTN_RPT ST) ST1
where (ST1.LatestRun=1 and
PKG_NME like '%EDW_IDS%FACT')or
(ST1.LatestRun=1 and
PKG_NME like 'MST_EDW%CHILD_MASTER')
order...
February 20, 2013 at 10:30 am
if i go woth your suggestion then i need to group it by the other non aggregated columns, if i group it my results will go wrong, so i am...
February 20, 2013 at 10:00 am
Just to make calrify, my requirement is i have 5 ole db sources that i have load it into a SINGLE flat file
why 5 ole db sources?
As i dont have...
February 19, 2013 at 11:15 am
FYI, No Sorting requirements, and flat file formatting is delimeter, Thanks.
February 19, 2013 at 10:19 am
Sorry in the first statement i said there are keys , But they are no keys to join i mean no relationship between the tables.
February 18, 2013 at 1:53 pm
i have 5 logging tables with keys to join like
Table 1:
Columns : A,B,C
Table 2:
Columns : D,E,F,G
Table 3:
Columns : H,I,J,k,l
Table 1:
Columns : M,N
Table 1:
Columns : A1,B1,C1
i want to pick only...
February 18, 2013 at 1:52 pm
Viewing 11 posts - 1 through 11 (of 11 total)