• magoo,

    small correction to my previous post,

    This is a good solution. In the query output, base_id is getting eliminated,but I need to get the the base_id record also

    regards