diff --git a/common/database_helpers.py b/common/database_helpers.py index 1873fc6c..be1e745e 100644 --- a/common/database_helpers.py +++ b/common/database_helpers.py @@ -467,8 +467,8 @@ def __init__(self, instrument_id): investigationInstrument = aliased(INSTRUMENT) self.base_query = self.base_query\ .join(FACILITYCYCLE.FACILITY) \ - .join(FACILITY.INSTRUMENTS) \ - .join(FACILITY.INVESTIGATIONS) \ + .join(FACILITY.INSTRUMENT) \ + .join(FACILITY.INVESTIGATION) \ .join(INVESTIGATION.INVESTIGATIONINSTRUMENT) \ .join(investigationInstrument, INVESTIGATIONINSTRUMENT.INSTRUMENT) \ .filter(INSTRUMENT.ID == instrument_id) \