Closed jshelley-xx closed 7 years ago
looks like you left some debugging println's in send-uuid
This should probably be mentioned in the documentation, in the PostgreSQL Types section. It might be worth mentioning there that UUIDs are only supported with the uuid-ossp
extension enabled, but that shouldn’t really matter much, given that a uuid
column could only exist with that already enabled.
a fresh install of postgresql on freebsd, without uuid-ossp
listed in pg_extension
can handle uuid values fine, which seems to be consistent with the final paragraph of https://www.postgresql.org/docs/9.6/static/datatype-uuid.html
Ah, you’re right—you only need uuid-ossp
to generate UUIDs. The support should still be mentioned in the documentation, though.
Looking over the type support documentation, it's talking about how arrays are also supported for each of the supported single types. I'll work on getting that running and get back to you.
uuid[] added, now, and I added the "uuid" entry to the type support doc. Hopefully that's what you were wanting.
It seems like it would also be a good idea to add a test to db-test/tests/db/db/sql-types.rkt
. Otherwise, I think this change looks good, though I believe @rmculpepper is the maintainer, so his review is the important one.
Working on getting the tests (running and) updated.
Added a test case for uuids in PG.
Changed to use the file/sha1 functions and added a uuid? predicate.
I’ve taken advantage of the fact that GitHub allows maintainers to push to PR branches to implement @rmculpepper’s suggestions and document the uuid?
function, mostly because I’d actually really like to have access to these changes, myself! Hopefully this should be sufficient.
This should get v4 uuids working with postgres. Values have the feel of strings to client code.