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
Show whitespace changes
Inline Side-by-side
API/Queries/Query-Search-Options.md
View page @ 8d59b844
[[_TOC_]]
# NULL / NOT NULL
# DBIX::Class Inbuilts
## (not) NULL
To search for (not) NULL entries, use the null value in json:
```JSON
#/data/extensions/widget/query
`POST /data/extensions/client_meta_data/query`
{ "conds" : {"me.query" : null }}
```json
{
"conds": {
"me.api_key": null
}
}
```
```JSON
#/data/extensions/widget/query
"conds" : {
"me.query" : {
"-not" : null
```json
{
"conds": {
"me.api_key": {
"-not": null
}
}
}
```
# IDENT - comparing two columns
## IDENT - comparing two columns
```JSON
#/data/system/entity/query
This query will return all entries where name=label.
{ "conds" : {"me.name" : {"-ident": "module.name"}} }
`POST /data/system/entity/query`
```json
{
"conds": {
"me.name": {
"-ident": "me.label"
}
}
}
```
```SQL
WHERE ( me.name = module.name )
```sql
WHERE ( me.name = me.label )
```
<http://search.cpan.org/~ilmari/SQL-Abstract-1.84/lib/SQL/Abstract.pm#-ident>
# LIKE and ILIKE
## LIKE and ILIKE
```JSON
#/data/system/entity/query
`POST /data/system/entity/query`
```json
#
{ "conds" : {"me.name" : {"-like": "%a%"}} }
{ "conds" : {"me.name" : {"-not_like": "%a%"}} }
{ "conds" : {"me.name" : {"-ilike": "%a%"}} }
{ "conds" : {"me.name" : {"-not_ilike": "%a%"}} }
```
```SQL
```sql
WHERE ( me.name like ? )
WHERE ( me.name not like ? )
```
# (not) IN
## (not) IN
```JSON
#/data/system/entity/query
Search for a list of values.
`POST /data/system/entity/query`
```json
{ "conds" : {"me.name" : {"-in": [1,2]}} }
{ "conds" : {"me.name" : {"-not_in": [3,4]}} }
```
```SQL
WHERE ( me.name in (?) )
WHERE ( me.name not in (?) )
```
# IronAPI Extensions
# -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