-
Notifications
You must be signed in to change notification settings - Fork 854
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add databasetypename for time-with-time-zone #1883
Comments
I suppose we could add some sort of support for it... But FYI, the PostgreSQL project itself recommends against using that type. From https://www.postgresql.org/docs/current/datatype-datetime.html:
and later on the page
|
i see, thanks for the info. i still need to handle it in my use-case becaue of some legacy reasons, but i'll just go with the |
That number is the OID assigned to the type in PostgreSQL. That will never change. The only way that would change in pgx is if pgx added some sort of support for timetz - then the name would change to But for now I have added |
Is your feature request related to a problem? Please describe.
i'm writing code that makes decisions based on the https://pkg.go.dev/database/sql#ColumnType.DatabaseTypeName.
the problem is:
time
, it saysTIME
time with time zone
, it says1266
i can hardcode
1266
into my code, but i feel something likeTIMETZ
would be better.Describe the solution you'd like
return something better than
1266
for time-with-time-zoneDescribe alternatives you've considered
i can just use the value
"1266"
instead.The text was updated successfully, but these errors were encountered: