[ Pobierz całość w formacie PDF ]
.TABLESDefault: noneSpecifies a list of table names to import.Use an asterisk (*) to indicate alltables.When specified, this parameter initiates a table mode import, whichrestricts the import to tables and their associated objects, as listed in Table 1-1on page 1-5.The number of tables that can be specified at the same time isdependent on command line limits.Any table-level Import or partition-level Import attempts to create apartitioned table with the same partition names as the exported partitionedtable, including names of the form SYS_Pnnn.If a table with the same namealready exists, Import processing depends on the setting of the IGNOREparameter.Unless SKIP_UNUSABLE_INDEXES=Y, inserting the exported data into thetarget table fails if Import cannot update a non-partitioned index or indexpartition that is marked Indexes Unusable or otherwise not suitable.Although you can qualify table names with schema names (as inSCOTT.EMP) when exporting, you cannot do so when importing.In thefollowing example, the TABLES parameter is specified incorrectly:imp system/manager TABLES=(jones.accts, scott.emp,scott.dept)Import 2-25The valid specification to import these tables is:imp system/manager FROMUSER=jones TABLES=(accts)imp system/manager FROMUSER=scott TABLES=(emp,dept)If TOUSER is specified, SCOTT s objects are stored in the schema specified byTOUSER.If user SCOTT does not exist in the current database, his tables areimported into the importer s schema system in the previous example.Otherwise, the tables and associated objects are installed in SCOTT s schema.Additional Information: Some operating systems, such as UNIX,require that you use escape characters before special characters, such asa parenthesis, so that the character is not treated as a special character.On UNIX, use a backslash (\) as the escape character, as shown in thefollowing example:TABLES=\(EMP,DEPT\)Table Name RestrictionsTable names specified on the command line or in the parameter file cannotinclude a pound (#) sign, unless the table name is enclosed in quotationmarks.For example, if the parameter file contains the following line, Importinterprets everything on the line after EMP# as a comment.As a result, DEPTand MYDATA are not imported.TABLES=(EMP#, DEPT, MYDATA)However, if the parameter file contains the following line, the Import utilityimports all three tables:TABLES=( EMP# , DEPT, MYDATA)Attention: When you specify the table name in quotation marks, it iscase sensitive.The name must exactly match the table name stored in thedatabase.By default, database names are stored as uppercase.Additional Information: Some operating systems require single quotesinstead of double quotes.See your Oracle operating system-specificdocumentation.2-26 Oracle8 Server UtilitiesTOUSERDefault: noneSpecifies a list of usernames whose schemas will be imported.TheIMP_FULL_DATABASE role is required to use this parameter.To import to a different schema than the one that originally contained theobject, specify TOUSER.For example:imp system/manager FROMUSER=scott TOUSER=joe TABLES=empIf multiple schemas are specified, the schema names are paired.The followingexample imports SCOTT s objects into JOE s schema, and FRED s objects intoTED s schema:imp system/manager FROMUSER=scott,fred TOUSER=joe,tedUSERIDDefault: undefinedSpecifies the username/password of the user performing the import.Optionally, you can specify the @connect_string clause for Net8.See the user sguide for your Net8 protocol for the exact syntax of @connect_string.Import 2-27Using Table-Level and Partition-Level Export and ImportBoth table-level Export and partition-level Export can migrate data acrosstables and partitions.Guidelines for Using Partition-Level ImportThis section provides more detailed information about partition-level Import.For general information, see Understanding Table-Level and Partition-LevelImport on page 2-5.Partition-level Import cannot import a non-partitioned exported table.However, a partitioned table can be imported from a non-partitionedexported table using table-level Import.Partition-level Import is legal only ifthe source table (that is, the table called table-name at export time) waspartitioned and exists in the Export file." If the partition-name is not a valid partition in the export file, Importgenerates a warning." The partition-name in the clause refers to only the partition in the Exportfile, which may not contain all of the data of the entire table on the exportsource system.If ROWS = Y (default), and the table does not exist in the Import targetsystem, all of the rows for the specified partition in the table are inserted intothe same partition in the table in the Import target system.If ROWS = Y (default), but the table already existed before Import, all therows for the specified partition in the table are inserted into the table.Therows are stored according to the partitioning scheme of the target table.If thetarget table is partitioned, Import reports any rows that are rejected becausethey fall above the highest partition of the target table.If ROWS = N, Import does not insert data into the target table and continuesto process other objects associated with the specified table and partition in thefile.If the target table is non-partitioned, the partitions are imported into theentire table.Import requires IGNORE = Y to import one or more partitionsfrom the Export file into a non-partitioned table on the import target system.2-28 Oracle8 Server UtilitiesMigrating Data Across Partitions and TablesThe presence of a table-name:partition-name with the TABLES parameterresults in reading from the Export file only data rows from the specifiedsource partition.If you do not specify the partition-name, the entire table isused as source.Import issues a warning if the specified partition is not in thelist of partitions in the exported table
[ Pobierz całość w formacie PDF ]