Remove primary key ContributorId

`Ebook` to `Contributor` is one to many, and we don't query by ContributorId.
The table already has a SortOrder column, and we use that to order the queries.
This commit is contained in:
Mike Colagrosso 2024-10-13 21:06:08 -06:00 committed by Alex Cabal
parent 1076c9a77d
commit 3f3cf702b2
3 changed files with 4 additions and 9 deletions

View file

@ -210,7 +210,7 @@ class Ebook{
from Contributors
where EbookId = ?
and MarcRole = ?
order by ContributorId
order by SortOrder asc
', [$this->EbookId, 'aut'], Contributor::class);
}
@ -227,7 +227,7 @@ class Ebook{
from Contributors
where EbookId = ?
and MarcRole = ?
order by ContributorId
order by SortOrder asc
', [$this->EbookId, 'ill'], Contributor::class);
}
@ -244,7 +244,7 @@ class Ebook{
from Contributors
where EbookId = ?
and MarcRole = ?
order by ContributorId
order by SortOrder asc
', [$this->EbookId, 'trl'], Contributor::class);
}
@ -261,7 +261,7 @@ class Ebook{
from Contributors
where EbookId = ?
and MarcRole = ?
order by ContributorId
order by SortOrder asc
', [$this->EbookId, 'ctb'], Contributor::class);
}