Added index to Observation dates.
This commit is contained in:
parent
bec332f7ab
commit
77dbe259f0
@ -40,6 +40,7 @@ enum class RatingCategory {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
|
@Table(indexes = [Index(name = "dateIndex", columnList = "date")])
|
||||||
data class Observation(
|
data class Observation(
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
@ -47,7 +48,7 @@ data class Observation(
|
|||||||
@JsonIgnore
|
@JsonIgnore
|
||||||
@ManyToOne
|
@ManyToOne
|
||||||
val site: Site,
|
val site: Site,
|
||||||
@Column(nullable = false)
|
@Column(nullable = false, name = "date")
|
||||||
val date: LocalDate,
|
val date: LocalDate,
|
||||||
@Column(nullable = false)
|
@Column(nullable = false)
|
||||||
val type: TrainingType,
|
val type: TrainingType,
|
||||||
|
Loading…
Reference in New Issue
Block a user