IEC.DataManagement.ImportExport.Screens

Revision as of 23:04, 4 November 2009 by Admin (Talk | contribs)
(diff) ← Older revision | Current revision (diff) | Newer revision → (diff)

Data Management : Import/Export Feature specifications for NetBeans 7.0

Contents


Specifications Abstract

Import Data

  • Import Data from a File into a Relational Database Table
  • Import a Relational Data table into another database

Export Data

  • Export Data Table from a Relational DB into a file
  • Export Data Table from a Relational DB into another database



I. File here refers to file types like fixed width, csv (comma separated values), spreadsheets and XML file types.
II. All the features would be enabled from NetBeans IDE database explorer.



I. IMPORT FILE DATA INTO A RELATIONAL TABLE

1. Import Table Action

File:IEC.DataManagement.Uploads/ImportTableListItem.PNG
Screen Description

  1. From the NetBeans Database Explorer, right click on the Tables node of the database connection where table needs to be imported.
  2. From the options list, select Import Table... option to invoke the Import Wizard.
  3. Imported table will be later added under the tables node of this database connection when the import wizard finishes.


2. Select Source for Data Import

File:IEC.DataManagement.Uploads/Import SelectImportSource File.PNG
Screen Description

  1. Table (along with the data) can be imported either from a file source or from an existing relational database table.
  2. Select one of the available import options.
  3. Import from file option has been selected here.


3. Select File Import Source

File:IEC.DataManagement.Uploads/Import SelectDataFromFileSrcToImport.PNG
Screen Description

  1. On selecting the file import option, wizard displays file selection panel where user can browse for files that need to be imported.
  2. Multiple files can be selected for import from this panel. User can browse and click on the file(s) displayed under “Choose a file” panel and add them for import with the “Add” button provided.
  3. User can select “remote” or “web” files using “URL” input box where user can provide ftp or http links to remote files that need to be imported. “Choose a file” panel will be used only for local file selections.
  4. Panel would filter files for types that are allowed to be imported i.e. CSV, spreadsheets etc. using “Files of type” filer. (This is not shown here to be implemented yet in “Files of Type” drop box)
  5. Files selected and added will cumulatively be added into “Selected Table Source” table shown on the panel.
  6. User may choose to remove the files that were added with the help of “Remove” button provided.
  7. User may opt to import combination of supported import file types e.g CSV and XML can be imported using a common wizard flow.
  8. Wizard would iterate between steps 3 and 7 of this wizard if multiple files are selected before importing the data from the selected files.


4. Enter Details of File Table to Import

File:IEC.DataManagement.Uploads/Import EnterTableDetails.PNG
Screen Description

  1. From the list of files selected for import, wizard would select one file and allow the user to define some of the basic details that would be required to express file as a virtual database table.
  2. This panel would allow the user to insert the name of imported table. Default table name for the imported table would be same as the name of file selected.
  3. Wizard would sense the type and encoding of data contained on the file and would default the closest options on “Encoding” and “Table Type” panel.
  4. File Table types currently being planned for support are :
  • Fixed Width (.txt files with fixed columns and record sizes. Fields in this file will be separated by spaces)
  • CSV (Comma Separated Value files with fields separated by a user specified delimiter.)
  • Spreadsheets (Microsoft .xls or Star Office .ods files)
  • XML (Simple xml files clearly defining rows and columns)
  1. Wizard would make a best attempt to select all the parameters for the file being processed on this panel. User, however, would be expected to review and set the appropriate option before proceeding for the next wizard panel.


4.5 Select the Sheet (Applicable for XLS file types only)

File:IEC.DataManagement.Uploads/Import XLS1 Choose A Sheet.png
Screen Description

  1. If the file type selected is XLS, this panel is shown.
  2. This panel allows user to select appropriate sheet from the various sheets/tabs that the SpreadSheet file might have.
  3. User can select the sheet from the dropdown list and preview the same with the preview button.



5. Define MetaData for File Data Being Imported (For CSV file types only)

