Machine-translated by Google. Questions are authored in English.
Top

Discussion

Which of the following do you need to consider when you make a table in SQL?

  • A.Data types
  • B.Primary keys
  • C.Default values
  • D.
    All of the above.

Answer: D

Correct answer: All of the above.

All three are part of defining a table, and each answers a different question.

Data types fix what may be stored in a column and how much space it takes. Primary keys identify each row uniquely and are what foreign keys elsewhere refer to. Default values decide what a column holds when an INSERT does not mention it, which is how a column can be NOT NULL without every statement supplying it. Constraints and indexes belong to the same design decision.

No comment is present. Be the first to comment.
Loading…

Post your comment

Please log in or register to post a comment.