Forum Replies Created

Viewing 15 posts - 211 through 225 (of 2,007 total)

  • RE: Growing Your SQL Server Skills without Breaking the Bank

    In the UK, there's also SQLBits[/url]. Again, not cheap (although there is a free day), but excellent. And they do upload videos of the talks (eventually :-P)

  • RE: Find integer at end of a string. There *must* be a better solution ?

    Lowell (7/26/2013)


    Cadavre I love your new signature with the nolock pointers! just noticed it today.

    I added it after the last time I had to dig them all out 🙂

  • RE: Find integer at end of a string. There *must* be a better solution ?

    Forgive me for my simplistic approach 😀

    WITH tmp

    AS (SELECT x = 'some text-1'

    UNION ALL SELECT x = 'some text-123'

    UNION ALL SELECT x...

  • RE: Using a Recursive CTE to Generate a List

    Nice article, but was wondering if there was any reason you'd do that over using FOR XML PATH to concatenate a string? I'd imagine that the IO of the recursive...

  • RE: help with joining to table with non unique index and duplicate rows

    Another guess: -

    SELECT sv.SVSEQ, sc.SCACO, ac.f1 AS AccountNo,

    ne.NEAN, ne.NEEAN, bg.BGCFN1, bg.BGCFN2,

    bg.BGCFN3, bg.BGCUS, sv.SVNA1, sv.SVNA2,

    sv.SVNA3, sv.SVNA4, sv.SVNA5, sv.SVPZIP,

    sv.SVCSA, sc.SCACO, sx.SXDLM

    FROM NEPF ne

    INNER JOIN tmpAccountList ac ON NEEAN...

  • RE: The US Holiday

    Took dredging it up from the depths of my memory, but I got it. I run a dark theme, e.g. black background. All the rest of the colours are customised...

  • RE: sql quantity sold per day

    engstevo (7/3/2013)


    I have tried this but my head of it department still telling me tht i have failed this is my last chance

    Write a SQL statement from the above example...

  • RE: substring comparison for last 2 characters

    timscronin (7/1/2013)


    I have a field with data like below I need to join on

    patid

    123453

    124344ME

    323390

    3233MS

    I need to remove the last 2 charcters if they are not numeric. So my results...

  • RE: Query Help

    kapil_kk (6/30/2013)


    thnks its working.. but can you plz explain me this part of query:

    SUBSTRING(VoucherNo,2,LEN(VoucherNo)) - ROW_NUMBER() OVER(ORDER BY VoucherNo, TransNo)

    Sure. I'm removing the character from the start of the voucherno...

  • RE: Group by - Retaining all serial numbers

    akberali67 (6/29/2013)


    Hi,

    Firstly, I Apologize for presenting the data the way I did.

    No problem, just remember for next time 😀

    akberali67 (6/29/2013)


    Just one final question is whether the numbers would be ordered...

  • RE: Query Help

    kapil_kk (6/29/2013)


    Srry that was typo misktake in my question n i Have corrected that...

    that was trns1 only not trns2...

    I tried it but not it is not possible with min max...

  • RE: Group by - Retaining all serial numbers

    First things first, when you visit a technical forum it is always a good idea to provide as much information as possible and to make it as easy as possible...

  • RE: Query Help

    kapil_kk (6/29/2013)


    Hi,

    I need help in getting this type of output, I tired with MIN and MAX function but didnt get required output:

    Create table T1

    (Id int identity primary key,

    VoucherNo varchar(10),

    TransNo varchar(10)

    )

    Insert...

  • RE: "Running totals" query

    SQL Server 2012 is good for running totals.

    I've also used Hugo's cursor for running totals and Jeff's quirky update method. Jeff's is quicker, so I generally use that for...

  • RE: Query improvement

    ChrisM@Work (6/27/2013)


    Why read the table twice?

    SELECT

    sumyy = sum(yy),

    xx = ???('summary line') -- where ??? is an aggregate function

    FROM tablea

    CROSS APPLY (

    SELECT SurrogateGroup = CASE

    WHEN somedate_column < @startdate_parameter...

Viewing 15 posts - 211 through 225 (of 2,007 total)