mirror of
https://github.com/zitadel/zitadel.git
synced 2025-08-12 04:07:31 +00:00
feat: handle instanceID in projections (#3442)
* feat: handle instanceID in projections * rename functions * fix key lock * fix import
This commit is contained in:
@@ -50,6 +50,8 @@ const (
|
||||
OperationIn
|
||||
//OperationJSONContains checks if a stored value matches the given json
|
||||
OperationJSONContains
|
||||
//OperationNotIn checks if a stored value does not match one of the passed value list
|
||||
OperationNotIn
|
||||
|
||||
operationCount
|
||||
)
|
||||
|
@@ -288,8 +288,11 @@ func (db *CRDB) columnName(col repository.Field) string {
|
||||
}
|
||||
|
||||
func (db *CRDB) conditionFormat(operation repository.Operation) string {
|
||||
if operation == repository.OperationIn {
|
||||
switch operation {
|
||||
case repository.OperationIn:
|
||||
return "%s %s ANY(?)"
|
||||
case repository.OperationNotIn:
|
||||
return "%s %s ALL(?)"
|
||||
}
|
||||
return "%s %s ?"
|
||||
}
|
||||
@@ -304,6 +307,8 @@ func (db *CRDB) operation(operation repository.Operation) string {
|
||||
return "<"
|
||||
case repository.OperationJSONContains:
|
||||
return "@>"
|
||||
case repository.OperationNotIn:
|
||||
return "<>"
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
Reference in New Issue
Block a user