Skip to content

Commit

Permalink
Merge pull request #334 from EBI-Metagenomics/hotfix/webuploader-ena-…
Browse files Browse the repository at this point in the history
…db-views-query-fix

Hotfix/webuploader ena db views query fix
  • Loading branch information
mberacochea authored Nov 1, 2023
2 parents cbae783 + aa052b6 commit 3e33442
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions emgena/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -194,12 +194,20 @@ class Meta:

class RunStudy(StudyAbstract):
class Meta(StudyAbstract.Meta):
db_table = 'V_MGP_RUN_STUDY'
# ERA needs to be appended as the default connection tries to use
# the PUBLIC SYNONYM (according to ENA) and it's not working ATM
# we were advised to prefix the views and this is the simplest way.
# The short-term plan is to remove the dependency of ENA databases
db_table = 'ERA\".\"V_MGP_RUN_STUDY'


class AssemblyStudy(StudyAbstract):
class Meta(StudyAbstract.Meta):
db_table = 'V_MGP_ASSEMBLY_STUDY'
# ERA needs to be appended as the default connection tries to use
# the PUBLIC SYNONYM (according to ENA) and it's not working ATM
# we were advised to prefix the views and this is the simplest way.
# The short-term plan is to remove the dependency of ENA databases
db_table = 'ERA\".\"V_MGP_ASSEMBLY_STUDY'


class Project(models.Model):
Expand Down

0 comments on commit 3e33442

Please sign in to comment.