File:IEC.DataManagement.Uploads/Import ImportTableMetaData.PNG
Screen Description

  1. For the file being processed , wizard would prompt the user to define/identify some table metadata properties that could be used while defining the virtual table for this file.
  2. Wizard may jump few steps on this wizard based on the iterations required by the file type being processed.
  3. Wizard may present a different set of parameters to be set on this panel based on file type. Parameters shown here are applicable only for CSV type of file.
  4. “Preview of file” window would allow the user to preview file data while setting up metadata properties for the file being processed.
  5. Properties being set are explained here :
  • Default Data Type : A default JDBC datatype that will be used for all the columns while creating virtual tables from the file.
  • Default precision : Default column size for the file table being created.
  • Record delimiter : Character(s) that the file parser would use to identify between database records on a file. E.g. $$$, \n etc. Users may choose to define their own record delimiter in the properties combo box or use one of the common once pre-listed in the box. Here are the pre-listed once :
  • {CR}{LF} or {LF} : Carriage Return and Line Feed or Line feed.
  • {newline} i.e. \n
  • {semicolon} i.e. ;
  • {comma} i.e. ,
  • {tab} i.e. \tab
  • {pipe} i.e.|
  • User Defined : On selecting this, the combo box becomes editable and user can enter a delimiter of choice.
  • Field Delimiter : Characters(s) that file parser would use to identify between column data in a single record. Users may choose to define their own field delimiter in the properties combo box or use one of the common once pre-listed in the box. Here are the pre-listed once :
  • {comma} i.e. ,
  • {tab} i.e. \t
  • {semicolon} i.e. ;
  • {pipe} i.e. |
  • User Defined : On selecting this, the combo box becomes editable and user can enter a delimiter of choice.
  • Text Qualifier : Columns data (on files) enclosed within text qualifier being defined here will be read as-is, irrespective of whatever it contains. Any field or record delimiter or special characters will be ignored by parser for column data contained within “Text qualifiers”.
  • First line contains field names : This indicated to the parser if the first line of the file being parsed contains column/field names. If checked, first line fields will be treated as column names for the table being created.
  • Create data files if not exists : This option indicates if dat file for the database being created will be created if missing. This is more relevant to other products where this panel is being used.
  • Rows to skip: Indicates if mentioned no of rows from the beginning of the file need to be excluded from file table being created.
  • Max no of faults to tolerate: User can set this limit if it is required that the file parser should ignore configured no of file parsing faults while its processing the file. Defaults is set to 0 (zero).
  • Trim White spaces: Ignore while spaces from the field data being read from file.


5.1 Define MetaData for File Data Being Imported (For SpreadSheets/XLS file types only)

File:IEC.DataManagement.Uploads/Import XLS2 Table Import MetaData.png

  1. All the Properties being set are explained with the properties for CSV files.


5.2 Define MetaData for File Data Being Imported (For Fixed Width file types only)

File:IEC.DataManagement.Uploads/Import FixedWidth Table Import MetaData.png

  1. Most Properties being set are explained with the properties for CSV files.
  2. Additional Properties applicable to this file type are explained here :
  • Record Length : Total length of the fixed width record in characters
  • Field Count : Total fields in the fixed width record
  • Header Offset : ??
  • Note that the field delimiter in the fixed width file is assumed to be space between the fields.



6. Enter Column Properties

File:IEC.DataManagement.Uploads/Import EnterColumnProperties.PNG
Screen Description

  1. For the file being processed , wizard would finally attempt to define the column properties for the virtual file table.
  2. User may also use this panel as an opportunity, to change the database table properties like column names, column size, data type, whether column is a primary key or not, whether column can be null or not and default value for the column.
  3. “Preview Table Content” displays data from the file expressed as table before user could proceed to create a table.
  4. The preview panel could be refreshed to display any changes made in the “Column Definitions” with the help of embedded refresh option on the dataview panel.
  5. In case the file being imported contains bulk of data, preview can be limited to user defined no. of rows by setting up the limit of rows that could be previewed using “Page Size” box.
  6. It is important to note that the wizard would navigate back to step 3 from here if there are any more selected files pending. In such a case, wizard would keep the “Finish” option disabled and only show “Next >” option to the user. However, as in this case, there was only one file selected, the “Next >” option is disabled and user is allowed to “Finish” the wizard.


6.5 Select Fields to Import into New or Existing table

Latest Entry :: Click on this to browse step details

7. Database View of Files Imported

File:IEC.DataManagement.Uploads/Import ImportedTableView file.PNG
Screen Description

  1. On Finish of the wizard, all the files selected will be imported and added as tables under the database connection that was used to initiate import.
  2. Imported tables can be queried (as other tables in the database) from the SQL Interface from NetBeans IDE.




II. IMPORT A DATABASE TABLE FROM ANOTHER DATABASE

1. Import Table Action

File:IEC.DataManagement.Uploads/ImportTableListItem.PNG
Screen Description

  1. From the NetBeans Database Explorer, right click on the Tables node of the database connection where table needs to be imported.
  2. From the options list, select Import Table... option to invoke the Import Wizard.
  3. Imported table will be later added under the tables node of this database connection when the import wizard finishes.



2. Select Import Data Source

File:IEC.DataManagement.Uploads/Import SelectImportSource Table.PNG
Screen Description

  1. Table (along with the data) can be imported either from a file source or from an existing relational database table.
  2. Select one of the available import options.
  3. Import Data from relational database table has been selected here.



3. Select Relational Table to Import

