Forum Replies Created

Viewing 15 posts - 136 through 150 (of 163 total)

  • RE: Calculating the Number of Business Hours Passed Since a Point of Tme

    You can use the functions CalcTimeBetweenTwoDates & CalcTimeSinceCreated in any SQL statement, stored procedure or UDF

    For example

    select dbo.CalcTimeBetweenTwoDates(date_created, date_modified) from [Your Table]

    will give the duration between the two fields.

    select...

  • RE: Help! I'm a DBA! How did that happen?

    One tool that is readily available to you as a part of the SQL Server 2k5 without any additional cost is SSRS (SQL Server Reporting Services). You can use this...

  • RE: Question of the Day for 12 Jul 2004

    The another way to get the same result:

    select top 25 * from Products a

    where ProductID in (select top 50 ProductID from Products)

    order by...

  • RE: Want to Calculate Business Working hours

    Hi Venki,

    It is my pleasure to inform that I have posted the second version of my work

    Calculating the Number of Business Hours Passed Since a Point of Time[/url]

    I have modified...

  • RE: Problem in Query

    Sorry, no idea. You should provide the structure of your three tables x, y, z and some sample rows if you want more help.

    Sincerely,

    Maz

  • RE: Problem in Query

    Ahmad,

    I already gave you the answer. The keyword here that will solve your purpose is 'embedded query'

    The solution will be:

    ---------------------------------------------------------

    select z.category,x.count(distinct customers) as cnt, y.sum(sales) as sales from

    x inner...

  • RE: A New MVP

    Congatulations Steve,

    I feel honored too by associationg with you and the community through SQLserverCentral.

    Sincerely,

    Maz

  • RE: Calculating the Number of Business Hours Passed Since a Point of Tme

    Dear Carlos,

    You had a similar remark earlier also

    when i execute the function "select dbo.ufninc_CalcTimeSinceCreated (getdate(),getdate()+1)" it return 9 hours instead of the 8 hours.

    Then you sloved it yourself.

    By the...

  • RE: Problem in Query

    You can do like this:

    select Category, Count, sales from 'Your Table view or embedded query'

    union

    select 'Total', sum(Count), sum(Sales) from 'Your Table view or embedded query'

    order by 2

    The result will be:

    -------------------------

    Category Count Sales

    -------------------------

    ABC 1 250.00

    ZYX 2 450.00

    PQR 3 550.00

    Total 6 1250.00

  • RE: SQL SERVER 2005 vs ORACLE 10G

    You are right. This is a rat race. But in a rat race it is not guarented that the older and fatter rat will necessarily win.

    SQL Server is surely a...

  • RE: The Login dialog box appears repeatedly when I try to View reports.

    You can try to use SSRS 2005. I had the same problem with my SSRS 2005 reports when some one checked the anonymous login in the IIS folders. I fixed...

  • RE: Calculating the Number of Business Hours Passed Since a Point of Tme

    Hi carlos,

    Nice to see you back. I know the reason. This is because you need to modify your function dbo.ufninc_CalcGetDate

    I have clarified this in the first posting in this...

  • RE: Calculating the Number of Business Hours Passed Since a Point of Tme

    Dear carlosdanielsousa,

    Here is the bug:

    You need to move the code

    if dbo.ufninc_DataAMeiaNoite(@VarCalcCreateDate) in (select dbo.ufninc_DataAMeiaNoite (EffectiveIntervalStart) from dbo.CalendarRuleBase where ExtentCode=2 and SubCode=5)

    set @VarCalcCreateDate = dbo.ufninc_DataInicioTrab(@VarCalcCreateDate + 1)

    7 lines down its present...

  • RE: Calculating the Number of Business Hours Passed Since a Point of Tme

    I think I can resolve the issue if I see your modified code. Apparently it is not able to get out of the loop if the previous day of the...

  • RE: The Login dialog box appears repeatedly when I try to View reports.

    Also check the properties of the two virtual folders in the IIS and uncheck the 'Anonymious Login'

Viewing 15 posts - 136 through 150 (of 163 total)