Informatica – PowerCenter Express – Data Sync – MSSQL to MySQL ( Using MySQL JDBC Driver )
2016-12-20 17:29
573 查看
Background
A dated follow-up to our post on using Informatica – PowerCenter Express.In that post we copied data between two
MS SQL Server Instances.
In this post we will copy data from SQL Server to MySQL.
Outline
Here is a brief outline of the steps we will take:Select a Driver to use to communicate with MySQL
If Driver is not yet downloaded, please do so
Deploy Driver
Configure Informatica Client & Server with newly installed driver
Launch Informatica Desktop
Design Project
Create new project
Physical Data Object
Create Physical Data Object to Source ( MS SQL Server )
Create Physical Data Object to Source ( MySQL )
Create Mapping
Link Data Sources to ( Source and Destination )
Validate Mapping
Run Mapping
Lab
Select Driver to Connect to MySQL
We have to decide whether we want to connect to MySQL using an ODBC or JDBC Driver.We chose to go with the Vendor’s own JDBC Driver.
Download Driver
Availability
The MySQL Java/JDBC Driver is available here.![](https://danieladeniji.files.wordpress.com/2016/06/downloadconnectorj-0606pm.png?w=1314&h=290)
OS Platform
As we are installing on MS Windows, and not Unix, we chose to go with Zip file packages, as opposed to Tar, if we were on Unix.![](https://danieladeniji.files.wordpress.com/2016/06/beginyourdownload.png?w=700&h=295)
Deploy Driver
Copy Jar file to the following locations<Informatica Home>\PCExpress\externaljdbcjars
Used by Server
<Informatica Home>\PCExpress\client\externaljdbcjars
Used by Client
In our case, we copied the extracted mysql-connector-java-5.1.39-bin.jar to:
D:\Informatica\PCExpress\client\externaljdbcjars
D:\Informatica\PCExpress\externaljdbcjars
Configure Informatica Client & Server with MySQL Driver
Configure Informatica Server
Launch
From the MS Windows desktop menu, access Start \ Informatica PowerCenter Express \ Launch Informatica Administrator.Login
The default browser opens in a new tab. Our URL is http://localhost:7009/administrator/![](https://danieladeniji.files.wordpress.com/2016/06/informaticaadministratoruserauthentication.png?w=1109&h=255)
Domain Navigator
The URL for local Domains appear. That URL is http://dbdev:7009/administrator/#admin/Domain_Domain_localhost![](https://danieladeniji.files.wordpress.com/2016/06/connections-new-connection-cropped.png?w=1318&h=248)
New Connection – Choose to Create New Connection
Access the “Domain” \ “Connections” tab.And, through the “Actions” link drop down, select New \ Connection
![](https://danieladeniji.files.wordpress.com/2016/06/connections-accessmenuactionnewconnections.png?w=700&h=278)
New Connection – Select a connection type
Once New \ Connection is selected from the dropdown menu, the “New Connection” panel is displayed.![](https://danieladeniji.files.wordpress.com/2016/06/newconnection-selectaconnectiontype.png?w=700&h=377)
New Connection – Step 1 of 2
Here is our user credentials and MySQL JDBC Driver Class Name and MySQL Hostname and Port number.Username :- xferClient
Password :- Enter password
JDBC Driver Class Name :- com.mysql.jdbc.Driver
Connection String :- jdbc:mysql://DBDEV:3306
![](https://danieladeniji.files.wordpress.com/2016/06/newconnection-step1of2.png?w=700&h=494)
New Connection – Test Connection
![](https://danieladeniji.files.wordpress.com/2016/06/newconnection-connectiontestedsuccessfully.png?w=700&h=498)
New Connection – Step 2 of 2
![](https://danieladeniji.files.wordpress.com/2016/06/newconnection-step2of2.png?w=700&h=496)
Configure Informatica Developer
Launch
Let us configure Informatica Developer with our newly downloaded JDBC Driver.If the Developer has not be launched, please do so now.
Access Preferences
Access the Preferences menu by navigating the menu – Window\Preferences.![](https://danieladeniji.files.wordpress.com/2016/06/winddow-preferences.png?w=700&h=182)
Informatica \ Connections
Using the tree menu on the left panel, access Informatica \ Connections![](https://danieladeniji.files.wordpress.com/2016/06/preferences-connections-before1.png?w=700)
Add new JDBC Connection
In the Connections window, click the Add button to add a new JDBC ConnectionUsername :- xferClient
Password :- Enter password
JDBC Driver Class Name :- com.mysql.jdbc.Driver
Connection String :- jdbc:mysql://DBDEV:3306
![](https://danieladeniji.files.wordpress.com/2016/06/connectiondetails-connectiondetailscompleted.png?w=774&h=683)
Design Project
Launch Informatica Developer if not already running.Create New Project
Connect To Repository
Using the Object Explorer, select and connect to the ModelRepository.![](https://danieladeniji.files.wordpress.com/2016/06/informaticadeveloper.png?w=700&h=192)
Create New Project
Create a new project by using the menu items – File \ New \ Project![](https://danieladeniji.files.wordpress.com/2016/06/newproject.png?w=700&h=493)
Name Project
In the “New Project” window, enter the name you will like to give to the Project.And, review and change the “Repository Service” if there is one.
![](https://danieladeniji.files.wordpress.com/2016/06/createanewproject.png?w=700)
Data Object – Source
Create Data Object
Right click on the Project and select New \ Data Object![](https://danieladeniji.files.wordpress.com/2016/06/new-dataobject.png?w=700&h=493)
Select a wizard
From the “Select a wizard” window, please select “Relational Data Object”![](https://danieladeniji.files.wordpress.com/2016/06/selectawizard-relationaldataobject.png?w=700)
Relational Data Object – Select a connection
The “Relational Data Object” window appears and the user is prompted “Select a connection”![](https://danieladeniji.files.wordpress.com/2016/06/relationaldataobect-selectaconnection.png?w=700)
Relational Data Object – Choose Connection
The “Choose Connection” window appear ….![](https://danieladeniji.files.wordpress.com/2016/06/relationaldataobect-chooseconnection.png?w=700)
Relational Data Object – Specify RDO Name
Specify the name of the Relational Data Object.![](https://danieladeniji.files.wordpress.com/2016/06/relationaldataobect-selectaresource-isnextstep.png?w=700)
Relational Data Object – Select a Resource – Initial
By the “Resource” item, select the Browse button.Here is the initial contents of the “Select a Resource” window.
![](https://danieladeniji.files.wordpress.com/2016/06/relationaldataobect-selectaresource-initialscreen.png?w=700)
Relational Data Object – Select a Resource – Avail all Schemas
Uncheck the “Show Default Schema Only” checkbox.Unchecking the “Show Default Schema Only” button, reveals all database objects.
![](https://danieladeniji.files.wordpress.com/2016/06/relationaldataobect-selectaresource-ongoing.png?w=700)
Relational Data Object – Select a Resource – Object Selected
Our object, Admin.ErrorLog, is selected below.![](https://danieladeniji.files.wordpress.com/2016/06/relationaldataobect-selectaresource-ongoing2.png?w=700)
Relational Data Object – New Relational Data Object – Form Filled Out
Here is what things look like once our choices are all filled out.![](https://danieladeniji.files.wordpress.com/2016/06/relationaldataobect-createarelationaldataobject.png?w=700)
Relational Data Object – Overview
Here is the Overview screen.It shows the columns and corresponding datatype of those columns.
![](https://danieladeniji.files.wordpress.com/2016/06/relationaldataobect-postcreation.png?w=700&h=492)
Data Object – Destination
Choose To Create New Physical Data Object
Use the menu item to initiate creation of a new Physical Data Object.![](https://danieladeniji.files.wordpress.com/2016/06/newphysicaldataobject-menu-20160628-1122am.png?w=700&h=243)
Relational Data Object – Select a connection
We are back at the initial contents of the “New Relational Data Object” screen.We are being prompted to choose a connection
![](https://danieladeniji.files.wordpress.com/2016/06/relationaldataobject-selectaconnection.png?w=700)
Relational Data Object – Choose Connection
Aforementioned, we will like to use JDBC to connect to our target data source.And, so we will choose the MySQL Data Source that we created earlier.
The name of that Data Source is DBDEVPlatform32JDBC.
![](https://danieladeniji.files.wordpress.com/2016/06/relationaldataobject-chooseconnection.png?w=561&h=542)
Relational Data Object – Select a resource
With our data source connected, we will go on to select a Resource, the specific Data Object that will be processing on the Target.![](https://danieladeniji.files.wordpress.com/2016/06/relationaldataobject-selectaresource.png?w=700)
Please click the Browse button to review the list of objects available on the target.
Relational Data Object – Select a resource – Initial
Upon the “Select a Resource” window appearing, the resources listed will like be limited![](https://danieladeniji.files.wordpress.com/2016/06/selectaresource-showdefaultschemaonly.png?w=700)
Relational Data Object – Select a resource – “Show Default Schema Only” Unchecked
Once we uncheck “Show Default Schema Only“, we are able to see a fuller list of schemas and objects.![](https://danieladeniji.files.wordpress.com/2016/06/selectaresource-showdefaultschemaonly-unchecked-upon.png?w=700)
Relational Data Object – Select a resource – Resource Chosen
We choose the dblab.errorlog table that we created earlier.![](https://danieladeniji.files.wordpress.com/2016/06/selectaresource-showdefaultschemaonly-unchecked.png?w=700)
Relational Data Object – Completed
Please review the chosen connections, resource, and change the name of the RDO to afford specificality.![](https://danieladeniji.files.wordpress.com/2016/06/relationaldataobject-completed.png?w=700)
Mapping
Initiate New Mapping
Please initiate New Mapping by clicking on the menu items ( New \ Mapping )![](https://danieladeniji.files.wordpress.com/2016/06/1232pm-newmapping-menu.png?w=700)
Specify New Mapping’s Name
Specify a name that allows us to identify which objects are being mappedBefore
![](https://danieladeniji.files.wordpress.com/2016/06/1232pm-mapping-createamapping-initial.png?w=700)
After
![](https://danieladeniji.files.wordpress.com/2016/06/1232pm-mapping-createamapping-after.png?w=700)
Mapping Canvas
Empty CanvasHere is our new empty canvas.
![](https://danieladeniji.files.wordpress.com/2016/06/mapping-canvas-empty.png?w=1051&h=386)
Add Source
Drag the source data object ( ErrorLog#Source ) from underneath Physical Data Objects\<Database>\<Object> to the canvas.
As this is our source, we will detail that our access will be “Read“.
![](https://danieladeniji.files.wordpress.com/2016/06/addtomapping-read.png?w=700)
Add Destination
Drag the destination data object ( ErrorLog#Destination ) from underneath Physical Data Objects\<Database>\<Object> to the canvas.
As we are now working on the destination, we will specify that our access type is for “Write“.
![](https://danieladeniji.files.wordpress.com/2016/06/addtomapping-read.png?w=700)
Mapping – Relational Data Objects
Here are the RDO Objects once the are dropped on the canvas.
![](https://danieladeniji.files.wordpress.com/2016/06/relationaldataobjects-beforelinking.png?w=700&h=343)
Mapping – Relational Data Object – Initiate Menu
Select the Source Object and right click on it’s menu bar to get an insight of options available for that object.
![](https://danieladeniji.files.wordpress.com/2016/06/relationaldataobjects-menu-appear1.png?w=700&h=302)
Please select “Auto Link”.
Mapping – Auto Link
Mapping – AutoLink – Initial
![](https://danieladeniji.files.wordpress.com/2016/06/autolink-20160628-1241pm.png?w=700&h=466)
In the screenshot above, we have only selected the Source Object and so the “OK” and “Apply” buttons are disabled.
Mapping – AutoLink – Select Source & Destination
Please select the Source and Destination objects
![](https://danieladeniji.files.wordpress.com/2016/06/autolink-20160628-1244pm.png?w=700&h=468)
And, click OK or Apply to effect the changes.
Mapping – Validation
Mapping – Validation – InitiationPlease right click on the empty canvas and select the Validate option from the drop-down menu.
![](https://danieladeniji.files.wordpress.com/2016/06/mappings-validate-cropped.png?w=700&h=503)
Mapping – Validation – Completion
If no problems are found, we are told so.
![](https://danieladeniji.files.wordpress.com/2016/06/mappings-validate-noproblemsfound.png?w=700)
Mapping – Validation – Completion
Mapping – Run Mapping
Right click on the canvas, and chose to “Run Mapping”![](https://danieladeniji.files.wordpress.com/2016/06/mappinginitiate-20160628-0105pm.png?w=700)
Mapping Running
![](https://danieladeniji.files.wordpress.com/2016/06/runmapping.png?w=700)
Errors
There are some errors to be on the lookout for:Maximum Number of rows for a 24-hour period
It is possible that you might experience the error pasted below:Mapping run completed with errors.
[MPSVCCMN_10082] The Mapping Service Module [MappingService] could not run the mapping due to the following error: [[DS_10192]
The Integration Service processed the maximum number of rows for a 24-hour period. Wait until the row limit resets at [2016-06-28 00:00:00.000].].
As we are running the Express, Informatica Developer for PowerCenter Express, edition and it is free and licensed for Development purpose, it is not suitable for large datasets.
References
cData Software
JDBC Data Sources
Create Informatica Mappings From/To a JDBC Data Source for CassandraLink
Create Informatica Mappings From/To a JDBC Data Source for Marketo
Link
相关文章推荐
- mysql数据库允许远程访问
- MySQL创建用户与授权方法
- mysql的存储过程
- 启动mysql配置文件的启动方式
- Mysql创建索引
- mysql触发器+权限管理+备份还原
- mysql悲观锁总结和实践
- mysql乐观锁总结和实践
- 学习小记-Flask Web (2) 尝试用MySQL代替SQLite
- mysql字符串转数字---备忘录
- 设计Mysql索引的原则
- 防火墙规则,指定ip访问mysql数据库3306端口
- mysql无法插入中文以及查询无法显示中文
- mysql登陆测试hydra方式
- (转)MySQL Group Replication介绍
- windows修改mysql字符集,支持ios emoji标签
- mysql - 数据库、表 的创建
- windows下如何在一台机器上安装两个MYSQL数据库
- Mysql触发器简单使用
- mysql经纬度定位