Added plan detail query.