Set Child table select Option Dynamically

How to set Child table select field Options dynamically. based on user selection system need to show the option.

Please check the example: Filter Options in Select Field

Another Reference: