Tag: 多对多

如何使用eBean和Kotlin来表示带有额外字段的连接表?

我正在从规范作者/ book多对多关系示例向book_author表添加字段“角色”: create table author ( id bigint auto_increment not null, name varchar(255), constraint pk_author primary key (id) ); create table book ( id bigint auto_increment not null, title varchar(255), constraint pk_book primary key (id) ); create table book_author ( book_id bigint not null, author_id bigint not null, role varchar(255), constraint pk_book_author primary key (book_id,author_id) […]