Are the posted questions getting worse?

  • WayneS (6/20/2009)


    Jeff Moden (6/17/2009)


    Ummmm.... my rule of thumb is to peel one potato at a time on the quirky update...

    Hey Jeff, I remember reading a post where you loaded in a massive file in microseconds (astonishing all others that were working on the problem)... do you happen to have a link to that thread so I can review it again?

    Thanks,

    Heh... it wasn't quite that effective but I remember the post. I don't have a link saved anywhere, though. Sorry. I'll take a quick look for it but I probably don't remember enough detail to find it.

    Of course, if you're using IE and you manage to find the post, the code windows are gonna be pretty tough on you. 😛

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)

  • Paul White (6/19/2009)


    Jeff Moden (6/19/2009)


    Heh... cool... maybe a little head boiling will get him to fix the code windows for IE? 😛

    I admire your persistence.

    And your optimism!

    😛

    ... and neither have paid of so far. I'll keep trying. It would be really helpful if several other IE users started throwing rocks at this annoying problem.

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)

  • Jeff Moden (6/20/2009)


    Paul White (6/19/2009)


    Jeff Moden (6/19/2009)


    Heh... cool... maybe a little head boiling will get him to fix the code windows for IE? 😛

    I admire your persistence.

    And your optimism!

    😛

    ... and neither have paid of so far. I'll keep trying. It would be really helpful if several other IE users started throwing rocks at this annoying problem.

    ummm.... That'd require me to use IE. But hey, seeing those code windows work in IE would be great.

    -Luke.

    To help us help you read this[/url]For better help with performance problems please read this[/url]

  • Jeff Moden (6/20/2009)


    It would be really helpful if several other IE users started throwing rocks at this annoying problem.

    Hey Jeff,

    So yeah - I'm game - at whom should we throw rocks?

    BTW I just fired up IE8 (version 8.0.6001.18702 it says) and the code windows look about the same as they do in Chrome 2. Are we talking about the code="sql" embedded stuff or something else? What are the major problems that you see?

    Cheers,

    Paul

  • Jeff Moden (6/20/2009)


    WayneS (6/20/2009)


    Jeff Moden (6/17/2009)


    Ummmm.... my rule of thumb is to peel one potato at a time on the quirky update...

    Hey Jeff, I remember reading a post where you loaded in a massive file in microseconds (astonishing all others that were working on the problem)... do you happen to have a link to that thread so I can review it again?

    Thanks,

    Heh... it wasn't quite that effective but I remember the post. I don't have a link saved anywhere, though. Sorry. I'll take a quick look for it but I probably don't remember enough detail to find it.

    FYI, I found the link I was looking for at http://www.sqlservercentral.com/Forums/FindPost629308.aspx

    Of course, if you're using IE and you manage to find the post, the code windows are gonna be pretty tough on you. 😛

    I'm curious... what exactly is the problem? I just recently started trying out FireFox (mainly because of Gail's mention of the Clippings Add-On a few hundred posts back on THE THREAD here), but I copied text out of code windows for a long time with IE. I didn't notice any problems....

    Wayne
    Microsoft Certified Master: SQL Server 2008
    Author - SQL Server T-SQL Recipes


    If you can't explain to another person how the code that you're copying from the internet works, then DON'T USE IT on a production system! After all, you will be the one supporting it!
    Links:
    For better assistance in answering your questions
    Performance Problems
    Common date/time routines
    Understanding and Using APPLY Part 1 & Part 2

  • Heh... Ok... Remember... you asked.:-)

    Here's why... the original code looks like this (for example)....

    [font="Courier New"]--===== Create and populate the Tally table on the fly

     SELECT TOP 1000000 --equates to more than 30 years of dates

            IDENTITY(INT,1,1AS N

       INTO dbo.Tally

       FROM Master.dbo.SysColumns sc1,

            Master.dbo.SysColumns sc2

    --===== Add a Primary Key to maximize performance

      ALTER TABLE dbo.Tally

        ADD CONSTRAINT PK_Tally_N 

            PRIMARY KEY CLUSTERED (NWITH FILLFACTOR = 100

    --===== Allow the general public to use it

      GRANT SELECT ON dbo.Tally TO PUBLIC[/font]

    If I throw that code into a code window in the presence of IE, the code in the code window looses the blank lines. Like this....

    [font="Courier New"]--===== Create and populate the Tally table on the fly

     SELECT TOP 1000000 --equates to more than 30 years of dates

            IDENTITY(INT,1,1AS N

       INTO dbo.Tally

       FROM Master.dbo.SysColumns sc1,

            Master.dbo.SysColumns sc2

    --===== Add a Primary Key to maximize performance

      ALTER TABLE dbo.Tally

        ADD CONSTRAINT PK_Tally_N 

            PRIMARY KEY CLUSTERED (NWITH FILLFACTOR = 100

    --===== Allow the general public to use it

      GRANT SELECT ON dbo.Tally TO PUBLIC[/font]

    If I copy that from the code window and paste it directly into SSMS, it ends up looking like this... notice that all leading spaces have been eliminated and the code has been double spaced in many areas...

    [font="Courier New"]--===== Create and populate the Tally table on the fly[p]  [/p]SELECT TOP 1000000 --equates to more than 30 years of dates[p]  [/p]IDENTITY(INT,1,1) AS N[p]  [/p]INTO dbo.Tally[p]  [/p]FROM Master.dbo.SysColumns sc1,

    [p]  [/p]Master.dbo.SysColumns sc2

    --===== Add a Primary Key to maximize performance

    [p]  [/p]ALTER TABLE dbo.Tally

    [p]  [/p]ADD CONSTRAINT PK_Tally_N

    [p]  [/p]PRIMARY KEY CLUSTERED (N) WITH FILLFACTOR = 100

    --===== Allow the general public to use it

    [p]  [/p]GRANT SELECT ON dbo.Tally TO PUBLIC

    [/font]

    The thing that's really an itch is that if I can demonstrate how to do it correctly in a normal window, why can't they make it work in a code window? 😛

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)

  • Paul White (6/20/2009)


    Jeff Moden (6/20/2009)


    It would be really helpful if several other IE users started throwing rocks at this annoying problem.

    Hey Jeff,

    So yeah - I'm game - at whom should we throw rocks?

    BTW I just fired up IE8 (version 8.0.6001.18702 it says) and the code windows look about the same as they do in Chrome 2. Are we talking about the code="sql" embedded stuff or something else? What are the major problems that you see?

    Cheers,

    Paul

    See my previous post just above this one, Paul. Those who should go into the rock catching business would probably be Phil Factor, Tony Davis, and Steve Jones. 😛

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)

  • WayneS (6/20/2009)


    Jeff Moden (6/20/2009)


    WayneS (6/20/2009)


    Jeff Moden (6/17/2009)


    Ummmm.... my rule of thumb is to peel one potato at a time on the quirky update...

    Hey Jeff, I remember reading a post where you loaded in a massive file in microseconds (astonishing all others that were working on the problem)... do you happen to have a link to that thread so I can review it again?

    Thanks,

    Heh... it wasn't quite that effective but I remember the post. I don't have a link saved anywhere, though. Sorry. I'll take a quick look for it but I probably don't remember enough detail to find it.

    FYI, I found the link I was looking for at http://www.sqlservercentral.com/Forums/FindPost629308.aspx

    Oh yeah... now I remember. One column needed to be split (a portion isolated, really) from the middle. Instead of trying to do it in a single query, I did the ol' "Divide'n'Conquer" thing using a derived table to do the first part of the split and did the rest of the split in the outer query. I did it unconsciously because I learned a long time ago that the sum of the code is frequently less than the individual parts. The calculation of "interim answers" through the use of derived tables frequently abbreviates the duration of the code. I believe that someone recently wrote an article about this same phenomena...

    ... that's all "geekinese" for "peel one potato at a time". 😛

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)

  • Jeff Moden (6/20/2009)


    Heh... Ok... Remember... you asked.:-)

    Here's why... the original code looks like this (for example)....

    [font="Courier New"]--===== Create and populate the Tally table on the fly

     SELECT TOP 1000000 --equates to more than 30 years of dates

            IDENTITY(INT,1,1AS N

       INTO dbo.Tally

       FROM Master.dbo.SysColumns sc1,

            Master.dbo.SysColumns sc2

    --===== Add a Primary Key to maximize performance

      ALTER TABLE dbo.Tally

        ADD CONSTRAINT PK_Tally_N 

            PRIMARY KEY CLUSTERED (NWITH FILLFACTOR = 100

    --===== Allow the general public to use it

      GRANT SELECT ON dbo.Tally TO PUBLIC[/font]

    If I throw that code into a code window in the presence of IE, the code in the code window looses the blank lines. Like this....

    [font="Courier New"]--===== Create and populate the Tally table on the fly

     SELECT TOP 1000000 --equates to more than 30 years of dates

            IDENTITY(INT,1,1AS N

       INTO dbo.Tally

       FROM Master.dbo.SysColumns sc1,

            Master.dbo.SysColumns sc2

    --===== Add a Primary Key to maximize performance

      ALTER TABLE dbo.Tally

        ADD CONSTRAINT PK_Tally_N 

            PRIMARY KEY CLUSTERED (NWITH FILLFACTOR = 100

    --===== Allow the general public to use it

      GRANT SELECT ON dbo.Tally TO PUBLIC[/font]

    Hi Jeff

    I just tried with IE8. Copied your code from IE to SSMS, from SSMS to SQL Prettifier and back to "Reply" Textbox:

    [font="Courier New"]--===== Create and populate the Tally table on the fly

    SELECT TOP 1000000 --equates to more than 30 years of dates

            IDENTITY(INT,1,1) AS N

       INTO dbo.Tally

       FROM MASTER.dbo.SysColumns sc1,

            MASTER.dbo.SysColumns sc2

    --===== Add a Primary Key to maximize performance

      ALTER TABLE dbo.Tally

        ADD CONSTRAINT PK_Tally_N

            PRIMARY KEY CLUSTERED (N) WITH FILLFACTOR = 100

    --===== Allow the general public to use it

      GRANT SELECT ON dbo.Tally TO PUBLIC

    [/font]

    :ermm:

    Do you use any clipboard manager tool?

    Flo

  • Jeff Moden (6/20/2009)


    Oh yeah... now I remember. One column needed to be split (a portion isolated, really) from the middle.

    Fascinating thread. I just spent the last couple of hours reading every post from the discussion of "Cursors Be Gone!" - very entertaining.

    The only thing that bothers me really is the name of the method. "Quirky Update" just doesn't float my boat for reasons I struggle to explain, and "pseudo-cursor" just asks for the cursor-zealots to say 'aha!' so it isn't really set-based at all then! Sigh.

    I have spent far too much time on this site this weekend 🙂 It's all good.

    Paul

  • Florian Reischl (6/21/2009)


    Do you use any clipboard manager tool?

    No and that's a major part of my point... if you copy and paste into SSMS from the good code example I posted in the text window, you don't need all that stuff. If I can do it, why can't they? In this case, I'm thinking that "can't" simply means "won't". 😉 It's a very, very simple replacement of leading spaces with hard spaces and the use of the paragraph code for blank lines. What's worse is that the old code windows, with the exception of the occasional appearance of a smiley face, used to work almost perfectly... certainly better than they do now with IE.

    What ever happened to the good ol' WYSIWYG days? 😛

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)

  • Paul White (6/21/2009)


    Jeff Moden (6/20/2009)


    Oh yeah... now I remember. One column needed to be split (a portion isolated, really) from the middle.

    Fascinating thread. I just spent the last couple of hours reading every post from the discussion of "Cursors Be Gone!" - very entertaining.

    The only thing that bothers me really is the name of the method. "Quirky Update" just doesn't float my boat for reasons I struggle to explain, and "pseudo-cursor" just asks for the cursor-zealots to say 'aha!' so it isn't really set-based at all then! Sigh.

    I have spent far too much time on this site this weekend 🙂 It's all good.

    Paul

    Heh... you need a better hobby. 😛 (Me too! Look who's replying :hehe:)

    I agree... the word "Quirky" leaves a lot to be desired... I prefer the term Pseudo-Cursor (first heard the term from Barry... I used to call them "set based loops") especially because the cursor-zealots like to argue about it and especially because they usually don't have a clue as to what "set based" actually means. The article I wrote on triangular joins is because of such zealots (and even some non-zealots) claiming that cursors are better than set-based for "certain things". Heh... in fact, now that I think about it, most of my articles are aimed squarely at the heads of cursor-zealots... 😀

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)

  • Jeez... here's something I absolutely hate to see...

    http://www.sqlservercentral.com/Forums/Topic738870-361-1.aspx

    I suppose it's because people just don't know enough about databases to know better than to think they can just jump in and write one to support some new application for a client. Once again, the perception of an OP is that a database is just a place to dump data. At least this one knows what an FK is... maybe.

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)

  • Jeff Moden (6/21/2009)


    Florian Reischl (6/21/2009)


    Do you use any clipboard manager tool?

    No and that's a major part of my point... if you copy and paste into SSMS from the good code example I posted in the text window, you don't need all that stuff.

    Thanks for your reply! I was blind and you made me seeing... :pinch:

    I misunderstood your previous sample. Now I can reproduce this problem.

    If I can do it, why can't they?

    Because I use a browser ... erm ... Firefox ... erm ... oups... 😀

    In this case, I'm thinking that "can't" simply means "won't". 😉 It's a very, very simple replacement of leading spaces with hard spaces and the use of the paragraph code for blank lines. What's worse is that the old code windows, with the exception of the occasional appearance of a smiley face, used to work almost perfectly... certainly better than they do now with IE.

    I'm with you, there are also some real security issues with HTML like this:

    Blah

    Or just think about all those problems with XML in many posts. This should be fixed also - maybe in same release as your code window problem 😛

    What ever happened to the good ol' WYSIWYG days? 😛

    This would be a really great thing!

  • Florian Reischl (6/21/2009)


    I'm with you, there are also some real security issues with HTML like this:

    Heh... ok... that might be useful for some of the things I'd like to do... how did you do that?

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)

Viewing 15 posts - 5,896 through 5,910 (of 66,712 total)

You must be logged in to reply to this topic. Login to reply