Which two statements are true regarding tables? (Choose two.)
A.
A table name can be of any length.
B.
A table can have any number of columns.
C.
A column that has a DEFAULT value cannot store null values.
D.
A table and a view can have the same name in the same schema.
E.
A table and a synonym can have the same name in the same schema.
F.
The same table name can be used in different schemas in the same database.
Explanation:
Synonyms
Synonyms are database objects that enable you to call a table by another name. You can create synonyms to
give an alternative name to a table.
You may have upto 1,000 columns in a table these days.
If you have more than 255 – they will be stored in multiple row pieces (like a chained row – the first 255 point to the next 255 point to the next 255 and so on)
C + F
a synonym and a table in the same schema can’t have the same name (ORA-01471 or ORA-00955)
Ups ignore that I missread C … it can store null values so C is false.
Hmm … then I’m not sure which beside F is correct.
Public synonyms can have the same name as a table but they are not in the same schema are they?
For Option E.
”
You can have:
Table and Public Synonym with the same name
Public Synonym and Private Synonym with the same name
But can not have:
Table and Private Synonym with the same name inside the same schema
The first thing to note is that Public Synonyms are non-schema objects, while Private Synonyms and Tables are. Another is that the uniqueness of database objects’ names are defined by the namespace. As it is stated in SQL Expert Study Guide:
USER, ROLE, and PUBLIC SYNONYM objects are in their own collective namespace.
TABLE, VIEW, SEQUENCE, PRIVATE SYNONYM, and user-defined TYPE objects have their own unique namespace within a given schema.
INDEX objects have their own namespace within a given schema.
CONSTRAINT objects have their own namespace within a given schema.
So, as long as objects do not share the same namespace you can give them the same names. Hope this helps.
”
https://stackoverflow.com/questions/23192502/can-we-create-synonym-with-the-same-name-in-same-schema
D & E
As previous posts points out you can’t have the same name for table and view or two tables or two views in the same schema.
D is incorrect.
Should be E & F