การจัดกลุ่มข้อความค้นหา
จัดทุกอย่างให้เป็นระเบียบอยู่เสมอด้วยคอลเล็กชัน
บันทึกและจัดหมวดหมู่เนื้อหาตามค่ากำหนดของคุณ
คุณจัดกลุ่มข้อความค้นหาหลายรายการเข้าด้วยกันได้โดยใช้เครื่องหมายวงเล็บ ((
และ )
)
เช่น
(hello OR world) AND lang:java
นอกจากนี้ คุณยังซ้อนกลุ่มหลายกลุ่มได้ด้วย เช่น
((Strings OR StringBuilder) AND lang:java) OR (std AND lang:cpp)
ดูข้อมูลเพิ่มเติมได้ที่ตัวเลือกไวยากรณ์เพิ่มเติม
ในเอกสารอ้างอิง
เนื้อหาของหน้าเว็บนี้ได้รับอนุญาตภายใต้ใบอนุญาตที่ต้องระบุที่มาของครีเอทีฟคอมมอนส์ 4.0 และตัวอย่างโค้ดได้รับอนุญาตภายใต้ใบอนุญาต Apache 2.0 เว้นแต่จะระบุไว้เป็นอย่างอื่น โปรดดูรายละเอียดที่นโยบายเว็บไซต์ Google Developers Java เป็นเครื่องหมายการค้าจดทะเบียนของ Oracle และ/หรือบริษัทในเครือ
อัปเดตล่าสุด 2025-07-26 UTC
[null,null,["อัปเดตล่าสุด 2025-07-26 UTC"],[[["\u003cp\u003eSearch terms can be grouped together using parentheses for more complex queries.\u003c/p\u003e\n"],["\u003cp\u003eNested grouping with parentheses allows combining multiple search conditions.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eOR\u003c/code\u003e operator searches for either term within a group, while the \u003ccode\u003eAND\u003c/code\u003e operator requires both terms to be present.\u003c/p\u003e\n"],["\u003cp\u003eFor detailed syntax information, refer to the additional syntax options in the reference documentation.\u003c/p\u003e\n"]]],[],null,["# Grouping search terms\n\nYou can group multiple search terms together using parentheses (`(` and `)`).\nFor example: \n\n (hello OR world) AND lang:java\n\nYou can also nest multiple groups. For example: \n\n ((Strings OR StringBuilder) AND lang:java) OR (std AND lang:cpp)\n\nFor more information see [Additional syntax options](../reference#syntax-options)\nin the reference documentation."]]