ไวยากรณ์ภาษาในการค้นหาของ Merchant Center
การอ้างอิงไวยากรณ์เกี่ยวกับภาษาของคำค้นหาใน Merchant Center (ในรูปแบบนิพจน์ทั่วไป) มีดังนี้
Query -> SelectClause FromClause? WhereClause? OrderByClause? LimitClause?
SelectClause -> SELECT FieldName (, FieldName)*
FromClause -> FROM TableName
WhereClause -> WHERE Condition (AND Condition)*
OrderByClause -> ORDER BY Ordering (, Ordering)*
LimitClause -> LIMIT PositiveInteger
Condition -> FieldName Operator Value | FieldName BETWEEN Value AND Value
Operator -> = | != | > | >= | < | <= | <> | IN | NOT IN |
CONTAINS ANY | CONTAINS ALL | CONTAINS NONE | DURING |
LIKE | NOT LIKE | REGEXP_MATCH | NOT REGEXP_MATCH
Value -> Number | NumberList | String | StringList | Function
Ordering -> FieldName (ASC | DESC)?
FieldName -> [a-z] ([a-zA-Z0-9._])*
TableName -> [A-Z] ([a-zA-Z_])*
StringList -> ( String (, String)* )
NumberList -> ( Number (, Number)* )
PositiveInteger -> [1-9] ([0-9])*
Number -> -? [0-9]+ (. [0-9] [0-9]*)?
String -> (' Char* ') | (" Char* ")
Function -> LAST_14_DAYS | LAST_30_DAYS | LAST_7_DAYS |
LAST_BUSINESS_WEEK | LAST_MONTH | LAST_WEEK_MON_SUN |
LAST_WEEK_SUN_SAT | THIS_MONTH | THIS_WEEK_MON_TODAY |
THIS_WEEK_SUN_TODAY | TODAY | YESTERDAY
?
หมายถึงองค์ประกอบที่ไม่บังคับ
*
หมายถึง 0 ขึ้นไป +
หมายถึง 1 รายการขึ้นไป
(xxxxxx)
หมายถึงการจัดกลุ่ม
[a-z0-9]
หมายถึงช่วงอักขระ
|
ย่อมาจาก "or"
เนื้อหาของหน้าเว็บนี้ได้รับอนุญาตภายใต้ใบอนุญาตที่ต้องระบุที่มาของครีเอทีฟคอมมอนส์ 4.0 และตัวอย่างโค้ดได้รับอนุญาตภายใต้ใบอนุญาต Apache 2.0 เว้นแต่จะระบุไว้เป็นอย่างอื่น โปรดดูรายละเอียดที่นโยบายเว็บไซต์ Google Developers Java เป็นเครื่องหมายการค้าจดทะเบียนของ Oracle และ/หรือบริษัทในเครือ
อัปเดตล่าสุด 2024-09-20 UTC
[null,null,["อัปเดตล่าสุด 2024-09-20 UTC"],[[["The Merchant API is the new version of the Content API for Shopping and represents the future of product data integration."],["Developers can learn more about the Merchant API and its benefits, as well as how to participate in shaping its future, in the official announcement blog post."],["The Merchant Center Query Language uses a structured grammar, allowing developers to query data with clauses like `SELECT`, `FROM`, `WHERE`, `ORDER BY`, and `LIMIT`."],["Various operators such as comparison, range, list inclusion, and regular expression matching are supported within the `WHERE` clause to filter data effectively."],["The `REGEXP_MATCH` operator leverages RE2 syntax for flexible and powerful regular expression-based filtering capabilities."]]],["The beta version of the Merchant API, the new Content API for Shopping, is available. The Merchant Center Query Language uses a specific grammar, defined with regular expressions, including `SELECT`, `FROM`, `WHERE`, `ORDER BY`, and `LIMIT` clauses. Conditions use operators like `=`, `IN`, `CONTAINS`, and `DURING`, and values can be numbers, strings, or functions like `LAST_14_DAYS`. The `REGEXP_MATCH` operator employs RE2 syntax. The documentation details how to integrate and shape this API.\n"]]