Forum Replies Created

Viewing 15 posts - 61 through 75 (of 231 total)

  • RE: Using DateDiff to work as Excel Networkdays

    Thanks Phil -

    Ended up doing the following which does what I need it to do.

    SELECT C.comm_reference AS Referance

    ,C.current_task_target_date AS TargetDate

    ,DATEDIFF(d, C.current_task_target_date,CURRENT_TIMESTAMP) - NoWorkDays AS 'Days Past Target...

  • RE: Date Parameters Defaults

    Someone has posted on another site for me the following - which works - so if anyone needs to use it in the future.

    I use a long IIF() expression to...

  • RE: Date Parameters Defaults

    Again thank you for your generosity of replying but I don't think the example will help me as it is VB language I need in report builder.

    Thanks

  • RE: Date Parameters Defaults

    I got a feeling I may have posted in the wrong forum.

    These are parameters in Report Builder which uses VBA.

  • RE: Date Parameters Defaults

    Thanks, I've been playing about with these basic date functions but am still no where near close to working out how I do this to the next level, which is...

  • RE: Date Table

    Don't dare apolagise mate - You've helped me so much. Really appreciate it.

    Happy xmas.

  • RE: Date Table

    Incredible.

    Thank you so much, this is much more advanced than I'm used to but it "almost" gives me what I want.

    Looking at year 2015, this will include a leap year...

  • RE: Date Table

    Sorry I'm not making sense - the way we do our months here aren't really making sense to me either.

    Looking at the data again it looks to be that the...

  • RE: Date Table

    In answer to your question and to clarify.

    There is nothing special about the "weeks" as far as I am aware.

    I'll try and explain the month a bit better and apologise...

  • RE: Date Table

    Spreadsheet now attached with date examples

  • RE: Error running report

    Worked it out again guys - not long after posting on here.

    I enabled remote errors. - see here on how to do this -

    https://www.youtube.com/watch?v=PLIDL0FLkqI

    Then this changed the...

  • RE: The query did not run, or the database table could not be opened.

    Guys worked it out -

    I've created a SQL Server login on both databases - called linkedserver. I will then use this account to read the data from the linked...

  • RE: The query did not run, or the database table could not be opened.

    Hi - Set NoCount on didn't make any difference.

    Also where do I need to look for the security? My username of domain\uerid has access to both databases on each server?

  • RE: Collation issue

    Excellent guys.

    Placed it just in the CONCAT expression in the SELECT and the GROUP BY.

    Thank yo so much - Revised Code below.

    SELECT

    CONCAT(CONVERT(varchar(5),LEFT(IMADD.Postcode, 5)collate DATABASE_DEFAULT)

    ,

    '/'

    ,

    CASE

    WHEN DATEDIFF([year],IMIND.DOB, GETDATE()) - CASE WHEN...

  • RE: CAST or Convert

    Thanks Eugene Elutin, what you've suggested has worked for me.

Viewing 15 posts - 61 through 75 (of 231 total)