Skip to content

GitLab

  • Menu
Projects Groups Snippets
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • A api
  • Project information
    • Project information
    • Activity
    • Members
  • Packages & Registries
    • Packages & Registries
    • Package Registry
    • Container Registry
    • Infrastructure Registry
  • Wiki
    • Wiki
  • Activity
Collapse sidebar
  • ironapi
  • api
  • Wiki
  • Api
  • Queries
  • Query Search Options

Query Search Options · Changes

Page history
attrs docu authored Jan 25, 2022 by Andrea Pavlovic's avatar Andrea Pavlovic
Hide whitespace changes
Inline Side-by-side
API/Queries/Query-Search-Options.md
View page @ 8d59b844
[[_TOC_]] [[_TOC_]]
# NULL / NOT NULL # DBIX::Class Inbuilts
## (not) NULL
To search for (not) NULL entries, use the null value in json: To search for (not) NULL entries, use the null value in json:
```JSON `POST /data/extensions/client_meta_data/query`
#/data/extensions/widget/query
{ "conds" : {"me.query" : null }} ```json
{
"conds": {
"me.api_key": null
}
}
``` ```
```JSON ```json
#/data/extensions/widget/query {
"conds": {
"conds" : { "me.api_key": {
"me.query" : { "-not": null
"-not" : null
} }
} }
}
``` ```
# IDENT - comparing two columns ## IDENT - comparing two columns
```JSON This query will return all entries where name=label.
#/data/system/entity/query
{ "conds" : {"me.name" : {"-ident": "module.name"}} } `POST /data/system/entity/query`
```json
{
"conds": {
"me.name": {
"-ident": "me.label"
}
}
}
``` ```
```SQL ```sql
WHERE ( me.name = module.name ) WHERE ( me.name = me.label )
``` ```
<http://search.cpan.org/~ilmari/SQL-Abstract-1.84/lib/SQL/Abstract.pm#-ident> <http://search.cpan.org/~ilmari/SQL-Abstract-1.84/lib/SQL/Abstract.pm#-ident>
# LIKE and ILIKE ## LIKE and ILIKE
```JSON `POST /data/system/entity/query`
#/data/system/entity/query
```json
#
{ "conds" : {"me.name" : {"-like": "%a%"}} } { "conds" : {"me.name" : {"-like": "%a%"}} }
{ "conds" : {"me.name" : {"-not_like": "%a%"}} } { "conds" : {"me.name" : {"-not_like": "%a%"}} }
{ "conds" : {"me.name" : {"-ilike": "%a%"}} } { "conds" : {"me.name" : {"-ilike": "%a%"}} }
{ "conds" : {"me.name" : {"-not_ilike": "%a%"}} } { "conds" : {"me.name" : {"-not_ilike": "%a%"}} }
``` ```
```SQL ```sql
WHERE ( me.name like ? ) WHERE ( me.name like ? )
WHERE ( me.name not like ? ) WHERE ( me.name not like ? )
``` ```
# (not) IN ## (not) IN
```JSON Search for a list of values.
#/data/system/entity/query
`POST /data/system/entity/query`
```json
{ "conds" : {"me.name" : {"-in": [1,2]}} } { "conds" : {"me.name" : {"-in": [1,2]}} }
{ "conds" : {"me.name" : {"-not_in": [3,4]}} } { "conds" : {"me.name" : {"-not_in": [3,4]}} }
``` ```
```SQL # IronAPI Extensions
WHERE ( me.name in (?) )
WHERE ( me.name not in (?) )
```
# -in_function # -in_function
......
Clone repository
  • API
    • Available Endpoints
    • Changing Passwords
    • Form Input Types
    • Introduction
    • Logout
    • Plugins
    • Queries
    • Queries
      • Attributes
      • Context
      • Query Examples
      • Query Search Options
      • Referenced Instances
      • Saved Queries
    • Schema_Changes
    • Storing Files
View All Pages