Before You Begin
This 15-minute tutorial shows you how to load data from a flat file data source into a database using Oracle Analytics Cloud Data Sync.
Background
Use Oracle Analytics Cloud Data Sync to upload and manage data. You can load data from CSV and XLSX files, relational sources (tables, views, and SQL statements), Oracle Transactional Business Intelligence (OTBI), JDBC data sources, and Oracle Service Cloud. You can load to relational tables or data sets.
After loading data with Oracle Analytics Cloud Data Sync, you can then analyze the data in Oracle Analytics Cloud.
What Do You Need?
- Install and configure Oracle Analytics Cloud Data Sync version 2.5
- Install Java Development Kit (JDK) V1.8
- Access to Oracle Database Cloud Service:
- User credentials
- URL for the Oracle Database Cloud Service instance
- Java Database Connectivity (JDBC) driver address
- Download sampledatadenorm.csv to your computer
Create
Your Data Loading Project
In Oracle Analytics Cloud Data Sync, create a new project to manage your data load.
- From the Oracle Analytics Cloud Data Sync installation directory, start Oracle Analytics Cloud Data Sync using
datsync.batordatasync.sh. - In Enter Password, enter your password, click Remember password, and then click Login.
- In Welcome, click Create
a New Project, enter
My Demo Data Load,and then click OK.
Create
Your Target Connection
Specify the connection details for your target database. In this tutorial, an Oracle Database Cloud Service instance was used to perform the steps.
- Click Connections. In the Sources/Targets tab, click New.
- In New Connection, enter
OracleDBin Name. - From the Type field, select Oracle (Thin), and then click OK.
- In the Sources/Targets tab, select the OracleDB connection.
- In the Edit tab, enter the user name of your database account in User, and then enter your Password.
- In the URL field, click the check
. In the URL dialog box, enter the URL for your database instance, and then click OK. Your URL should look similar to the following:
jdbc:oracle:thin:@HOST_NAME:1521/SERVICE_NAME. - In the JDBC Driver field, click the check
. In the JDBC dialog box, enter the JDBC driver address for your database instance,
and then click OK.Your URL should look similar to the following:
oracle.jdbc.driver.OracleDriver. - On the Edit tab, click Test Connection.
- In Connection Successful, click OK. In the Edit tab, click Save.
Configure
Your Data Load
In this section, you select the columns and rows to load to your database instance, and you name the target table.
- Click Project. On the Data Flows tab, click Data From Object(s). In Select Source, choose File source, and then click OK.
- In New Source File, on the Select File tab, click the check
in the File Location field. - Navigate to and
select the
sampledatadenorm.csvfile, and then click Next. - In Import Options, click Next.
- In Configure Target, in the
Create new field, enter
T_PRODUCTS,and then click Next. - In New Source File: Map Columns, click Select None.
- In the Load column, select the
product-related columns:
- PROD_ITEM_KEY
- PROD_BRAND
- PROD_LOB
- PROD_TYPE
- PRODUCT
- PROD__ITEM_DESC
- In the PROD_ITEM_KEY row, click Update Rows on Match, and then click OK.
Specify
a Load Strategy
Choose how you'd like to keep your target data up-to-date.
- Click the Data Flows tab. In the row containing the T_Products target object, click the check
in the Load Strategy column,
and then click Replace data in table. Click OK.
Load
Your Data
Create and run a data loading job to load your data.
- Click Jobs, and then click New.
- In New Job, enter
MyProductsin Job name, and then click Next. - In New Job, in the TARGET row, click Override With, and select OracleDB. Click Finish.
- In Configuring execution instance, click OK.
- Click Run Job. In Do you want to run the job "My Demo Data Load - MyProducts," click OK.
- In Run Job, Request successfully submitted, click OK.
Verify the Data Load Success
Monitor the data loading job to check that the data load was successful.
- From the Jobs tab, click Runs.
- Review the Run Status column until you see the value Completed.
- Click Tasks, and make sure that the Successful Rows value is 11 and the Failed Rows value is 0.
Loading
Data Using Oracle Analytics Cloud Data Sync