mirror of
https://github.com/MewoLab/AquaDX.git
synced 2026-02-07 02:37:26 +08:00
[allnet] Fix Keychip sql migration on MariaDB/MySQL
This commit is contained in:
@@ -1,23 +1,27 @@
|
||||
package icu.samnyan.aqua.sega.allnet.model;
|
||||
|
||||
import javax.persistence.*;
|
||||
import java.io.Serializable;
|
||||
|
||||
import javax.persistence.Entity;
|
||||
import javax.persistence.Id;
|
||||
import javax.persistence.Table;
|
||||
import javax.persistence.UniqueConstraint;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
@Entity(name = "Keychip")
|
||||
@Table(name = "allnet_keychips", uniqueConstraints = {@UniqueConstraint(columnNames = {"keychip_id"})})
|
||||
@Data
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
public class Keychip implements Serializable {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
public class Keychip {
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.SEQUENCE)
|
||||
@Column(name = "id", nullable = false)
|
||||
private Long id;
|
||||
private long id;
|
||||
|
||||
private String keychip_id;
|
||||
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(Long id) {
|
||||
this.id = id;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,8 +1,5 @@
|
||||
create table allnet_keychips
|
||||
CREATE TABLE allnet_keychips
|
||||
(
|
||||
id int(20) primary key AUTOINCREMENT not null,
|
||||
keychip_id varchar(255) not null
|
||||
)
|
||||
ENGINE = InnoDB
|
||||
DEFAULT CHARSET = utf8mb4
|
||||
collate = utf8mb4_unicode_ci;
|
||||
id BIGINT auto_increment PRIMARY KEY,
|
||||
keychip_id VARCHAR(255) NOT NULL
|
||||
);
|
||||
|
||||
@@ -1,8 +1,5 @@
|
||||
create table allnet_keychips
|
||||
CREATE TABLE allnet_keychips
|
||||
(
|
||||
id int(20) primary key AUTOINCREMENT not null,
|
||||
keychip_id varchar(255) not null
|
||||
)
|
||||
ENGINE = InnoDB
|
||||
DEFAULT CHARSET = utf8mb4
|
||||
collate = utf8mb4_unicode_ci;
|
||||
id BIGINT auto_increment PRIMARY KEY,
|
||||
keychip_id VARCHAR(255) NOT NULL
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user