fix(room): make stoptime's fkids non-unique
ajsodfijasfoiasjgifasngiuash
This commit is contained in:
parent
8925c943ab
commit
b5f2ec102d
4 changed files with 372 additions and 3 deletions
|
|
@ -22,7 +22,7 @@ import moe.lava.banksia.room.entity.VersionMetadataEntity
|
|||
import androidx.room.Database as DatabaseAnnotation
|
||||
|
||||
@DatabaseAnnotation(
|
||||
version = 5,
|
||||
version = 6,
|
||||
entities = [
|
||||
RouteEntity::class,
|
||||
ShapeEntity::class,
|
||||
|
|
|
|||
|
|
@ -13,8 +13,8 @@ import moe.lava.banksia.model.StopTime
|
|||
"StopTime",
|
||||
primaryKeys = ["tripId", "stopId"],
|
||||
indices = [
|
||||
Index("tripId", unique = true),
|
||||
Index("stopId", unique = true),
|
||||
Index("tripId", unique = false),
|
||||
Index("stopId", unique = false),
|
||||
],
|
||||
foreignKeys = [
|
||||
ForeignKey(TripEntity::class, parentColumns = ["id"], childColumns = ["tripId"], onDelete = CASCADE),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue