-
Notifications
You must be signed in to change notification settings - Fork 73
ORM #6
Comments
I'm not sure if it's feasible to adapt or make an ORM for Momoko. Personally I don't like ORMs, because it looks like complex things like joins and relations look even more complex in ORM style. And I probably won't use them if not needed. I haven't studied how an ORM exactly works, but if it doesn't require an connection and has functions that just generate SQL and return it a client can be made that feeds that SQL into an async query. Feedback please, if possible. :) |
Ok, I won't need an ORM for myself so I won't do this. |
I'll study and test it next week. I don't have time this week. :) |
I just wondering how do you use momoko? In my view, some sql-generator is necessary, for example, when try to insert a row which has none-options, the hard code sql way will not work. Very basic featured ORM would still be in need, such as insert,select,update and delete. Any ideas? |
Currently there are no plans to invest in ORM. You can apply Serializer approach - create SQL serialization for you models and then imply momoko. |
|
Yes, I'm saying you can write/use independent sql generator and then use momoko to execute it. I'm using momoko to execute complex two-page long queries to database and stream back the results. I personally don't have a use for ORM, although I don't undervalue it by any means. I would happily develop ORM for you if I had a free time, but currently I don't and demand for ORM for momoko is rather low. You are welcome to send pull requests :) |
Since the blocking-style API is done it's easier to write top-down code.
Maybe Peewee can be adapted so it uses Momoko.
The text was updated successfully, but these errors were encountered: