itgle.com

单选题What type of constraint can be used to ensure that, in any given row in a table, the value of one column never exceeds the value of another column?()A CheckB RangeC ReferentialD Informational

题目
单选题
What type of constraint can be used to ensure that, in any given row in a table, the value of one column never exceeds the value of another column?()
A

Check

B

Range

C

Referential

D

Informational


相似考题
参考答案和解析
正确答案: D
解析: 暂无解析
更多“单选题What type of constraint can be used to ensure that, in any given row in a table, the value of one column never exceeds the value of another column?()A CheckB RangeC ReferentialD Informational”相关问题
  • 第1题:

    Which of the following can be used to ensure that once a row has been inserted in table TABLEX, the column MAINID in that row cannot be updated?()

    A.Define the column MAINID as NOT UPDATABLE

    B.Define the column MAINID as a PRIMARY KEY

    C.Define the column MAINID as a FOREIGN KEY

    D.Define an UPDATE trigger on table TABLEX


    参考答案:D

  • 第2题:

    Which of the following constraint types can be used to ensure the value of an INTEGER column references only positive values?()

    • A、Unique
    • B、Check
    • C、Referential
    • D、Informational

    正确答案:B

  • 第3题:

    Which of the following scenarios will ensure that the value of the NEXT_STEPNO column in a given row of table TABLEX exists as a value of column STEPNO (usually in another row) in the same table?()

    • A、Define a UNIQUE constraint on the columns NEXT_STEPNO and STEPNO.
    • B、Define a CHECK constraint on the NEXT_STEPNO column (NEXT_STEPNO = STEPNO).
    • C、Define column STEPNO as the primary key of TABLEX and column NEXT_STEPNO as a foreign key referencing column STEPNO of the same table.
    • D、Define column NEXT_STEPNO as the primary key of TABLEX and column STEPNO as a foreign key referencing column NEXT_STEPNO in the same table.

    正确答案:C

  • 第4题:

    What type of constraint is used to ensure that each row inserted into the EMPLOYEE table with a value in the WORKDEPT column has a row with a corresponding value in the DEPTNO column of the DEPARTMENT table?()

    • A、A check constraint on the EMPLOYEE table
    • B、A unique constraint on the EMPLOYEE table WORKDEPT column
    • C、A foreign key reference from the DEPARTMENT tables DEPTNO column to the WORKDEPT column of the EMPLOYEE table
    • D、A foreign key reference from the EMPLOYEE tables WORKDEPT column to the DEPTNO column of the DEPARTMENT table

    正确答案:D

  • 第5题:

    The EMPLOYEES table has these columns: LAST NAME VARCHAR2(35) SALARY NUMBER(8,2) HIRE_DATE DATE Management wants to add a default value to the SALARY column. You plan to alter the table by using this SQL statement: ALTER TABLE EMPLOYEES MODIFY ( SALARY DEFAULT 5000); What is true about your ALTER statement?()

    • A、Column definitions cannot be altered to add DEFAULT values.
    • B、A change to the DEFAULT value affects only subsequent insertions to the table.
    • C、Column definitions cannot be altered at add DEFAULT values for columns with a NUMBER data type.
    • D、All the rows that have a NULL value for the SALARY column will be updated with the value 5000.

    正确答案:B

  • 第6题:

    Which three statements are true regarding the data types in Oracle Database 10g/11g?()

    • A、Only one LONG column can be used per table 
    • B、A TIMESTAMP data type column stores only time values with fractional seconds 
    • C、The BLOB data type column is used to store binary data in an operating system file 
    • D、The minimum column width that can be specified for a VARCHAR2 data type column is one 
    • E、The value for a CHAR data type column is blank-padded to the maximum defined column width

    正确答案:A,D,E

  • 第7题:

    You are modifying a table named Product in a SQL Server 2005 database. You want to add a new column named FriendlyName to the Product table. A friendly name for each product will be stored in this column. The table currently contains data. The sales department has not yet created a friendly name for each product. FriendlyName is a required value for each product. You want to add this new column by using the least amount of effort. What should you do?()

    • A、Define the new column as NULL.Update the FriendlyName column to the same value as the productName column. Alter the FriendlyName column to be NOT NULL.
    • B、Define the new column as NOT NULL with a default value of ’Undefined.’
    • C、Define the new column as NULL. Use application logic to enforce the data constraint.
    • D、Define the new column as NULL with a default value of ’Undefined.’

    正确答案:B

  • 第8题:

    单选题
    Which of the following scenarios will ensure that the value of the NEXT_STEPNO column in a given row of table TABLEX exists as a value of column STEPNO (usually in another row) in the same table?()
    A

    Define a UNIQUE constraint on the columns NEXT_STEPNO and STEPNO.

    B

    Define a CHECK constraint on the NEXT_STEPNO column (NEXT_STEPNO = STEPNO).

    C

    Define column STEPNO as the primary key of TABLEX and column NEXT_STEPNO as a foreign key referencing column STEPNO of the same table.

    D

    Define column NEXT_STEPNO as the primary key of TABLEX and column STEPNO as a foreign key referencing column NEXT_STEPNO in the same table.


    正确答案: A
    解析: 暂无解析

  • 第9题:

    多选题
    Which three statements are true regarding the data types in Oracle Database 10g/11g?()
    A

    Only one LONG column can be used per table

    B

    A TIMESTAMP data type column stores only time values with fractional seconds

    C

    The BLOB data type column is used to store binary data in an operating system file

    D

    The minimum column width that can be specified for a VARCHAR2 data type column is one

    E

    The value for a CHAR data type column is blank-padded to the maximum defined column width


    正确答案: C,E
    解析: 暂无解析

  • 第10题:

    单选题
    You are modifying a table named Product in a SQL Server 2005 database. You want to add a new column named FriendlyName to the Product table. A friendly name for each product will be stored in this column. The table currently contains data. The sales department has not yet created a friendly name for each product. FriendlyName is a required value for each product. You want to add this new column by using the least amount of effort. What should you do?()
    A

    Define the new column as NULL.Update the FriendlyName column to the same value as the productName column. Alter the FriendlyName column to be NOT NULL.

    B

    Define the new column as NOT NULL with a default value of ’Undefined.’

    C

    Define the new column as NULL. Use application logic to enforce the data constraint.

    D

    Define the new column as NULL with a default value of ’Undefined.’


    正确答案: D
    解析: 暂无解析

  • 第11题:

    单选题
    What type of constraint is used to ensure that each row inserted into the EMPLOYEE table with a value in the WORKDEPT column has a row with a corresponding value in the DEPTNO column of the DEPARTMENT table?()
    A

    A check constraint on the EMPLOYEE table

    B

    A unique constraint on the EMPLOYEE table WORKDEPT column

    C

    A foreign key reference from the DEPARTMENT tables DEPTNO column to the WORKDEPT column of the EMPLOYEE table

    D

    A foreign key reference from the EMPLOYEE tables WORKDEPT column to the DEPTNO column of the DEPARTMENT table


    正确答案: C
    解析: 暂无解析

  • 第12题:

    单选题
    You are a database administrator for your company. The company uses a SQL Server 2005 database that includes a table named Inventory. The table contains a column named Price. A company policy states that the value in the Price column cannot be decreased by more than 10 percent in any single database operation. Updates to the Price column are made by various means, including by using ad hoc queries. You need to ensure that this company policy is enforced. What should you do?()
    A

    Create a trigger that rolls back changes to the Price column that violate company policy.

    B

    Create a stored procedure that disallows changes to the Price column that violate company policy.

    C

    On the Price column, create a check constraint that requires a specified minimum value.

    D

    On the Price column, create a foreign key constraint to a table that contains valid prices.


    正确答案: A
    解析: 暂无解析

  • 第13题:

    What type of constraint can be used to ensure that, in any given row in a table, the value of one column never exceeds the value of another column?()

    A.Check

    B.Range

    C.Referential

    D.Informational


    参考答案:A

  • 第14题:

    What type of constraint can be used to ensure that, in any given row in a table, the value of one column never exceeds the value of another column?()

    • A、Check
    • B、Range
    • C、Referential
    • D、Informational

    正确答案:A

  • 第15题:

    You are a database administrator for your company. The company uses a SQL Server 2005 database that includes a table named Inventory. The table contains a column named Price. A company policy states that the value in the Price column cannot be decreased by more than 10 percent in any single database operation. Updates to the Price column are made by various means, including by using ad hoc queries. You need to ensure that this company policy is enforced. What should you do?()

    • A、Create a trigger that rolls back changes to the Price column that violate company policy.
    • B、Create a stored procedure that disallows changes to the Price column that violate company policy.
    • C、On the Price column, create a check constraint that requires a specified minimum value.
    • D、On the Price column, create a foreign key constraint to a table that contains valid prices.

    正确答案:A

  • 第16题:

    Which of the following can be used to ensure that once a row has been inserted in table TABLEX, the column MAINID in that row cannot be updated?()

    • A、Define the column MAINID as NOT UPDATABLE
    • B、Define the column MAINID as a PRIMARY KEY
    • C、Define the column MAINID as a FOREIGN KEY
    • D、Define an UPDATE trigger on table TABLEX

    正确答案:D

  • 第17题:

    Which two are true about aggregate functions? ()

    • A、You can use aggregate functions in any clause of a SELECT statement.
    • B、You can use aggregate functions only in the column list of the select clause and in the WHERE clause of a SELECT statement.
    • C、You can mix single row columns with aggregate functions in the column list of a SELECT statement by grouping on the single row columns.
    • D、You can pass column names, expressions, constants, or functions as parameter to an aggregate function.
    • E、You can use aggregate functions on a table, only by grouping the whole table as one single group.
    • F、You cannot group the rows of a table by more than one column while using aggregate functions.

    正确答案:A,D

  • 第18题:

    You are responsible for managing the database schema for an order entry application in a SQL Server 2005 database. After a design review, a member of the development staff asks you to add a new column named CommissionRate to the Product table. Because the actual commission rates for all products are not known at this time, each product has a default commission rate of 12 percent. The rate can be modified as necessary. You add the new column. You need to configure the table to assign the default value as efficiently as possible. What should you do?()

    • A、 Create an INSERT trigger to assign the default value to each item in the table. 
    • B、 Create a CHECK constraint to validate the data and to assign the default value to each item in the table. 
    • C、 Create an UPDATE trigger to update the default value for each new item in the table. 
    • D、 Create a DEFAULT constraint to assign the default value specifying the WITH VALUES argument.

    正确答案:D

  • 第19题:

    Which two statements are true regarding single row functions?()

    • A、They accept only a single argument 
    • B、They can be nested only to two levels 
    • C、Arguments can only be column values or constants 
    • D、They always return a single result row for every row of a queried table 
    • E、They can return a data type value different from the one that is referenced

    正确答案:D,E

  • 第20题:

    单选题
    Which of the following constraint types can be used to ensure the value of an INTEGER column references only positive values?()
    A

    Unique

    B

    Check

    C

    Referential

    D

    Informational


    正确答案: C
    解析: 暂无解析

  • 第21题:

    单选题
    You are responsible for managing the database schema for an order entry application in a SQL Server 2005 database. After a design review, a member of the development staff asks you to add a new column named CommissionRate to the Product table. Because the actual commission rates for all products are not known at this time, each product has a default commission rate of 12 percent. The rate can be modified as necessary. You add the new column. You need to configure the table to assign the default value as efficiently as possible. What should you do?()
    A

     Create an INSERT trigger to assign the default value to each item in the table. 

    B

     Create a CHECK constraint to validate the data and to assign the default value to each item in the table. 

    C

     Create an UPDATE trigger to update the default value for each new item in the table. 

    D

     Create a DEFAULT constraint to assign the default value specifying the WITH VALUES argument.


    正确答案: D
    解析: 暂无解析

  • 第22题:

    单选题
    Which of the following can be used to ensure that once a row has been inserted in table TABLEX, the column MAINID in that row cannot be updated?()
    A

    Define the column MAINID as NOT UPDATABLE

    B

    Define the column MAINID as a PRIMARY KEY

    C

    Define the column MAINID as a FOREIGN KEY

    D

    Define an UPDATE trigger on table TABLEX


    正确答案: D
    解析: 暂无解析

  • 第23题:

    多选题
    Which two statements are true regarding single row functions?()
    A

    They accept only a single argument

    B

    They can be nested only to two levels

    C

    Arguments can only be column values or constants

    D

    They always return a single result row for every row of a queried table

    E

    They can return a data type value different from the one that is referenced


    正确答案: E,B
    解析: 暂无解析