# RELEASE Wrong ref text field summary lookup for reference

**URL:** <https://community.datagerry.com/t/release-wrong-ref-text-field-summary-lookup-for-reference/729>\
**Category:** Report a Bug\
**Created:** [April 10, 2025, 2:11pm UTC](https://community.datagerry.com/t/release-wrong-ref-text-field-summary-lookup-for-reference/729 "2025-04-10T14:11:49Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![cmdbeval1](https://avatars.discourse-cdn.com/v4/letter/c/f14d63/32.png) [@cmdbeval1](https://community.datagerry.com/u/cmdbeval1)\
**Post date:** [April 10, 2025, 2:11pm UTC](https://community.datagerry.com/t/release-wrong-ref-text-field-summary-lookup-for-reference/729/1 "2025-04-10T14:11:49Z")

</div>

Scenario:  
Type A has a text field “name” - this field is set as visible field in “summary”  
Type B has a reference (from special controls in gui editor) to field “name” of type A

Problem:  
If I enter some text in field “name” at type A, save it and try to create a new object of type B and then select an object to be referenced of type A with certain text in field “name” the summary field is not correctly shown - i.e. other fields than the field “name” are shown.

Diagnostics:  
This only happens for certain input in field “name”.

Here is the result of my tests (left the input, right the result):  
app-study–3 NOT OK  
app-study–3- NOT OK  
app-study-A-3- NOT OK  
appstudy-A-3 NOT OK  
appstudy-A-39 NOT OK  
app-study-A-39 NOT OK  
app-study-A-A OK  
app-study-A-A1 OK  
app-study-A-A19339 OK

From the above I gather that the lookup mechanism does some regular expression matching for lookup with some hardcoded rules and trips over.

## I think the broken algorithm there is: “If the field contains a dash at the END of the name followed by at least one number - then go wrong in all other cases - do it right”

Caveat: It might be that this problem does not occur in a fresh blank new database as I had to switch between release and current dev code several times. I had no time to test this yet.

–

Please fix this quickly (if it is reproducible at your developers) as this is an elementary functionality for entering data and would lessen the value of Datagerry significantly!

---

<div class="post-metadata">

**Author:** ![abdullah-khalid](https://dub1.discourse-cdn.com/flex013/user_avatar/community.datagerry.com/abdullah-khalid/32/860_2.png) [@abdullah-khalid](https://community.datagerry.com/u/abdullah-khalid)\
**Post date:** [April 10, 2025, 3:12pm UTC](https://community.datagerry.com/t/release-wrong-ref-text-field-summary-lookup-for-reference/729/2 "2025-04-10T15:12:54Z")

</div>

Hello,

Thanks for the info. I’ve created a Jira ticket for it ( **DAT-1545** ) and will update you once the issue is resolved.

Best Regards,  
Abdullah

---

<div class="post-metadata">

**Author:** ![abdullah-khalid](https://dub1.discourse-cdn.com/flex013/user_avatar/community.datagerry.com/abdullah-khalid/32/860_2.png) [@abdullah-khalid](https://community.datagerry.com/u/abdullah-khalid)\
**Post date:** [April 11, 2025, 12:48pm UTC](https://community.datagerry.com/t/release-wrong-ref-text-field-summary-lookup-for-reference/729/3 "2025-04-11T12:48:35Z")

</div>

Hi,

The issue has been fixed — the bug is resolved in the current dev version. Thanks again for your detailed report!

Best Regards,  
Abdullah
