<div class="form-group">
<label>Stok Product Material</label>
<select class="form-control" id="prod_mat" name="prod_mat">
        <option selected>Pilih Material</option>
        <?php include"../koneksi.php";
        $data = mysqli_query ($koneksi, " SELECT 
                                        COUNT(stpj.STPJ_ID) AS jumlah,
                                        plan.ProductID,
                                        product.ItemDescription,
                                        product.SLoc,
                                        product.QtyUnit,
                                        sum(stpj.Qty) as jml,
                                        DATE_FORMAT(plan.DatePlan, '%y%m') AS dateplan,
                                        material.MaterialID,
                                        material.RawMat,
                                        stpj.Lock
                                FROM stpj 
                                INNER JOIN plan
                                ON stpj.PlanID=plan.PlanID
                                INNER JOIN product
                                ON plan.ProductID=product.ProductID
                                INNER JOIN material
                                ON plan.MaterialID=material.MaterialID
                                where stpj.Del_ID IS NULL AND plan.ProductID='$_GET[id]'
                                GROUP BY material.MaterialID, plan.ProductID");
        while($row = mysqli_fetch_array ($data)){
        ?>
        <option value="<?php echo $row['MaterialID']; ?>"><?php echo $row['RawMat']; ?> | <?php echo $row['jml']; ?> <?php echo $row['SLoc']; ?> @ <?php echo $row['QtyUnit']; ?> PCS</option>
        <?php } ?>
</select>
</div>