collerek
collerek
Yeah, seems like a good idea, seems also like sqlalchemy supports them so it should be possible https://github.com/sqlalchemy/sqlalchemy/issues/4894
I will take a look at this, I'm modifying the example value already so will check if adding property field to openapi schema causes some errors or not
Nesting ormar in pydantic is not really supported (another way around should be fine). So quick fix/workaround would be: ```python class SomeResponse(pydantic.BaseModel): authorized: bool = True me: User.get_pydantic() # generate...
Hi, with orms that actually try to parse the results into corresponding Models and validate the results it's always challenging to allow users to produce derived columns and subqueries and...
If you have the capacity i would be more than grateful. The new relation should be added as a separate class very similar to `ForeignKey` one, the difference is that...
No, unfortunately right now you cannot set relation fields to the primary key. This would change with compound primary keys (#137), but that's not yet ready.
Composite pks should be declared in Model Meta class, otherwise the fields would have to be aware of each other and pk creation would have to be delayed after all...
### Composite PK I think it should be clear and clearly separated: * you want one column pk -> use field property `primary_key=True`, * you want composite one -> use...
Ah, I just got what you meant :D Yes, the relation should be registered with `ForeignKeyConstraint.name` and be accessible/settable with this name (`a` in example). Thinking about this I guess...
The `PrimaryKeyConstraint` fields should be accessible anyway as those are own model fields, and you can set them quite freely, so in B class both `a` and `id` fields should...