seven-technologies-cloud / pythonrest

Creative Commons Zero v1.0 Universal
10 stars 4 forks source link

Add full support for Set and Enum Types #57

Closed leo-viana closed 2 months ago

leo-viana commented 5 months ago

Goal

Add support for generating sql alchemy type of enum and set(for mysql databases) with their permitted values and validations

Description

Currently, Enum and Set types are not being generated in their ideal way(Set is currently being mapped to Enum and Enum does not validate its permitted values when inserting and updating values on the table).

The Set data type has a class defined by sqlalchemy on this path: image To give support to the set data type, the following changes will have to be made:

To validate the values of Enum(and SET when the above is working), the following will have to be considered when changing files:

leo-viana commented 2 months ago

Commit fe6be55 fixed this issue