The dotted table

  • Comments posted to this topic are about the item The dotted table

  • Nice question.

    But your "not necessarily recommended" is a bit less emphatic than my expression would be if I encountered something like this in a code review. :rolleyes:

    Tom

  • Nice simple question, valid it may be but certainly not to be recommended. Thanks Steve.

    ...

  • This was removed by the editor as SPAM

  • TomThomson (11/23/2015)


    Nice question.

    But your "not necessarily recommended" is a bit less emphatic than my expression would be if I encountered something like this in a code review. :rolleyes:

    +1

    😎

    Certainly drop the code most probably something else along with it........

  • Easy one, thanks.

    Need an answer? No, you need a question
    My blog at https://sqlkover.com.
    MCSE Business Intelligence - Microsoft Data Platform MVP

  • Yes valid, but definitely not recommended, I hope that MS will prevent this code from being created by mistake in future releases.

    Thanks & Best Regards,
    Hany Helmy
    SQL Server Database Consultant

  • According to Chambers Dictionary, the definition of "wrong" includes:

    "not appropriate or suitable"

    "not good or sensible; unjustifiable"

    "amiss, causing trouble, pain, etc"

    "not socially acceptable"

    I think you could make a case for the "dotted table" being wrong on all these counts!

  • The correct answer is missing: "The table doesn't have a primary key". It's also suspect that all columns are nullable.

    From the answer options I deduced that I needed to focus on the table name only; perhaps you can change the question text to reflect that?


    Hugo Kornelis, SQL Server/Data Platform MVP (2006-2016)
    Visit my SQL Server blog: https://sqlserverfast.com/blog/
    SQL Server Execution Plan Reference: https://sqlserverfast.com/epr/

  • I have to agree with Tom. It may be valid, but is certainly not recommended and it would never survive a review.

  • I tried creating a #table and it didn't like the periods.

  • Iwas Bornready (11/24/2015)


    I tried creating a #table and it didn't like the periods.

    The # needs to be inside the brackets

    CREATE TABLE [#this.is.a.test]

  • Maybe "What's wrong with this table?" should be change to something like "What's wrong with the syntax of this statement to create a table"?

    Luis C.
    General Disclaimer:
    Are you seriously taking the advice and code from someone from the internet without testing it? Do you at least understand it? Or can it easily kill your server?

    How to post data/code on a forum to get the best help: Option 1 / Option 2
  • The following will also work

    CREATE TABLE [.[[.[[.[[.]].]].]].]]]

    ( myid INT

    , mychar VARCHAR(200)

    );

    or

    CREATE TABLE [[[[[[[]]]]]]]]]

    ( myid INT

    , mychar VARCHAR(200)

    );

    or

    CREATE TABLE [You Are Fired!]

    ( myid INT

    , mychar VARCHAR(200)

    );

  • martin.whitton (11/24/2015)


    According to Chambers Dictionary, the definition of "wrong" includes:

    "not appropriate or suitable"

    "not good or sensible; unjustifiable"

    "amiss, causing trouble, pain, etc"

    "not socially acceptable"

    I think you could make a case for the "dotted table" being wrong on all these counts!

    +1

    Don Simpson



    I'm not sure about Heisenberg.

Viewing 15 posts - 1 through 15 (of 29 total)

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