Are the posted questions getting worse?

  • Brandie Tarvin wrote:

    So, I could use some help on this one: To Drop or Not to Drop (the temp table question) – SQLServerCentral Forums

    I've tried Googling it but not finding exactly what this person is talking about.

    Someone told you that these temp table drops are expensive (in database terms), but without providing evidence, and now they're expecting you just to believe them?

    The burden of proof in this case is on them, not you.


  • On that subject, I always leave the DROP TABLE IF EXISTS code in the proc but commented out.  That way I don't have to add it back in when I need to do multiple reruns while troubleshooting.

    I've also been known to drop Temp Tables if they're big, I'm done with their content, and the proc isn't finished, yet, just to free up RAM for other people during my sometimes long winded processes.

    --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)

  • Phil: Someone told you that these temp table drops are expensive (in database terms), but without providing evidence, and now they're expecting you just to believe them?

    The burden of proof in this case is on them, not you.

    Me: Not an option. I'm outranked by this person. That's why I'm trying to find the information.

    Brandie Tarvin, MCITP Database AdministratorLiveJournal Blog: http://brandietarvin.livejournal.com/[/url]On LinkedIn!, Google+, and Twitter.Freelance Writer: ShadowrunLatchkeys: Nevermore, Latchkeys: The Bootleg War, and Latchkeys: Roscoes in the Night are now available on Nook and Kindle.

  • Brandie Tarvin wrote:

    Not an option. I'm outranked by this person. That's why I'm trying to find the information.

    Wouldn't someone who "outranks" you want to teach you the why along with the what? I realise I know nothing about the environment, but I would hope that if a senior DBA/Developer tells me to do something a certain way because of "X", and I ask them if they can provide me with further information on that "X" they'd be happy to, as it aid my learning and I can also then better impart that knowledge onto other employees too. Otherwise we just end up in an environment like "Put NOLOCK after every table, as it doesn't lock the table and it's faster". >_<

    Thom~

    Excuse my typos and sometimes awful grammar. My fingers work faster than my brain does.
    Larnu.uk

  • That question is further proof that ChatGPT has been trained by people that don't have the correct knowledge in such matters.  (and yes... I'm trying to soften my tone, lately, but, I have to tell you, it actually caused me physical pain to word things so nicely).

    It apparently cannot make the distinction between "temp tables" and "temporary tables".  It's seriously incorrect for what most of us refer to as "temp tables" and seriously correct for "real" "Temporary Tables".

    --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 wrote:

    It apparently cannot make the distinction between "temp tables" and "temporary tables".  It's seriously incorrect for what most of us refer to as "temp tables" and seriously correct for "real" "Temporary Tables".

    Hmm.. not sure what you're referring to with "temp tables", so I'm obviously not "most people". 🙂

    Is it a temperature table? A temperamental table? A temptation table? I'm honestly wondering...

    In the context of SQL Server, I personally think most people would indeed think of "temp tables" as a lazy short-hand for "temporary tables".

  • kaj wrote:

    Jeff Moden wrote:

    It apparently cannot make the distinction between "temp tables" and "temporary tables".  It's seriously incorrect for what most of us refer to as "temp tables" and seriously correct for "real" "Temporary Tables".

    Hmm.. not sure what you're referring to with "temp tables", so I'm obviously not "most people". 🙂

    Is it a temperature table? A temperamental table? A temptation table? I'm honestly wondering...

    In the context of SQL Server, I personally think most people would indeed think of "temp tables" as a lazy short-hand for "temporary tables".

    Totally true and we (including you) usually mean something created in TempDB whose hame starts with a "#"..  ChatGTP didn't consider it as "Temporary table objects that live in TempDB that start with  # sign".  It was apparently thinking of a "Table created in any database that is a real table and won't automatically be dropped at the end of the session or procedure run".

    --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 wrote:

    kaj wrote:

    Jeff Moden wrote:

    It apparently cannot make the distinction between "temp tables" and "temporary tables".  It's seriously incorrect for what most of us refer to as "temp tables" and seriously correct for "real" "Temporary Tables".

    Hmm.. not sure what you're referring to with "temp tables", so I'm obviously not "most people". 🙂

    Is it a temperature table? A temperamental table? A temptation table? I'm honestly wondering...

    In the context of SQL Server, I personally think most people would indeed think of "temp tables" as a lazy short-hand for "temporary tables".

    Totally true and we (including you) usually mean something created in TempDB whose hame starts with a "#"..  ChatGTP didn't consider it as "Temporary table objects that live in TempDB that start with  # sign".  It was apparently thinking of a "Table created in any database that is a real table and won't automatically be dropped at the end of the session or procedure run".

    Yes, and I now see your wisdom. 🙂

    I think I got stuck on the sentence "It can't make the distinction between "temp tables" and "temporary tables", which didn't make much sense to me at the time.

  • Don't get me started in WITH (NOLOCK). Apparently there are a number of people suddenly making that recommendation to get rid of blocking.

    It's apparently easier advice to give people than details on how to actually fix their code.

    Brandie Tarvin, MCITP Database AdministratorLiveJournal Blog: http://brandietarvin.livejournal.com/[/url]On LinkedIn!, Google+, and Twitter.Freelance Writer: ShadowrunLatchkeys: Nevermore, Latchkeys: The Bootleg War, and Latchkeys: Roscoes in the Night are now available on Nook and Kindle.

  • Worse than that, it apparently knows what is meant by "temp" table but still couldn't tie it together in the previous question.  Or, if it did, it's seriously incorrect.  Here's the question I just asked it.

    The really odd part is, I'm NOT actually seriously disappointed.  In fact, I actually expected such answers.  The reason why is that there are so many people who have labelled themselves as "expert" that answered such questions (and more) in a similar manner. For proof of that, hang around StackOverflow and other such forums for a while and read some of the articles and blogs and 'tubes so many "experts" have made.  Don't plan on being able to post a response on most of those articles and blogs to help them see the light, either.  Comments are usually disabled or just not supported by whatever engine they're using to support their articles and blogs.

    What I AM disappointed in is all the rave reviews it's getting and all the claims that it's very quickly going to supplant the need for people that have studied the art that other people are asking questions about.  IMHO, it's currently in a dangerous state where it comes out with seriously incorrect answers while "demonstrating" that it's "correct" by the additional rhetoric it provides.  It sounds like most people do on linked in that talk about politics, Covid, and a bunch of other subjects that they're highly opinionated about but actually have no qualifications. 😀  I can see it now... "Well, it's not just my opinion here... look what ChatGPT says". {headddesk}{headddesk}{headddesk}.

    Like my Pappy used to tell me... "Half of all the written is wrong and the other half is written in such a manner that you can't tell".  ChatGPT is the latter point in that statement but in spades. and that makes it dangerous.

    Heh... I DO congratulate them, though.  I've never actually seen a fully automated bullshit grinder before. 😀 😀 😀

     

    --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)

  • And, I hit the "first post on the next page" problem with that so posting another so that it'll actually be visible.

    --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)

  • And now we're just waiting for Google's Bard chatbot to go to GA. Time will tell who is the more truthful chatterbox.

    But Bard will probably not do any better, since it will be based even more on online content.

  • kaj wrote:

    And now we're just waiting for Google's Bard chatbot to go to GA. Time will tell who is the more truthful chatterbox.

    But Bard will probably not do any better, since it will be based even more on online content.

    Indeed.  I just hope neither one does too much damage.  I don't believe my hope will be realized, though.

    --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)

  • I read something about temp tables just a while back. I only vaguely remember the article, but I had thought about testing the premise about not dropping temp tables at the end of procedures. It just seems good practice to drop at the end what you create at the beginning of a procedure.

    I just wish I could remember where I read it.

     

  • kaj wrote:

    Jeff Moden wrote:

    kaj wrote:

    Jeff Moden wrote:

    It apparently cannot make the distinction between "temp tables" and "temporary tables".  It's seriously incorrect for what most of us refer to as "temp tables" and seriously correct for "real" "Temporary Tables".

    Hmm.. not sure what you're referring to with "temp tables", so I'm obviously not "most people". 🙂

    Is it a temperature table? A temperamental table? A temptation table? I'm honestly wondering...

    In the context of SQL Server, I personally think most people would indeed think of "temp tables" as a lazy short-hand for "temporary tables".

    Totally true and we (including you) usually mean something created in TempDB whose hame starts with a "#"..  ChatGTP didn't consider it as "Temporary table objects that live in TempDB that start with  # sign".  It was apparently thinking of a "Table created in any database that is a real table and won't automatically be dropped at the end of the session or procedure run".

    Yes, and I now see your wisdom. 🙂 I think I got stuck on the sentence "It can't make the distinction between "temp tables" and "temporary tables", which didn't make much sense to me at the time.

    BTW... we had a similar bit of confusion in real life at work.  They wanted to create some "temporary logging tables" by run for a kind of complex system they developed.  They original started out by creating them as tables with date included in the name but they had them all in the "dbo" schema.  Not fun to look at in the Object Explorer.  There was also great confusion between "Temp" tables (the kind in TempDB with a # sign) and the "temporary" tables they were actually talking about.

    To solve both of those issues, we started calling those table "scratch" tables and made a separate schema for them to get them out of the way in the Object Explorer (which also made using a filter easier, to boot).  I checked with everyone and they all agreed that they weren't needed after 7 days so I created a proc that would add a "To_Be_Deleted" prefix to those scratch tables 7 days after their last "modified" date and then those are simply dropped after 7 days.

    To date, no one has ever needed to rename or use even one of the "To_Be_Deleted" tables and so we're now considering just doing the auto-drop after 7 days without the rename thing.

    --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 - 66,121 through 66,135 (of 66,815 total)

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