diff --git a/pgtype/pgtype.go b/pgtype/pgtype.go index 45b9a092..8c4a8c49 100644 --- a/pgtype/pgtype.go +++ b/pgtype/pgtype.go @@ -1416,7 +1416,7 @@ func (ci *ConnInfo) Encode(oid uint32, formatCode int16, value interface{}, buf plan := ci.PlanEncode(oid, formatCode, value) if plan == nil { - return nil, fmt.Errorf("unable to encode %v", value) + return nil, fmt.Errorf("unable to encode %#v into OID %d", value, oid) } return plan.Encode(value, buf) }