PROD_ID列は、SALESテーブルの外部キーです。これはPRODUCTSテーブルを参照します。 同様に、CUST_ID列とTIME_ID列も、それぞれCUSTOMERSテーブルとTIMESテーブルを参照するSALESテーブルの外部キーです。 次のCREATETABLEコマンドを評価します。 CREATE TABLE new_sales(prod_id、I cust_id、order_date DEFAULT SYSDATE) AS SELECT I prod_id、cust_id、time_id FROMsales。 上記のコマンドに関して正しい説明はどれですか?
正解:C
The statement true regarding the CREATE TABLE command: C . The NEW_SALES table would not get created because the column names in the CREATE TABLE command and the SELECT clause do not match: The SQL command tries to create a table with columns prod_id, cust_id, and order_date, but the SELECT statement specifies columns prod_id, cust_id, and time_id. The mismatch in column names and the number of columns specified will prevent the table from being created. Incorrect options: A: It is possible to specify a DEFAULT value in the column definition when creating a table with the CREATE TABLE AS SELECT syntax. B: Not all NOT NULL constraints (or any other constraints, for that matter) are automatically passed to the new table unless explicitly stated in the CREATE TABLE statement. D: FOREIGN KEY constraints are not automatically included when creating a table using the CREATE TABLE AS SELECT syntax; they would need to be added explicitly afterwards.