Thursday, 6 August 2015

What is Informatica big data edition (BDE) ?

What is Informatica big data edition BDE ?


Informatica big data edition BDE is a product from Informatica Corp that can be used like an ETL tool for working in hadoop enviroment along with traditional RDBMS tools.  Now there are lot of ETL products in the market that makes it easier to integrate with hadoop. To name a few talend, pentaho, etc. Informatica is one of the leading ETL tool vendor and Informatica power center tool is very famous as an ETL tool and has been for many years. Traditionally this tool was used to extract transform and load data to traditional databases such as oracle, sql server, netezza to name a few. With advent of hadoop for storing peta byte volumes of data, building ETL tools that can work with hadoop became more important. It requires a lot of handcoding and knowledge to work directly with hadoop and build map reduce jobs. Hadoop tools such as hive made it easier to write SQL queries on top of Hive database and convert it to map reduce jobs. Hence, lot of companies started using Hive as a data warehouse tool and storing data in hadoop just like traditional databases and writing queries on Hive. How do we now extract , transform, and load the data in Hadoop? Thats where Informatica BDE comes into picture. It is a tool that you can use for ETL or ELT on hadoop infrastructure.  Informatica BDE can run in two modes. They are native mode and hive mode. 

In the native mode, it runs as a normal powercenter but in hive mode you can push down the whole mapping logic to hive and make it run on the hadoop cluster there by using the parallelism provided by hadoop. However there are some limitation when running in hive mode but that is more because of the limitations from hive itself. For example, hive does not allow updates in older versions.  

With Informatica BDE you can do the following at a very high level :

a) Just like any ETL tool you can do extract , transform, load between tranditional rdbms or hive/hdfs source and targets.
b) Push the whole ETL logic to hadoop cluster and make use of the map reduce framework. Basically it makes building hadoop jobs easier.
c) Makes it easy to create connection to all the different sources and integrate data from those sources. 
d) It makes it easier to ingest complex files such as JSON, XML, Cobol, AVRO, Parquest , etc.


Informatica BDE uses the Informatica developer interface to build the mappings , deploy and create applications. Anyone who has used IDQ before might be familiar with the Informatica developer interface. Informatica BDE can be found in Informatica  9.6 versions onwards.


Tuesday, 14 July 2015

How to monitor Netezza performance?

 How to monitor Netezza performance?

Performance of Netezza depends on various factors such as distribution keys on the table, query performance, hardware factors such as number of spus,  data skew i.e. how the data is distributed across the spus, etc

There are different ways to check how your netezza box is performing. First you can use the netezza administration tool to see the number of queries running , queries getting queued, the performance of individual queries. If there are too many queries running then obviously it is going to slow down your server performance. If there are any bad queries pulling lot of data then obviously it will one of the culprit. Put a threshold time out for queries that users are running so that it does not run for ever.You can also check out the netezza performance portal. Provides some extra information on performance.

Data skew on netezza refers to how well the data is distributed on different spus of the netezza server. If some of the spus have more data then the others then it is going to impact the performance. Make sure the data is properly distributed by using appropriate distribution keys.

You can also use certain queries to see the performance of the netezza machine. Some of them are listed below.

To check all the queries running on the system use the below query

select * from SYSTEM..NZ_QUERY_HISTORY

To check the list of successful and all historical queries also try out the below queries:

SELECT * FROM  HIST_admin."$v_hist_successful_queries"

SELECT * FROM  HIST_admin."$v_hist_queries"

select * from   HISTDB.."$v_hist_table_access_stats"

select * from _v_qryhist

select * from _v_qrystat;




We can check distribution of data using performance portal or the netezza administration console, or the explain plan, or nz_skew dba script. 

Sunday, 14 June 2015

How to connect to amazon redshift using Informatica power center?

How to connect to  amazon redshift using Informatica power center?


You can connect to amazon redshift from the drivers available on Informatica cloud. However, if you want to connect Informatica power center 9.1 and prior version  to redshift, using Postgres odbc drivers are an option. You can use DataDirect 6.1 PostgreSQL Wire Protocol and later versions for this purpose.

Step1: Install the postgres driver and create an entry in .odbc.ini


Some of the parameters you might have to set in your odbc (.odbc.ini) connection is below: Check you driver for the complete settings:

[PostgreSQL]
Driver=/informatica/server91/ODBC6.1/lib/DWpsql25.so
Description=DataDirect 6.1 PostgreSQL Wire Protocol
Database=mydatabasename
0HostName=myreshifthost.cqa0adasda-east-1.redshift.amazonaws.comLogonID=myuser_name
Password=mypassword
PortNumber=yourportnumber
TrustStore=/export/redshift-ssl-ca-cert.pem
PacketSize=32


