The INV_HISTORY table is created using the command: SQL>CREATE TABLE INV_HISTORY (inv_no NUMBER(3), inv_date DATE, inv_amt NUMBER(10,2)) partition by range (inv_date) interval (numtoyminterval(1,’month’)) (partition p0 values less than (to_date(’01-01-2005’,’dd-mm-yyyy’)), partition p1 values less than (to_date(’01-01-2006’,’dd-mm-yyyy’))); The following data has been inserted into the INV_HISTORY table : INV_NO INV_DATE INV_AMT 1 30-dec-2004 1000 2 30-dec-2005 2000 3 1-feb-2006 3000 4 1-mar-2006 4000 5 1-apr-2006 5000 You would like to store the data belonging to the year 2006 in a single partition and issue the command: SQL> ALTER TABLE inv_history MERGE PARTITIONS FOR(TO_DATE(’15-feb-2006’,’dd-mon-yyyy’)), FOR(TO_DATE(’15-apr-2006’)) INTO PARTITION sys_py; What would be the outcome of this command?()
在SQL Server Management Studio中,对SQL Server数据文件的维护包括()
Evaluate the SQL statement: 1 SELECT a.emp_name, a.sal, a.dept_id, b.maxsal 2 FROM employees a, 3 (SELECT dept_id, MAX(sal) maxsal 4. FROM employees 5 GROUP BY dept_id) b 6 WHERE a.dept_id = b.dept_id 7 AND a. asl < b. maxsal; What is the result of the statement? ()
You executed the following SQL statement to shrink the EMPLOYEES table segment stored in the EXAMPLE tablespace: ALTER TABLE employees SHRINK SPACE CASCADE; Which statement is correct in this scenario?()
What recommendations does the SQL Access Advisor provide for optimizing SQL queries?()
View the following SQL statements: Transaction T1 INSERT INTO hr.regions VALUES (5,’Pole’);COMMIT; Transaction T2 UPDATE hr.regions SET region_name=’Poles’ WHERE region_id = 5; COMMIT; Transaction T3 UPDATE hr.regions SET region_name=’North and South Poles’ WHERE region_id = 5; You want to back out transaction T2. Which option would you use?()
You executed the following code: SQL> CERATE TABLE COUNTRY (COUNTRY_ID CHAR(2) CONSTRAINT COUNTRY_ID_nn NOT NULL, COUNTRY_NAME VARCHAR2(20), CURRENCY_NAME VARCHAR2(20), CONSTRAINT COUNTRY_ID_PK PRIMARY KEY (COUNTRY_ID)) ORGANIZATION INDEX; Which types of tables will be created automatically?()
You received complaints about the degradation of SQL query performance. You identified top SQL queries that consume time. What would be your next step to find out recommendations about statistics collection and restructuring of the SQL statement to improve query performance?()
SQL数据库出现结构性损坏,用DBCC能部分修复,下列哪些语句会实现其要求()
You executed the following commands: SQL> ALTER SESSION SET OPTIMIZER_USE_PENDING_STATISTICS = false; SQL> EXECUTE DBMS_STATS.SET_TABLE_PREFS(’SH’, ’CUSTOMERS’, ’PUBLISH’,’false’); SQL> EXECUTE DBMS_STATS.GATHER_TABLE_STATS(’SH’, ’CUSTOMERS’); Which statement is correct regarding the above statistics collection on the SH.CUSTOMERS table in the above session?()