541 views

Description

When a date field is configured for an import from an Oracle database with JDBC, the related field is created as a Basic Date/Time field in the staging table. When this field is configured to be transformed to a Date/Time field in the target table, it gives the following error with the following stack trace:

2017-08-22 03:33:26 (089) worker.1 worker.1 SEVERE *** ERROR *** com.glide.system_import_set.ImportSetTransformerWorker
java.lang.NullPointerException
at java.util.Calendar.setTime(Calendar.java:1770)
at java.text.SimpleDateFormat.format(SimpleDateFormat.java:943)
at java.text.SimpleDateFormat.format(SimpleDateFormat.java:936)
at java.text.DateFormat.format(DateFormat.java:345)
at com.glide.db.impex.transformer.TransformEntry.getDateString(TransformEntry.java:126)
at com.glide.db.impex.transformer.TransformerField.getSourceValue(TransformerField.java:116)
at com.glide.db.impex.transformer.TransformerField.transformField(TransformerField.java:88)
at com.glide.db.impex.transformer.TransformRow.transformCurrent(TransformRow.java:100)
at com.glide.db.impex.transformer.TransformRow.transform(TransformRow.java:69)
at com.glide.db.impex.transformer.Transformer.transformBatch(Transformer.java:154)
at com.glide.db.impex.transformer.Transformer.transform(Transformer.java:79)
at com.glide.system_import_set.ImportSetTransformerImpl.transformEach(ImportSetTransformerImpl.java:239)
at com.glide.system_import_set.ImportSetTransformerImpl.transformAllMaps(ImportSetTransformerImpl.java:91)
at com.glide.system_import_set.ImportSetTransformerWorker.startWork(ImportSetTransformerWorker.java:40)
at com.glide.worker.AbstractProgressWorker.startAndWait(AbstractProgressWorker.java:116)
at com.glide.worker.ProgressWorker.startAndWait(ProgressWorker.java:52)
at com.glide.worker.BackgroundProgressJob.execute(BackgroundProgressJob.java:54)
at com.glide.schedule.JobExecutor.executeJob(JobExecutor.java:103)
at com.glide.schedule.JobExecutor.execute(JobExecutor.java:89)
at com.glide.schedule.GlideScheduleWorker.executeJob(GlideScheduleWorker.java:219)
at com.glide.schedule.GlideScheduleWorker.lambda$process$48(GlideScheduleWorker.java:161)
at com.glide.schedule.GlideScheduleWorker$$Lambda$30/3401850.run(Unknown Source)
at com.glide.worker.TransactionalWorkerThread.executeInTransaction(TransactionalWorkerThread.java:35)
at com.glide.schedule.GlideScheduleWorker.process(GlideScheduleWorker.java:161)
at com.glide.schedule.GlideScheduleWorker.run(GlideScheduleWorker.java:72)

Steps to Reproduce

 

  1. Select a table with Date format in an Oracle database.

  2. Configure this table as a data source in a ServiceNow instance.

  3. Configure a transform map from this Oracle field to a sample target table with a Date/Time field.

  4. Load data.

  5. Observe that the staging table has the Basic Date/Time attribute for that field.

  6. Run a transform against the target table and observe the error message.

  7. Change the staging table's field type to Date/time and reprocess.

    Observe that it works as expected.

 

 

Workaround

Change the staging table's field to Date/Time and run the transform again. If configured for Date/Time, it will not revert back to the Basic Date/Time attribute if the table is not deleted.


Related Problem: PRB1155952

Seen In

There is no data to report.

Fixed In

Jakarta Patch 5
Kingston

Associated Community Threads

There is no data to report.

Article Information

Last Updated:2018-04-23 17:09:55
Published:2017-09-26