Skip to content

Commit

Permalink
#590 SQL Comparisons lost in upgrade from 0.8 to 0.15
Browse files Browse the repository at this point in the history
neq function on a column introduced and on ExpressionWithColumnType.neq replaced with Expression.neq
  • Loading branch information
Tapac committed Jun 30, 2019
1 parent 6dcce56 commit aeeb897
Showing 1 changed file with 8 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,14 @@ object SqlExpressionBuilder {
return NeqOp(this, wrap(other))
}

infix fun <T, S1: T?, S2: T?> ExpressionWithColumnType<in S1>.neq(other: Expression<in S2>) : Op<Boolean> = NeqOp(this, other)
infix fun <T:Comparable<T>> Column<EntityID<T>>.neq(t: T?) : Op<Boolean> {
if (t == null) {
return isNotNull()
}
return NeqOp(this, wrap(t))
}

infix fun <T, S1: T?, S2: T?> Expression<in S1>.neq(other: Expression<in S2>) : Op<Boolean> = NeqOp(this, other)

fun<T> ExpressionWithColumnType<T>.isNull(): Op<Boolean> = IsNullOp(this)

Expand Down

0 comments on commit aeeb897

Please sign in to comment.