@@ -434,8 +434,8 @@ crossmatch_create_scan_state(CustomScan *node)
434434static void
435435crossmatch_begin (CustomScanState * node ,EState * estate ,int eflags )
436436{
437- CrossmatchScanState * scan_state = (CrossmatchScanState * )node ;
438- CrossmatchContext * ctx = (CrossmatchContext * )palloc0 (sizeof (CrossmatchContext ));
437+ CrossmatchScanState * scan_state = (CrossmatchScanState * )node ;
438+ CrossmatchContext * ctx = (CrossmatchContext * )palloc0 (sizeof (CrossmatchContext ));
439439
440440scan_state -> ctx = ctx ;
441441setupFirstcall (ctx ,scan_state -> outer_idx ,
@@ -448,10 +448,10 @@ crossmatch_begin(CustomScanState *node, EState *estate, int eflags)
448448static TupleTableSlot *
449449crossmatch_exec (CustomScanState * node )
450450{
451- CrossmatchScanState * scan_state = (CrossmatchScanState * )node ;
452- TupleTableSlot * slot = node -> ss .ss_ScanTupleSlot ;
453- TupleDesc tupdesc = node -> ss .ss_ScanTupleSlot -> tts_tupleDescriptor ;
454- HeapTuple htup = scan_state -> stored_tuple ;
451+ CrossmatchScanState * scan_state = (CrossmatchScanState * )node ;
452+ TupleTableSlot * slot = node -> ss .ss_ScanTupleSlot ;
453+ TupleDesc tupdesc = node -> ss .ss_ScanTupleSlot -> tts_tupleDescriptor ;
454+ HeapTuple htup = scan_state -> stored_tuple ;
455455
456456TupleTableSlot * result ;
457457
@@ -534,7 +534,20 @@ crossmatch_rescan(CustomScanState *node)
534534static void
535535crossmatch_explain (CustomScanState * node ,List * ancestors ,ExplainState * es )
536536{
537+ CrossmatchScanState * scan_state = (CrossmatchScanState * )node ;
538+ StringInfoData str ;
539+
540+ initStringInfo (& str );
537541
542+ appendStringInfo (& str ,"%s" ,
543+ get_rel_name (scan_state -> outer_idx ));
544+ ExplainPropertyText ("Outer index" ,str .data ,es );
545+
546+ resetStringInfo (& str );
547+
548+ appendStringInfo (& str ,"%s" ,
549+ get_rel_name (scan_state -> inner_idx ));
550+ ExplainPropertyText ("Inner index" ,str .data ,es );
538551}
539552
540553void
@@ -559,4 +572,4 @@ _PG_init(void)
559572crossmatch_exec_methods .MarkPosCustomScan = NULL ;
560573crossmatch_exec_methods .RestrPosCustomScan = NULL ;
561574crossmatch_exec_methods .ExplainCustomScan = crossmatch_explain ;
562- }
575+ }