DB view issue

woocash
Tera Contributor

I have a DB view which in a simplified version looks like this:

 

Service Contract - Asset - Maintenance Contract 1 - Maintenance Contract 2

 

All works well provided that all 3 contracts exist and are linked to the Asset via the Assets Covered table. However, if that's not the case and one of them is missing, the asset is filtered out from the view completely. Now, I understand this is expected behaviour, etc. but is there any way to prevent that and achieve the following example display (or something along the lines)?

 

Service Contract - Asset X - (empty) - Maintenance Contract 2

Service Contract - Asset Y - Maintenance Contract 1 - (empty)

Service Contract - Asset Z - (empty) - (empty)

1 REPLY 1

J Siva
Tera Sage

Hi @woocash 

Share the screenshot of your db configuration.

You need to make "Left join" true in Maintenance contract 1 and Maintenance contract 2 tables.

Regards,

Siva