command jhipster jdl ..\order\src\main\jdl\order.jdl would drop id column of tables
no error threw
Motivation for or Use Case
I try to use command jhipster jdl ..\order\src\main\jdl\order.jdl for generating liquibase. but it will create drop id changelog after modifying my jdl files. so I prefer to use jhipster jdl ..\order\src\main\jdl\order.jdl --skip-db-changelog for generating backend code and then using ./mvnw compile liquibase:diff for generating liquibase changelog, though it doesn't seem more reasonable.
Reproduce the error
generating liquibase changelog by command jhipster jdl
run the backend application and create a table
stop the backend application
modify the jdl file
regenerating by command jhipster jdl
Related issues
Suggest a Fix
JHipster Version(s)
8.7.1
JHipster configuration
To provide all information we need, you should run jhipster info in the project root folder (or workspaces root for microservices), and
copy/paste the result here.
jhipster info removes sentitive information like rememberKey, jwtSecretKey. Double check if there is any other sensitive info.
As alternative you can add a JDL wrapped in below structure
openjdk version "17.0.12" 2024-07-16 LTS
OpenJDK Runtime Environment Corretto-17.0.12.7.1 (build 17.0.12+7-LTS)
OpenJDK 64-Bit Server VM Corretto-17.0.12.7.1 (build 17.0.12+7-LTS, mixed mode, sharing)
git version 2.45.1.windows.1
node: v20.17.0
npm: 10.8.2
Docker version 27.1.1, build 6312585
JDL for the Entity configuration(s) entityName.json files generated in the .jhipster directory
JDL entity definitions
/**
* Company
*/
@ChangelogDate("20241018060451")
entity Company {
id UUID
name String
contact String
}
/**
* Order
*/
@ChangelogDate("20241018060452")
entity Order (jhi_order) {
id UUID
/**
* Parking type, 0: Street parking, 1: Gated parking
*/
parkType ParkType required
/**
* Order number
*/
orderNo String required maxlength(32)
/**
* Stall number, required when parkType=0
*/
stallNo String maxlength(32)
/**
* License plate number, format like [粤S12345] or new energy [粤S123456]
*/
licensePlate String required maxlength(8)
/**
* Order amount in cents
*/
orderAmount Long required min(1)
/**
* Multiple image files, supports jpg, jpeg and png, max 10M per file
*/
file String
/**
* Entry/exit lane code, choose between this and license plate number
*/
laneNo String maxlength(32)
/**
* Platform transaction order number, linking multiple merchant orders
*/
dealNo String maxlength(32)
/**
* Customer number
*/
customerNo String maxlength(32)
/**
* Actual amount received in cents
*/
realAmount Long min(1)
/**
* Platform service fee in cents
*/
platformFee Long min(1)
/**
* Assistance service fee in cents
*/
assistFee Long min(1)
/**
* Payment status, 0: Unpaid, 1: Payment successful, 2: Payment failed
*/
payState PayState required
/**
* Platform order number
*/
platformNo String maxlength(15)
/**
* Creation time
*/
createTime LocalDate
/**
* Entry time
*/
entryTime LocalDate
/**
* Payment time
*/
payTime LocalDate
/**
* Exit deadline
*/
exitDeadline LocalDate
/**
* Exit time
*/
exitTime LocalDate
}
/**
* Parking Lot
*/
@ChangelogDate("20241018060453")
entity ParkingLot {
id UUID
parkNo String
name String
capacity Integer
}
enum ParkType {
ROAD,
ENCLOSE
}
enum PayState {
UNPAY,
PAYED,
FAILED
}
relationship OneToMany {
/**
* Creditor company
*/
Company{company} to Order{company}
/**
* Assisting company
*/
Company{assistCompany} to Order{assistCompany}
/**
* Parking lot
*/
ParkingLot{order} to Order{parkingLot}
}
paginate Company, Order, ParkingLot with infinite-scroll
search Company, Order, ParkingLot with no
microservice Company, Order, ParkingLot with Order
clientRootFolder Company, Order, ParkingLot with Order
The information is mandatory for bug reports. This will allow us to use automated tests and genarate the broken sample using jhipster from-issue command.
Browsers and Operating System
Edition Windows 11 Pro
Version 23H2
Installed on 8/19/2024
OS build 22631.4317
Experience Windows Feature Experience Pack 1000.22700.1041.0
[x] Checking this box is mandatory (this is just to show you read everything)
Overview of the issue
jhipster jdl ..\order\src\main\jdl\order.jdl
would drop id column of tablesno error threw
Motivation for or Use Case
I try to use command
jhipster jdl ..\order\src\main\jdl\order.jdl
for generating liquibase. but it will create dropid
changelog after modifying my jdl files. so I prefer to usejhipster jdl ..\order\src\main\jdl\order.jdl --skip-db-changelog
for generating backend code and then using./mvnw compile liquibase:diff
for generating liquibase changelog, though it doesn't seem more reasonable.Reproduce the error
jhipster jdl
jhipster jdl
Related issues
Suggest a Fix
JHipster Version(s)
8.7.1
JHipster configuration
To provide all information we need, you should run
jhipster info
in the project root folder (or workspaces root for microservices), and copy/paste the result here.jhipster info
removes sentitive information like rememberKey, jwtSecretKey. Double check if there is any other sensitive info.As alternative you can add a JDL wrapped in below structure
.yo-rc.json file
Environment and Tools
openjdk version "17.0.12" 2024-07-16 LTS OpenJDK Runtime Environment Corretto-17.0.12.7.1 (build 17.0.12+7-LTS) OpenJDK 64-Bit Server VM Corretto-17.0.12.7.1 (build 17.0.12+7-LTS, mixed mode, sharing)
git version 2.45.1.windows.1
node: v20.17.0 npm: 10.8.2
Docker version 27.1.1, build 6312585
JDL for the Entity configuration(s)
entityName.json
files generated in the.jhipster
directoryJDL entity definitions
The information is mandatory for bug reports. This will allow us to use automated tests and genarate the broken sample using
jhipster from-issue
command.Browsers and Operating System
Edition Windows 11 Pro Version 23H2 Installed on 8/19/2024 OS build 22631.4317 Experience Windows Feature Experience Pack 1000.22700.1041.0