You can contact Informatica or read the driver documentation for the full settings.

2) Create a relational odbc connection from Informatica workflow manager as shown below: 



Wednesday, 10 June 2015

How to enforce primary key constraint in Informatica when loading to netezza?

Does netezza enforce primary key constraint?


Neteza does not enforce primary key constraint. Application that loads data to netezza has to enforce it.

How to enforce primary key constraint in Informatica when loading to netezza?


If Informatica is loading data to netezza you can enforce primary key constrain by setting the primary key constraint in the target definition of Informatica mappings. This allows it to enforce primary key constrain in the current load but does not work if there is data already in the netezza table. For example, if record1 and record2 are duplicate in the current load then Informatica detects it when loading to netezza table. However, if records2 already exists in netezza table, and you are now loading only record1 then Informatica cannot find out about record2.

In this circumtance you have to put additional logic in informatica such as a lookup or filter condition to check for existing records in netezza target table. Hope this helps!!




Monday, 8 June 2015

How to install UDF functions on Netezza?


How to install an user defined function (UDF) in netezza?


Lets says you have got hold of the UDF function from netezza and want to install it then the below steps would help. In the example below, reverse function is installed on netezza server.


How to install UDF functions on Netezza?


 In the folder where you have placed the tgz file execute the below instruction.

[netezzahost]$ gunzip reverse.tgz
[netezzahost]$ tar -xvf reverse.tar

[netezzahost]$ cd reverse

[netezzahost]$ ./install <databasename>

CREATE FUNCTION
Created udf
Done


After this step you might have to execute grant command to provide permission on the function to the users.

For example:

grant execute on reverse to <mygroup>;


Login to database and test the function:

select reverse('mydog');
 REVERSE
---------
 godmy
(1 row)

How to connect to microsoft sqlserver from Informatica using odbc driver ?

How to connect to sqlserver from Informatica using odbc driver?

Step1: set up the .odbc. ini file with the below entry. You will have to enter the proper path for your driver and information for your database.

[MYSQLSERVER]
Driver=/data/informatica/ODBC6.1/lib/DWmsss25.so
Description=DataDirect SQL Server Wire Protocol
Database=mydatabase
LogonId=mysuerid
Password=mydatabase
Address=machinename,1433
QuotedId=No
AnsiNPW=No

Step 2: set up the relational odbc connection from your workflow manager as shown in screenshot below. 

Tuesday, 12 May 2015

Connect to DB2 database using Informatica

Setting up DB2 ODBC or Native DB2 database Connection in Informatica

 There are two ways to create connection to DB2 in Informatica. First way is to use the DB2 in native mode using DB2 powerconnect module. Second way is to use odbc drivers.

To connect to DB2 in native mode, you need DB2 PowerConnect module installed on your informatica server machine.

The steps to create DB2 connection using DB2 powerconnect module is below:

1)    Create a remote DB2 database connection entry  using command:
db2 CATALOG TCPIP NODE <nodename> REMOTE <hostname_or_address> SERVER <port number>
2)    Create Catalog entries for the database in unix using command:
 db2 CATALOG DATABASE <dbname> as <dbalias> at NODE <nodename>
3)    Commands to check the database entries are below:
db2 list database directory
db2 list node directory
4)    Verify the connection to the DB2 database using command:
CONNECT TO <dbalias> USER <username> USING <password>
5)    Create a relational connection (type:DB2) with connect string as “nodename” in Informatic workflow manager (Sample below):





To connect to DB2 using odbc, you need odbc driver for db2 installed on your informatica server machine.

The steps to create DB2 connection using odbc is below:

1)    Create entry in .odbc.ini file on your Informatica server machine.

[mydb2database]
Driver=/informatica/ODBC6.1/lib/DWdb225.so
Description=DataDirect 5.2 DB2 Wire Protocol
ApplicationUsingThreads=1
ConnectionRetryCount=0
ConnectionRetryDelay=3
#Database applies to DB2 UDB only
Database=MYDB2DB
DynamicSections=200
GrantAuthid=PUBLIC
GrantExecute=1
IpAddress=101.101.701.101
LoadBalancing=0
#Location applies to OS/390 and AS/400 only
Location=
LogonID=<yourid>
 Password=<yourpasswd>
PackageOwner=
ReportCodePageConversionErrors=0
SecurityMechanism=0
TcpPort=4456
UseCurrentSchema=1
WithHold=1

2)    Create relational database connection of type odbc using the connection string created in step 1.