mirror of
https://github.com/open-metadata/OpenMetadata.git
synced 2025-11-29 00:53:24 +00:00
MINOR: Fix ES Req for Views (#19595)
This commit is contained in:
parent
0bbe147786
commit
459e1daa69
@ -402,19 +402,51 @@ class ESMixin(Generic[T]):
|
||||
"query": {
|
||||
"bool": {
|
||||
"must": [
|
||||
{"term": {"service.name.keyword": service_name}},
|
||||
{
|
||||
"term": {
|
||||
"tableType": [
|
||||
TableType.View.value,
|
||||
TableType.MaterializedView.value,
|
||||
TableType.SecureView.value,
|
||||
TableType.Dynamic.value,
|
||||
"bool": {
|
||||
"should": [
|
||||
{"term": {"service.name.keyword": service_name}}
|
||||
]
|
||||
}
|
||||
},
|
||||
{"term": {"deleted": False}},
|
||||
{"exists": {"field": "schemaDefinition"}},
|
||||
{
|
||||
"bool": {
|
||||
"must": [
|
||||
{
|
||||
"bool": {
|
||||
"should": [
|
||||
{
|
||||
"term": {
|
||||
"tableType": TableType.View.value
|
||||
}
|
||||
},
|
||||
{
|
||||
"term": {
|
||||
"tableType": TableType.MaterializedView.value
|
||||
}
|
||||
},
|
||||
{
|
||||
"term": {
|
||||
"tableType": TableType.SecureView.value
|
||||
}
|
||||
},
|
||||
{
|
||||
"term": {
|
||||
"tableType": TableType.Dynamic.value
|
||||
}
|
||||
},
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
{"bool": {"should": [{"term": {"deleted": False}}]}},
|
||||
{
|
||||
"bool": {
|
||||
"should": [{"exists": {"field": "schemaDefinition"}}]
|
||||
}
|
||||
},
|
||||
]
|
||||
}
|
||||
}
|
||||
|
||||
@ -244,8 +244,18 @@ class StoredProcedureLineageMixin(ABC):
|
||||
"query": {
|
||||
"bool": {
|
||||
"must": [
|
||||
{"term": {"service.name.keyword": self.service_name}},
|
||||
{"term": {"deleted": False}},
|
||||
{
|
||||
"bool": {
|
||||
"should": [
|
||||
{
|
||||
"term": {
|
||||
"service.name.keyword": self.service_name
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
{"bool": {"should": [{"term": {"deleted": False}}]}},
|
||||
]
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user