Can you write a SQL statement which will join the LOAN_SID with the primary key column of the MST_LN_SHARE table and check if you are able to get the values. The lookup_ext() also does the same function where it will bring NULL if there is no condition matching
Regards
Arun Sasi