Problem with Date format in oracOCI
Moderators: chulett, rschirm, roy
-
- Premium Member
- Posts: 1255
- Joined: Wed Feb 02, 2005 11:54 am
- Location: United States of America
Try running the job only for 5 records. And can you please look at the data using sqlplus and post the input and output fields. And what are the datatypes, lengths and scales of these date fields in the target OCI stage as well in the target table. That would help.
Anything that won't sell, I don't want to invent. Its sale is proof of utility, and utility is success.
Author: Thomas A. Edison 1847-1931, American Inventor, Entrepreneur, Founder of GE
Author: Thomas A. Edison 1847-1931, American Inventor, Entrepreneur, Founder of GE
What does this mean? Why "cannot view", what happens when you click View Data?sheema wrote:i have updated it with a space as below
OCONV(ICONV(Date,"D/MDY[2,2,4]"),"D-YMD[4,2,2]"):" 00:00:00".
But it not solve my problem,the data is getting loaded but i cannot view the data through oraOCI stage.
Please verify that you are using generated sql and the field in question is wrapped in a TO_DATE() function with the mask I specified earlier.
-craig
"You can never have too many knives" -- Logan Nine Fingers
"You can never have too many knives" -- Logan Nine Fingers
The source data which i am getting is of datatype Varchar(10) and it is in the format mm/dd/yy.
I am converting it in transformer using
OCONV(ICONV(Date,"D/MDY[2,2,4]"),"D-YMD[4,2,2]"):" 00:00:00"
Then i have datatype of the date fields in the oraOCI set to Timestamp(19).
The date datatype in the target oracle table is Date.The date fields are getting stored in the target table as DD-MON-YY.
I am converting it in transformer using
OCONV(ICONV(Date,"D/MDY[2,2,4]"),"D-YMD[4,2,2]"):" 00:00:00"
Then i have datatype of the date fields in the oraOCI set to Timestamp(19).
The date datatype in the target oracle table is Date.The date fields are getting stored in the target table as DD-MON-YY.
-
- Premium Member
- Posts: 1255
- Joined: Wed Feb 02, 2005 11:54 am
- Location: United States of America
If your source data has the year in a two digit format.sheema wrote:The source data which i am getting is of datatype Varchar(10) and it is in the format mm/dd/yy.
I am converting it in transformer using
OCONV(ICONV(Date,"D/MDY[2,2,4]"),"D-YMD[4,2,2]"):" 00:00:00"
Then you can't use
Code: Select all
OCONV(ICONV(Date,"D/MDY[2,2,4]"),"D-YMD[4,2,2]"):" 00:00:00"
Code: Select all
OCONV(ICONV(Date,"D/MDY[2,2,2]"),"D-YMD[4,2,2]"):" 00:00:00"
HTH,
Whale.
Last edited by I_Server_Whale on Fri Jan 26, 2007 12:23 pm, edited 1 time in total.
Anything that won't sell, I don't want to invent. Its sale is proof of utility, and utility is success.
Author: Thomas A. Edison 1847-1931, American Inventor, Entrepreneur, Founder of GE
Author: Thomas A. Edison 1847-1931, American Inventor, Entrepreneur, Founder of GE
So, in other words you've got absolutely no problem. Dates are stored in Oracle in internal format, not in any particular flavor of ''MM' or 'DD' or 'YYYY'. You can select them and get them back out in any format under the sun, hence my Toad comment earlier.sheema wrote:The source data which i am getting is of datatype Varchar(10) and it is in the format mm/dd/yy.
I am converting it in transformer using
OCONV(ICONV(Date,"D/MDY[2,2,4]"),"D-YMD[4,2,2]"):" 00:00:00"
Then i have datatype of the date fields in the oraOCI set to Timestamp(19).
The date datatype in the target oracle table is Date.The date fields are getting stored in the target table as DD-MON-YY.
-craig
"You can never have too many knives" -- Logan Nine Fingers
"You can never have too many knives" -- Logan Nine Fingers
Post the SQL so we can see what is actually being generated.sheema wrote:The sql is Generated SQL and it has To_Date().
I am getting the error when i click view data
ocixyz: ORA-01821: date format not recognized
ocixyz.DSLink1: DSP.Open GCI $DSP.Open error -100.
-craig
"You can never have too many knives" -- Logan Nine Fingers
"You can never have too many knives" -- Logan Nine Fingers
-
- Premium Member
- Posts: 1255
- Joined: Wed Feb 02, 2005 11:54 am
- Location: United States of America
And that problem could be your sql. So post it.chulett wrote:Post the SQL so we can see what is actually being generated.
Last edited by I_Server_Whale on Fri Jan 26, 2007 12:30 pm, edited 1 time in total.
Anything that won't sell, I don't want to invent. Its sale is proof of utility, and utility is success.
Author: Thomas A. Edison 1847-1931, American Inventor, Entrepreneur, Founder of GE
Author: Thomas A. Edison 1847-1931, American Inventor, Entrepreneur, Founder of GE
I was thinking of a different patch. Let us know what you find out.
eSupport wrote:Description:
Oracle OCI stage (ORAOCI9) incorrectly binds the lookup column values to the SQL statement which is being executed. This results in the Oracle database error "ORA-1008: Not all variables bound" [ECASE 73423].
Also included in this patch is a fix for the SQL Builder in the Oracle OCI stage, which incorrectly converted a "WHERE" clause to a "HAVING" clause [ECASE 74270].
-craig
"You can never have too many knives" -- Logan Nine Fingers
"You can never have too many knives" -- Logan Nine Fingers