Hi, I am actually using the mongDB API via a tLibraryLoad component, as I find this easier to build complex multi-level documents using tJavaRow and tJava components, than using the MongoDB palette components. I am reading in data from Oracle which are date values with a zero time stamp component:
The records in mongo shell appear to be the previous day. You can see the record is inserted as the 28-JUN-2008.
"status_date" : ISODate("2008-06-28T23:00:00Z")
It is almost as if mongoDB sees a midnight date as the end of the previous day, rather than the start of the 29th June 2008. In my schema I have specified the Oracle columns as Date and DB Type of Date. I expect this is related to UTC. However I am not sure where the UTC offset is being introduced. I am running the job locally on my PC which is UTC+00 (UK). In Oracle I am storing the date as a "date" and not a "timezone with timestamp" so am not even storing the timezone in the database. All I want is the stored date to be captured in mongoDB as captured in Oracle.... Any advice appreciated. Regards Stephen
Re: Oracle to MongoDB is removing one day from dates
Is this what you require? I believe this is to do with Daylight Saving Time. MongoDB is looking at the raw time from Oracle, and then adjusting due to DST for some reason....If I change my locale settings in Windows to US, then the changes to the dates adjust as to when they kick in - in accordance with DST in the US. Talend Unified Platform feature 188.8.131.5250908_1633 org.talend.tup.feature.feature.group Talend. Regards Stephen