select * from my_table where my_column01=xxx1 and (my_column02=xxx2 or my_column03=xxx3)
http://blog.csdn.net/kuluzs/article/details/52164880
http://blog.csdn.net/paditang/article/details/78802799
如果需要使用or的话,将must改成should
我也是刚学习,正好用到
{
"query": {
"bool": {
"filter": {
"bool": {
"should": [
{
"match": {
"eventname": "红楼梦"
}
},
{
"match": {
"description": "暑假必备"
}
},
{
"bool": {
"must": [
{
"match": {
"eventname": "西游记"
}
}
]
}
}
]
}
}
}
},
"size": 100
}