crate / crate-python

Python DB API client library for CrateDB, using HTTP.
https://cratedb.com/docs/python/
Apache License 2.0
79 stars 30 forks source link

Documentation: Add section about using `gen_random_text_uuid` as auto-PK #585

Closed amotl closed 11 months ago

amotl commented 11 months ago

About

CrateDB 4.5.0 added the gen_random_text_uuid() scalar function, which can also be used within an SQL DDL statement, in order to automatically assign random identifiers to newly inserted records on the server side. In this spirit, it is suitable to be used as a PRIMARY KEY constraint for SQLAlchemy.

This patch adds a corresponding documentation section how to use it with SQLAlchemy.

References

/cc @surister