Forum Replies Created

Viewing 15 posts - 511 through 525 (of 902 total)

  • RE: Format date time

    MyDoggieJessie (11/20/2012)


    How about SELECT CONVERT(VARCHAR(25), GETDATE(), 22)

    That actually formats the date as mm/dd/yy (h)h:mm:ss AM(PM), so you end up with a shortend year, which when it comes to converting back...

  • RE: Creating a Stored Procedure that accepts parameters

    as i'm in a bit of a lul at the moment I thought I've have a crack at it, and its one of the most comprehensive set of DDL I've...

  • RE: Find a string in SSIS Packages folder

    duggal.priyanka06 (11/20/2012)


    Hi,

    I have a folder of about 250 packages. I want to find all the packages which have a string '2075' . Please suggest how can I do this. I...

  • RE: Updation

    There probably is but you'd have to decide the rules and which one should be considered the Anchor row.

  • RE: Updation

    Glad to help.

    You can actually get rid of the where Clause its superflous, or you could change it to limit the update to only rows that arnt already set or...

  • RE: Get Records according to dataset.

    dwain.c (11/18/2012)


    CELKO (11/18/2012)


    Yes, we can help you be a bad SQL programmer, if you really want to be a bad programmer. But why?

    So you can be promoted to a...

  • RE: Updation

    kapil_kk (11/19/2012)


    but jason I alsio need to updateed parentprocedureID of procedureId 86 as 86 only----

    Personally I think thats the wrong path to take, as a Parent should not be the...

  • RE: Updation

    Heres some code that may be what you are looking for and sets the rows where the Procedurecode = '0062A' and '0062B' with 86, but doesnt do that where the...

  • RE: Updation

    kapil_kk (11/19/2012)


    i have already posted the script of table creation with some sample data...

    Well you posted the DDL for a table called ProcedureCode, but not one for ProcedureMaster, which is...

  • RE: Pivot Query

    No problem, and technically MAX is classed as an aggregation function in BoL,

  • RE: Query Optimization

    farooq.hbs (11/16/2012)


    Jason & Guys,

    I'm bit confused with discussion going on here.

    Sorry as tends to happen on message boards things sometimes get a little side tracked, hopefully we can bring...

  • RE: Accurate Computation of Age

    Heres another take on it using FLOOR to strip of the decimal places.

    Declare @dob date = '14-nov-1987'

    Print @dob

    Print Datediff(D,@dob,getdate())

    Select Floor(Datediff(D,@dob,getdate()) / 365.25) Years

    , Floor(Datediff(D,@dob,getdate()) % 365.25) Days

  • RE: Pivot Query

    kunal.desai 7690 (11/16/2012)


    Jason : I read those articles. They are excellent!! But afterall, they use aggregate functions and that is not what I want.

    BriPan : I tried your query,...

  • RE: Hierarchies on Steroids #2: A Replacement for Nested Sets Calculations

    Jeff,

    As with the first article its top draw, though I'm still reading through them both and making the various links to previous experiences, I like the use of the...

  • RE: Which is best way

    I suppose its an 'it depends' answer, your code is ok if you have simple queries, however when you get into complex queries with Multiple paramater combinations it will become...

Viewing 15 posts - 511 through 525 (of 902 total)