php - How to call define() with SQL statement with input parameters -
hey how call php define() sql statement has input parameters php page.
define("get_last_date", " select o.`order_date` autoship_order a, orders o a.last_order_id = o.order_id , a.autoship_order = ? ");
in order have definition reference across other pages need include_once
definition file.
include_once "definition.php";
to use constant
in mysqli query perform following action.
$stmt = $mysqli->prepare(get_last_date); $stmt->bind_param("i", 1);
Comments
Post a Comment