100 min, thinkphp fuzzy query about the problem, fuzzy query conditions for the array

Source: Internet
Author: User
100 points, urgent and urgent, thinkphp fuzzy query problem, fuzzy query conditions for an array
100 points, urgent and urgent, thinkphp fuzzy query problem, fuzzy query conditions for an array
$map 2[' ornamentations.tags '] =array (' Like ', Array ("% $a 1%", "% $a 2%", "% $a 3%"), ' or ');
The query condition should be and relationship, but write and the error, can not find the results, urgent urgent


------to solve the idea----------------------
Use $map 2[' _string '.
------to solve the idea----------------------
You need to enclose the conditional% with a single quotation mark, or you can return the error when you assemble the SQL.
------to solve the idea----------------------
References:
Quote: References:

Use $map 2[' _string '.

What does this mean? Don't understand



You can find out what's going on in the thinkphp manual by searching for _string, meaning you'll be able to answer the SQL statements you want.

------to solve the idea----------------------
Error output your SQL statement to see SQL stitching errors
------to solve the idea----------------------
Use $map [' _string '] to assign the original ecological where condition statement to this variable ...
  • Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.