开发者社区 问答 正文

请大神给讲解下面mysql语句的作用,谢谢!

请大神给讲解下面mysql语句的作用,谢谢!
`$query = "select orderid from orders where

           customerid = $customerid and  
           amount > ".$_SESSION['total_price']."-.001 and //这句是什么意思? 
           amount < ".$_SESSION['total_price']."+.001 and  //这句是什么意思? 
           date = '$date' and 
           order_status = 'PARTIAL' and 
           ship_name = '$ship_name' and 
           ship_address = '$ship_address' and 
           ship_city = '$ship_city' and 
           ship_state = '$ship_state' and 
           ship_zip = '$ship_zip' and 
           ship_country = '$ship_country'"; `

展开
收起
落地花开啦 2016-02-28 15:46:36 1905 分享 版权
1 条回答
写回答
取消 提交回答
  • 喜欢技术,喜欢努力的人

    就是传了一个变量 total_price,希望找到等于这个值的数据。

    2019-07-17 18:49:41
    赞同 展开评论