informatica convertion issue from timestamp to date (DD-MON-YY) - informatica-powercenter

I have one issue while converting from TIMESTAMP(17-SEP-15 02.00.00.000000 PM) format to DATE(DD-MON-YY) format in a informatica Mapping.
It works fine when I use the ODBC driver connection. But when we use ORACLE data direct connection it gives the ERROR.
Are there any solutions?

Try using DATE(DD-MON-RR), I think this should work.

Related

How to use parameters with Oracle JDBC?

I am using Oracles JDBC driver for 11g. And I want to establish the connection using the parameter defaultRowPrefetch=10000. When I try to call the connection URL, I get the following error:
Error trying to connect to 'jdbc:oracle:thin:#atukwos57:1521/LIVE;defaultRowPrefetch=10000':Invalid connection string format, a valid format is: "host:port:sid"
I cant find any examples. Am I using it wrong? Leaving out the parameter establishes the connection.
Try this one
jdbc:oracle:thin:#atukwos57:1521/LIVE?defaultRowPrefetch=10000
Syntax
jdbc:oracle:thin:#[[protocol:]//]
host1[,host12,host13][:port1][,host2:port2]/service_name[:server][/instance_name]
[?[parameter-name1=parameter-value1][&parameter-name2=parameter-value2],...]
There is a file called oracle.jdbc\defaultConnectionProperties.properties in the jar-file. Adding oracle.jdbc.defaultRowPrefetch=10000 to this file solved the issue.

How to set useUnicode=yes& characterEncoding=UTF-8 in DBCPConnectionPool for Oracle in NIFI?

I am using DBCPConnectionPool in order to create a connection and extract data from Oracle DB. But data results were extracted with wrong font. I guess it's due to not set UTF-8 in connection string.
I found a example when set DBCPConnectionPool for MySQL with utf-8:
Database Connection URL is set as below:
jdbc:mysql://localhost:3306/?useUnicode=yes&characterEncoding=UTF-8.
But I am not sure how does look like for Oracle.
Could you please help me give any solution? Thanks.
This page might be helpful to understand the intricacies of Unicode support in Oracle. To convert ASCII to UTF-8 in NiFi, use the ConvertCharacterSet processor.

Selecting LOB using Database Link (OCI) in Postgres

I have a database link set up to connect to an Oracle 11gR2 database from a Postgres 9.1 server. This uses OCI for the connection.
However, when I try to select any CLOB data I receive the following error:
ERROR: OCI error: ORA-01406: fetched column value was truncated
Is there anything that can be changed in the OCI to allow this to work correctly?
I am noticing that a lot of db's have trouble connecting to text fields in PostgreSQL. Is there a reason it has to be CLOB? Can you wrap in a function that would read the whole field?
My guess is that Oracle uses a streaming interface for CLOBs similar to the LOB postgresql interface but without the escaping. As a result PostgreSQL isnt really sure what to do with the value when it comes over.

SSMA (SQL Server Migration Assistant) for Oracle cannot find datatypes

I am trying to migrate my Oracle db to SqlServer 2008 using SSMA. I defined some type mappings for columns. When I synchronize after converting schema it gives errors like: "Cannot find datatype datetime" or bit. These datatypes are valid SQL Server datatypes.
Why I am getting these errors?
Just a guess, but it's quite hard to provide more than that before you give more details... (the code being synchronized to SQL Server, first of all).
Do you have case-sensitive collation on your SQL Server? I believe SSMA may have problems in this case. Try synchronizing to case-insensitive DB.
Also you may try running generated SQL Server (translated) code in the Management Studio and then find the problem with generated SQL or DB setup from that point. Again, it's most likely possible to figure out the problem solely by looking at your generated SQL if it's indeed corrupted due to some bug in SSMA.

What causes a JDBC Type 91 error?

I have a web app hosted on BEA Weblogic 10.x with an Oracle 10g database backend.
It works perfectly with one database, but when we make a clone of it and try to use a different WebLogic and Oracle instance we are getting this error:
ERROR - Problem initializing invocation tracking - disabling
tracking xxxxclass.BadTableMappingException: Database column
xxxxPeriodEnding in database yyyyyyy, table zzzzzzz has an
unknown type: JDBC Type 91.
We get it every time we do a query that involves a column of type DATE. There was no ORA-XXXX code in the message.
I can access the database using SQL*Plus using the same access and do selects and updates on the same tables with no errors.
The answer to this question is not just a simple description of what a type 91 error is (although that will help) but what could be causing this given the circumstances described above.
I am using ojdbc14.jar for JDBC on both instances of weblogic.
I have no idea about the error, but have you considered the jdbc jar version and more importantly if the oracle DB needs to be updated.
I faced very weird problems with oracle, and struggled for a while to find at the end that installing some patches for oracle would solve the problem.
Set oracle.jdbc.V8Compatible=true.
This remaps the oracle DATE type to a DATETIME time in JDBC. This parameter was missing on the new Weblogic server.

Resources