Skip to content

MongoDB request DSLopensavvy.ktmongo.dsl.queryFilterQuerygt

gt

open infix fun <V> Field<T, V>.gt(value: V)

Selects documents for which this field has a value strictly greater than value.

Example

class User(
    val name: String,
    val age: Int?,
)

collection.find {
    User::age gt 18
}

External resources

See also

open infix fun <V> KProperty1<T, V>.gt(value: V)

Selects documents for which this field has a value strictly greater than value.

Example

class User(
    val name: String,
    val age: Int?,
)

collection.find {
    User::age gt 18
}

External resources

See also