<html>
    <head>
      <base href="https://bugs.documentfoundation.org/">
    </head>
    <body>
      <p>
        <div>
            <b><a class="bz_bug_link 
          bz_status_UNCONFIRMED "
   title="UNCONFIRMED - (Correct) SQL-Query (wrongly) returns 0 (null) Values in specific Column. DBMS: PostgreSQL"
   href="https://bugs.documentfoundation.org/show_bug.cgi?id=118492#c1">Comment # 1</a>
              on <a class="bz_bug_link 
          bz_status_UNCONFIRMED "
   title="UNCONFIRMED - (Correct) SQL-Query (wrongly) returns 0 (null) Values in specific Column. DBMS: PostgreSQL"
   href="https://bugs.documentfoundation.org/show_bug.cgi?id=118492">bug 118492</a>
              from <span class="vcard"><a class="email" href="mailto:drewjensen.inbox@gmail.com" title="Drew Jensen <drewjensen.inbox@gmail.com>"> <span class="fn">Drew Jensen</span></a>
</span></b>
        <pre>Created <span class=""><a href="http://bugs.documentfoundation.org/attachment.cgi?id=143261" name="attach_143261" title="query after change">attachment 143261</a> <a href="http://bugs.documentfoundation.org/attachment.cgi?id=143261&action=edit" title="query after change">[details]</a></span>
query after change

I'm using a fresh postgresql 10 install on Ubuntu 18.04 and Libo with
postgres:SDBC. 

Created the three tables and a few records.

SELECT "SP"."id", "SP"."hämo", "S"."situation" 
FROM "situation_p" "SP", "situation" "S" 
WHERE "SP"."situation" = "S"."id"

got just the output you did in Base

changed it to: 

SELECT "SP"."id", "SP"."hämo", "S"."situation" 
FROM "situation_p" "SP", "situation" "S" 
WHERE "S"."id" = "SP"."situation"

and get what seems to be what you are looking for. (screen shot attached)</pre>
        </div>
      </p>


      <hr>
      <span>You are receiving this mail because:</span>

      <ul>
          <li>You are the assignee for the bug.</li>
      </ul>
    </body>
</html>