Fork me on GitHub

I'm having a little trouble with hugsql and was hoping somewhat might be able to tell me if I'm doing something wrong or if I've encountered a bug I need to report/look into.


I have a postgres table with 2 timestamptz fields that allows NULLs. On the hugsql side, one of the fields maps to basically {:timestamp_1 ...} while the other one maps to {:sub {:timestamp_2}}


:timestamp_1 properly inserts a NULL, but :timestamp_2 throws a Parameter Mismatch exception


I'm accessing timestamp_1 via :timestamp_1 in my .sql file, and timestamp_2 via :sub.timestamp_2 - so I don't believe it's a simple mistake on my part - as I'm doing this for other field types just fine


Is that something anyone has ran into?