keitaroemotion opened a new issue, #14505:
URL: https://github.com/apache/grails-core/issues/14505
I am now trying to make migration in Grails, and here is my domain class:
```
class SomeDomain {
String stringField
EnumClass enumField
static constraints = {
stringField nullable: true, maxSize: 100
enumField nullable: true, maxSize: 100
}
}
```
then if I auto generated diff groovy file,
It reflects the stringField's maxSize(100), but for enumField there are no
constraints reflected such that it is of maxSize(255).
### Task List
- [ ] Steps to reproduce provided
- [ ] Stacktrace (if present) provided
- [ ] Example that reproduces the problem uploaded to Github
- [ ] Full description of the issue provided (see below)
### Steps to Reproduce
1. make domain class with enum field.
2. make constraints for the enum field with maxSize: 100
3. auto generate migration file according to 2. then you see maxSize(100) is
not applied and its size is VARVHAR(255). (mySQL5.6)
### Expected Behaviour
After the migration, the fields constraints should be 100.
### Actual Behaviour
the fields constraints are size of 255
### Environment Information
- **Operating System**: Amazon linux
- **GORM Version:** TODO
- **Grails Version (if using Grails):** | Grails Version: 3.2.13
| Groovy Version: 2.4.15
| JVM Version: 1.8.0_272
openjdk version "1.8.0_272"
OpenJDK Runtime Environment (build 1.8.0_272-b10)
OpenJDK 64-Bit Server VM (build 25.272-b10, mixed mode)
### Example Application
- TODO: link to github repository with example that reproduces the issue
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]