Answers for "how to pass php variable in mysql laravel database"

PHP
0

how to pass php variable in mysql laravel database

$data = DB::select(DB::raw("SELECT pur_price FROM productpricing WHERE
                        mst_uid = (SELECT 
                                mst_uid
                            FROM
                                master_material
                            WHERE prd_id = :product_id
                                    AND mtl_id = :material
                                    AND color_id = :color
                                    AND mtl_status ='1')
                                     AND ($size between pur_sqft1 AND ifnull(pur_sqft2,$size))"),
                                    array('product_id'      =>$product_id,
                                             'material'     =>$material,
                                             'color'        =>$color,                                                 
                                    ));
Posted by: Guest on May-02-2020

Code answers related to "how to pass php variable in mysql laravel database"

Browse Popular Code Answers by Language