app/Module/RelationshipsChartModule.php
private function excludeFamilies($xref1, $xref2, $tree_id): array
    {
        return DB::table('link AS l1')
            ->join('link AS l2', static function (JoinClause $join): void {
                $join
                    ->on('l1.l_to', '=', 'l2.l_to')
                    ->on('l1.l_type', '=', 'l2.l_type')
                    ->on('l1.l_file', '=', 'l2.l_file');
            })
            ->where('l1.l_file', '=', $tree_id)
            ->where('l1.l_type', '=', 'FAMS')
            ->where('l1.l_from', '=', $xref1)
            ->where('l2.l_from', '=', $xref2)
            ->pluck('l1.l_to')
            ->all();
    }
private function excludeFamilies($xref1, $xref2, $tree_id): array
    {
        return DB::table('link AS l1')
            ->join('link AS l2', static function (JoinClause $join): void {
                $join
                    ->on('l1.l_to', '=', 'l2.l_to')
                    ->on('l1.l_type', '=', 'l2.l_type')
                    ->on('l1.l_file', '=', 'l2.l_file');
            })
            ->where('l1.l_file', '=', $tree_id)
            ->where('l1.l_type', '=', 'FAMS')
            ->where('l1.l_from', '=', $xref1)
            ->where('l2.l_from', '=', $xref2)
            ->pluck('l1.l_to')
            ->all();
    }
private function excludeFamilies ( $ xref1 , $ xref2 , $ tree_id ) : array { return DB :: table ( 'link AS l1' ) -> join ( 'link AS l2' , static function ( JoinClause $ join ) : void { $ join -> on ( 'l1.l_to' , '=' , 'l2.l_to' ) -> on ( 'l1.l_type' , '=' , 'l2.l_type' ) -> on ( 'l1.l_file' , '=' , 'l2.l_file' ) ; } ) -> where ( 'l1.l_file' , '=' , $ tree_id ) -> where ( 'l1.l_type' , '=' , 'FAMS' ) -> where ( 'l1.l_from' , '=' , $ xref1 ) -> where ( 'l2.l_from' , '=' , $ xref2 ) -> pluck ( 'l1.l_to' ) -> all ( ) ; }
Find all families of two individuals

@param string $xref1
@param string $xref2
@param int    $tree_id

@return string[]
Find all families of two individuals