Ticket #392 (closed defect: fixed)

Opened 18 months ago

Last modified 12 months ago

Error while opening validator configuration file

Reported by: gleison.silva Owned by: kasper
Priority: medium Milestone:
Component: DataCleaner-core Keywords: Error open configuration file
Cc:
Influenced classes: DomHelper

Description

Hello! After saving a validator configuration file (.dcv) and try reopen that file, I'm getting the message:

An error occorred when opening the file 'my_validator.dcv'

The stack trace is:

Error opening file

Message:

java.lang.NullPointerException?

Level:

SEVERE

Stack Trace: null

dk.eobjects.datacleaner.util.DomHelper?.getAttributeValue(DomHelper?.java:69) dk.eobjects.datacleaner.util.DomHelper?.getColumnsFromChildNodes(DomHelper?.java:142) dk.eobjects.datacleaner.validator.ValidatorJobConfiguration?.deserialize(ValidatorJobConfiguration?.java:124) dk.eobjects.datacleaner.gui.windows.ValidatorWindow?.deserialize(ValidatorWindow?.java:283) dk.eobjects.datacleaner.gui.widgets.OpenFileActionListener?.actionPerformed(OpenFileActionListener?.java:65) javax.swing.AbstractButton?.fireActionPerformed(Unknown Source) javax.swing.AbstractButton?$Handler.actionPerformed(Unknown Source) javax.swing.DefaultButtonModel?.fireActionPerformed(Unknown Source) javax.swing.DefaultButtonModel?.setPressed(Unknown Source) javax.swing.AbstractButton?.doClick(Unknown Source) javax.swing.plaf.basic.BasicMenuItemUI.doClick(Unknown Source) javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(Unknown Source) java.awt.Component.processMouseEvent(Unknown Source) javax.swing.JComponent.processMouseEvent(Unknown Source) java.awt.Component.processEvent(Unknown Source) java.awt.Container.processEvent(Unknown Source) java.awt.Component.dispatchEventImpl(Unknown Source) java.awt.Container.dispatchEventImpl(Unknown Source) java.awt.Component.dispatchEvent(Unknown Source) java.awt.LightweightDispatcher?.retargetMouseEvent(Unknown Source) java.awt.LightweightDispatcher?.processMouseEvent(Unknown Source) java.awt.LightweightDispatcher?.dispatchEvent(Unknown Source) java.awt.Container.dispatchEventImpl(Unknown Source) java.awt.Window.dispatchEventImpl(Unknown Source) java.awt.Component.dispatchEvent(Unknown Source) java.awt.EventQueue?.dispatchEvent(Unknown Source) java.awt.EventDispatchThread?.pumpOneEventForFilters(Unknown Source) java.awt.EventDispatchThread?.pumpEventsForFilter(Unknown Source) java.awt.EventDispatchThread?.pumpEventsForHierarchy(Unknown Source) java.awt.EventDispatchThread?.pumpEvents(Unknown Source) java.awt.EventDispatchThread?.pumpEvents(Unknown Source) java.awt.EventDispatchThread?.run(Unknown Source)

I'm currently using Firebird database. Could this is the problem?

Tks

Gleison

Attachments

my_validator.dcv Download (981 bytes) - added by gleison.silva 18 months ago.

Change History

Changed 18 months ago by gleison.silva

comment:1 follow-up: ↓ 3 Changed 18 months ago by kasper

Hi gleison,

I've been quickly looking at this and it seems that you've encountered a bug in our job-parsing code! I will take a look at fixing this asap but in the mean time here are some suggestions for a workaround:

Try opening your database in the application and have a look at the tree structure. Find the name of the table's schema. Then open your .dcv file in a text-editor and editor the <column> tag in the bottom of the fil. Add an attribute called schema and set it to the schema's name. Like this:

<column column="YOUR_SCHEMA_NAME" table="FCCTAEXT">TIPO_CTA</column>

Then it should work ...

comment:2 Changed 18 months ago by kasper

  • Owner changed from Gleison to kasper
  • Status changed from new to assigned

comment:3 in reply to: ↑ 1 Changed 18 months ago by gleison.silva

Hi, Kasper!

Tks for reply!

I've trying change <column> tag by adding the attribute "column" and, after, "schema". With attribute "schema" the error message has changed to:

An error occorred while reading validation rule configuration: Could not resolve column 'TIPO_CTA'

Here the content for line in the configuration file:

<column schema="" table="FCCTAEXT">TIPO_CTA</column>

Maybe this is a bug only with Firebird, since this DBMS don't have the "schema" concept...

Rgs

Replying to kasper:

Hi gleison,

I've been quickly looking at this and it seems that you've encountered a bug in our job-parsing code! I will take a look at fixing this asap but in the mean time here are some suggestions for a workaround:

Try opening your database in the application and have a look at the tree structure. Find the name of the table's schema. Then open your .dcv file in a text-editor and editor the <column> tag in the bottom of the fil. Add an attribute called schema and set it to the schema's name. Like this:

<column column="YOUR_SCHEMA_NAME" table="FCCTAEXT">TIPO_CTA</column>

Then it should work ...

comment:4 Changed 18 months ago by kasper

  • Influenced classes modified (diff)

Yes this is definately because the schema-name is non-existing for Firebird ... I'll have to dive a bit deeper to see if there are any plausable workarounds. I can fix the bug easily but it'll require a new release before you can run it (unless you're capable of compiling etc. yourself)... I'll see what I can do - maybe a minor maintenance release can be done within a few days.

comment:5 Changed 18 months ago by kasper

  • Status changed from assigned to closed
  • Resolution set to fixed
  • Milestone changed from DataCleaner X.0 to DataCleaner 1.5.5

The issue is fixed in the source code now. I'll try to see if we can do a quick release but I'll have to do a quality check and see if there are any other simple issues that we should bundle with the release then.

comment:6 follow-up: ↓ 7 Changed 18 months ago by kasper

Hey Gleison,

Could you try out my latest build where I think that the bug should be fixed?

You can download it here:  http://eobjects.org/resources/tmp/dc_firebird_fix.zip

Let me know :)

comment:7 in reply to: ↑ 6 Changed 18 months ago by gleison.silva

Hi, Kasper!

It works!

Thank you for your attention and willingness to help me with this issue!

Rgs

Replying to kasper:

Hey Gleison,

Could you try out my latest build where I think that the bug should be fixed?

You can download it here:  http://eobjects.org/resources/tmp/dc_firebird_fix.zip

Let me know :)

comment:8 Changed 12 months ago by kasper

  • Milestone DataCleaner 1.5.5 deleted

Milestone DataCleaner 1.5.5 deleted

Note: See TracTickets for help on using tickets.