SQL Exception when trying to create a new column and entering text in System Element field

Description

Getting the following exception message when entering data in the Sytem Element field:
org.postgresql.util.PSQLException: ERROR: operator does not exist: character varying = numeric

Steps to reproduce.
1. Open Table and Column window and navigate to Column Tab
2. Click to add a new column and enter some text in the System Element field
The above exception is generated.

From the log, the SQL generated for the lookup is as follows:

The problem is midway down: WHERE AD_Element.EntityType=AD_EntityType.AD_EntityType_ID

After further investigation I think this might be related to

Environment

Able to reproduce on test.idempiere.org

Activity

Tony Snook 
January 5, 2022 at 12:55 AM

Thanks

Carlos Ruiz 
January 4, 2022 at 1:43 PM

Thanks

Solved with https://github.com/idempiere/idempiere/commit/57d4caa

AD_EntityType and AD_Language are always exceptional tables because of their Char pseudo-primary-key

Carlos Ruiz 
January 4, 2022 at 10:16 AM

Thanks - I’ll take a look to see what other references are affected to revert

Tony Snook 
January 4, 2022 at 9:57 AM

It appears the reference _EntityTypeNew (AD_Reference_ID=389) has the Display Column set to “AD_EntityType_ID_Entity Type”. If I change the Display Column to “EntityType_Entity Type” everything works normally.

Fixed

Details

Assignee

Reporter

Components

Fix versions

Affects versions

Priority

Created January 4, 2022 at 9:19 AM
Updated March 1, 2022 at 12:21 PM
Resolved January 4, 2022 at 1:43 PM