Forum Replies Created

Viewing 15 posts - 1,726 through 1,740 (of 3,957 total)

  • RE: Using a Recursive CTE to Generate a List

    Hi Svetlana!

    I think this is a nice introductory tutorial on using rCTEs.

    However like a couple of folks that have already replied, I'd do it a little differently:

    WITH Offices AS (

    ...

  • RE: Are the posted questions getting worse?

    dwain.c (7/8/2013)


    Steve Jones - SSC Editor (7/8/2013)


    Notifications working for people? Seem like the queue might be stuck.

    Queue is definitely still stuck, although I did just receive one notification on this...

  • RE: How to import non-delimited text file

    reid.kell (7/3/2013)


    ...

    I need two of the 35 values (SubnetMask and SubnetDescription) for each of the 5000+ records in this long, continuous file. ...

    reid.kell (7/8/2013)


    Dwain.c, your code generates a single...

  • RE: Are the posted questions getting worse?

    Steve Jones - SSC Editor (7/8/2013)


    Notifications working for people? Seem like the queue might be stuck.

    Queue is definitely still stuck, although I did just receive one notification on this thread...

  • RE: Are the posted questions getting worse?

    Jeff Moden (7/8/2013)


    L' Eomot Inversé (7/7/2013)


    jasona.work (7/5/2013)


    Koen Verbeeck (7/5/2013)


    jasona.work (7/5/2013)


    You *KNOW* it's going to be a slow day when you get in at your normal time, and get front-row parking...

    I...

  • RE: Order of rows in a Table with Identity Column.

    Excuse me for asking a dumb question here but the OP says the TransactionID is the primary key with presumably a clustered index on it (my assumption).

    In that case, without...

  • RE: querying specific rows by list

    Assuming your Excel sheet is accessible from the SQL Server, you can use Chrissy's INNER JOIN on an OPENROWSET to read directly from the Excel sheet.

  • RE: Max of 2 dates

    Hoo-uh! And here I thought everyone had forgotten this thread.

    I'm not surprised by the results. I've had to clock down the machine I did this timing test on...

  • RE: Sequential numeric

    I hesitate to say this but I don't think you've got enough information to solve this.

    Any query that might appear to solve it would need to rely on the ordering...

  • RE: How to Add a Date randomly

    Jeff Moden (7/5/2013)


    dwain.c (7/4/2013)


    What in Buddha's name is a "lac day?"

    "lac" is 100,000 in the OP's language.

    Oh, I get it! It can be used like a productivity measure:

    SLOC/lac-days

  • RE: CONVERT COLUMN VALUES TO COMMA SEPARATED ONE ROW VALUE..

    Sean Pearce (7/5/2013)


    dwain.c (7/4/2013)


    Jeff Moden (7/4/2013)


    The other thing to worry about is that XML will entitize (change to a code sequence) certain characters if they are present.

    I don't...

  • RE: Convert Row to Column

    Mark-101232 (7/5/2013)


    Mark - That's a pretty slick approach.

    ... uses your method here[/url]

    Flattery will get you everywhere! 🙂

    But, I actually saw the UNION ALL method the first time in the discussion...

  • RE: Convert Row to Column

    What an odd requirement!

    Mark - That's a pretty slick approach.

    Using Eugene's suggestion of a Crosstab query, this is the best (or at least the least messy approach) I could come...

  • RE: CONVERT COLUMN VALUES TO COMMA SEPARATED ONE ROW VALUE..

    Jeff Moden (7/4/2013)


    The other thing to worry about is that XML will entitize (change to a code sequence) certain characters if they are present.

    I don't suppose you'd know...

  • RE: Max of 2 dates

    What, no takers? OK then I'll go for it.

    Test harness (now 1M rows):

    /**************************************************

    (1) Sample Data

    **************************************************/

    IF OBJECT_ID('tempdb..table1') IS NOT NULL

    DROP TABLE table1;

    IF OBJECT_ID('tempdb..table2') IS NOT NULL

    DROP TABLE table2;

    IF OBJECT_ID('tempdb..tally') IS...

Viewing 15 posts - 1,726 through 1,740 (of 3,957 total)