File:IEC.DataManagement.Uploads/Import ChooseTableToImport.PNG
Screen Description

  1. This panel allows the user to select tables to import from database connections that are already listed in NetBeans database explorer.
  2. User would need to connect to the database from NetBeans before selecting a table in that database for import.
  3. On selecting one of the connection (MySQL,sakila connection selected in this case), wizard would present user with all the database schemas and tables for the selected database. User can select/change schema from the “Schema” combo box and filter the tables in the “Tables” list.
  4. User can select and add more than one table from the “Tables” list by using “Select” button.
  5. Selected tables are incrementally added under “Table Selection” table area.
  6. Selected tables can be removed from the selected list by selecting the table entry under “Table Selection” and removing it using ”Remove” button.
  7. On finish, wizard imports the selected tables to the database initiating table import.


3.5 Select Fields to Import into New or Existing table

Latest Entry :: Click on this to browse step details

4. Database View of Relational Table Imported

File:IEC.DataManagement.Uploads/Import ImportedTableView.PNG
Screen Description

  1. Imported Relational tables can be queried (as other tables in the database) from the SQL Interface from NetBeans IDE.




III. EXPORT A DATABASE TABLE INTO A FILE

1. Select Database Table to Export

File:IEC.DataManagement.Uploads/Export Select table to export.PNG
Screen Description

  1. Expand the NetBeans DB Explorer to display the table that needs to be exported.
  2. Select and Right click on the table to see the options available.
  3. From the options list, Select the “Export Table...” option to invoke the export wizard.
  4. Note that multiple tables can also be exported by selecting multiple tables from the db explorer and exercising the same option. Usecase being discussed here shown one table being exported.


2. Select Export Option

File:IEC.DataManagement.Uploads/Export SelectExportOption.PNG
Screen Description

  1. Data Table can be exported either to a file source or to an existing or new relational database table.
  2. Select one of the available export options.
  3. Export to a file option has been selected here.
  1. Panel will display a brief display about option selected on this panel.



3. Select Export File Type

File:IEC.DataManagement.Uploads/Export Select FileType To Export.PNG
Screen Description

  1. On selecting the file export option, wizard would allow the user to select the type of file to which data can be exported.
  2. Following file types would be supported for export
  3. A brief description about the type of file selected will be displayed on the panel on selection of the option from drop down list.


3.5 Select Fields to Export on File

Latest Entry :: Click on this to browse step details

4. Select File Properties for Export

File:IEC.DataManagement.Uploads/Export Define File Properties.PNG
Screen Description

  1. This panel might be differ based on selection made in step 2. The parameters shown here are relevant to selection made i.e. CSV file type.
  2. This panel would prompt the user to enter some properties that would be needed to render the exported data on files type selected in step 2.
  3. User may choose to change the file name, field and record delimiter for CSV files on this panel. For e.g. Selection made on the screen is “|” for the field delimiter and “$$$” for the record delimiter.
  4. User may also define their own field and record delimiter if available commonly used options are not suitable.
  5. On Finish, data from the table will e exported to File as selected from the wizard.


4.5 Select Data Export Properties for Export on File

Latest Entry :: Click on this to browse step details

5. Exported Data File

File:IEC.DataManagement.Uploads/Export Exported Data file.PNG
Screen Description

  1. This shown the file exported with the data from relational table.
  2. Note that the file properties (name, field and record delimiter are as selected from the wizard).




IV. EXPORT A DATABASE TABLE INTO ANOTHER DATABASE

1. Select Database Table to be Exported

File:IEC.DataManagement.Uploads/Export Select table to export.PNG
Screen Description

  1. Expand the NetBeans DB Explorer to display the table that needs to be exported.
  2. Select and Right click on the table to see the options available.
  3. From the options list, Select the “Export Table...” option to invoke the export wizard.


2. Select Export Option

File:IEC.DataManagement.Uploads/Export SelectExportOption-Table.PNG
Screen Description

  1. Data Table can be exported either to a file source or to an existing or new relational database table.
  2. Select one of the available export options.
  3. Export to a database table option has been selected here.
  4. Panel will display a brief display about option selected on this panel.



3. Select Target Database To Export The Table

File:IEC.DataManagement.Uploads/Export ChooseDBToExport.PNG
Screen Description

  1. This panel would allow the user to define target table name and properties where data will be exported.
  2. User can define the name of target export table under “Enter name of exported table”. Default name will be same as that of Relational table being exported.
  3. Under “Target database connection properties”, user can select the database connection and schema under which table has to be exported. Note that the connections shown in the connection drop down will be the connections listed in NetBeans DB explorer.
  4. Wizard would need to the user to provide admin passwd for exporting the table to the target database.
  5. User can test the connection selected with login info entered before attempting to export the table.
  6. On click of finish, table will be exported to target database.



3.5 Select Fields to Export into a New or Existing Database table

Latest Entry :: Click on this to browse step details


4. Exported Table View

File:IEC.DataManagement.Uploads/Export ExportedTableView.PNG
Screen Description

  1. Table exported in the target database can be queries using standard NetBeans SQL Interface.




Related Links

Data Management Main Page

Data Management Import/Export Feature Page

Data Management Import/Export Review Page

Not logged in. Log in, Register

By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2012, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo