Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8628383
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T08:31:43+00:00 2026-06-12T08:31:43+00:00

Background We are migrating a legacy database that have the labels of fields internacionalized

  • 0

Background

We are migrating a legacy database that have the labels of fields internacionalized in the database. We still use the messages.properties for some static resouces like css classes (names). The table looks like:

ITEMS
-------------------------------------------
code           number(3)      not null PK
language_code  number(3)      not null PK
label          varchar2(90)   not null
hint           varchar2(250)  not null
help           varchar2(4000)
label_client   varchar2(90)   not null
hint_client    varchar2(250)  not null
help_client    varchar2(4000)

For the html components we just look for the item in this table, setting his label (custom TagLib), and this works well. Note that we also give the opportunity to the client modify some label (the *_client fields).

The Problem

By default, Grails will try to look in messages.properties with the suffix .label to use in the validation error message. For example (Person.name.label=name):

Property name must not be blank.

If my item in the database have the label Name of Person, in validations this will be inconsistent as the label of the input differs.

We cannot synchronize the items with the .properties because the client can change them. So the solution is to, somehow, modify the Grails validation messages to return the content of the database.

Is this possible? How can I, just for validation messages, get from the database instead of properties?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T08:31:44+00:00Added an answer on June 12, 2026 at 8:31 am

    This blog post suggests you can do it by implementing your own messageSource Spring bean and registering it in resources.groovy. It dates from 2010 but still worth a try.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Ok. Here is some background: I have created a simple APEX application that is
Background: I would like to dismiss a modalView that I have presented earlier and
Okay -- we have an interesting problem. Some background: Our main application uses Indy
I have an app that I am migrating from Ruby to JRuby (due to
I have an iOS app that I'm migrating from the very slow and clunky
I have created a data migration tool that reads data from a legacy SQL
We have an existing application using the legacy Master-Slave database with an alias to
Background: Migrating an application from ball of mud to MVC. Many classes contain HTML
Background: We're building an application that allows our customers to supply data in a
Background : I'm trying to convert some JavaScript code which uses the the Crossfilter

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.