String sql;String g=request.getParameter("find");if(g==null){sql="select shopping_no,shopping.mobile_no,mobile_name,brand,mobile_system,size,memory,price,snum,price*snum as shopSum from mobile,shopping where mobile.mobile_no=shopping.mobile_no and member_user='"+Saveuser.member_user+"'";}else{String input=request.getParameter("input");String where="";if(input!=""){where="where mobile.mobile_no=shopping.mobile_no and member_user='"+Saveuser.member_user+"' and mobile_name like '%"+input+"%'";}else if(input==""){where="where mobile.mobile_no=shopping.mobile_no and member_user='"+Saveuser.member_user+"'";}sql="select shopping_no,shopping.mobile_no,mobile_name,brand,mobile_system,size,memory,price,snum,price*snum as shopSum from mobile,shopping"+where;}
大神幫看看哪里寫錯了,錯誤提示Not unique table/alias: ’mobile'
白板的微信
2023-03-03 17:13:55