phiresky
phiresky
case when @orderid > 0 then orders.orderid else 0
Which is a string for me. https://www.postgresql.org/docs/8.2/static/functions-aggregate.html
With `.innerJoin` or `.leftJoin` it's very easy to accidentaly get the parameters the wrong way around and there is no way to notice. For example ```typescript sql.from(chkTable) .innerJoin(menu.meal) .on({ _mensa:...
it serializes new Date() using .toString() which results in ` invalid input syntax for type timestamp with time zone: "Thu Dec 11 2014 00:00:00 GMT+0100 (CET)"`
``` class TimestampTZType extends s.Type { name = 'timestamptz'; serialize(arg: Date): string | number | boolean { return arg as any; } deserialize(arg: string | number | boolean): Date {...
e.g. `select mensa.meals where (_mensaid, _lineid) in ((a,b), (c,d))`
currently must be `.cast(tInteger, true)` to be able to use functions like `add` etc.
Reference: https://www.postgresql.org/docs/9.1/static/sql-select.html#SQL-FOR-UPDATE-SHARE
Reference: https://www.postgresql.org/docs/9.5/static/sql-insert.html#SQL-ON-CONFLICT