Constantine Molchanov
Constantine Molchanov
@cmd410 thanks for the update! Now, the only thing left that I'll have to ask you to do is, please add a changelog entry for your change. And thank you...
@cmd410 some tests are failing.
@cmd410 most errors have to do with incorrect column names: ``` LINE 1: SELECT species, favToy, id FROM "Pet" ^ HINT: Perhaps you meant to reference the column "Pet.favToy". ```...
DbConn is a type Norm borrows from ndb. It offers exec proc for both SQLite and Postgres: - https://xzfc.github.io/ndb.nim/v0.19.8/sqlite.html#exec%2CDbConn%2CSqlQuery%2Cvarargs%5BDbValue%2CdbValue%5D - https://xzfc.github.io/ndb.nim/v0.19.8/postgres.html#exec%2CDbConn%2CSqlQuery%2Cvarargs%5BDbValue%2CdbValue%5D What problem specifically are you experiencing?
> Should creating an index be done via raw SQL or should norm provide a way of facilitating this, e.g. by having an "index"-pragma ? I think having a pragma...
@PhilippMDoerner I've just looked at the fromRow implementation and it's pretty simple: https://github.com/moigagoo/norm/blob/28121e0c334551f4b69e8f18f0f6bd997dc8aeaf/src/norm/private/sqlite/rowutils.nim#L17 The complexity comes from the needing to populate nested models. I think it shouldn't be hard to...
And given that you can actually get a raw Row with just plain ndb select, you could achieve your goal. One thing that I have concerns about is that this...
@PhilippMDoerner I think we already have it? Here's an example: ``` nim> import norm/model nim> import norm/sqlite nim> import norm/private/sqlite/rowutils nim> type .... M = ref object of Model .......
I’m sure there are tools that can do that for a DB, so I don’t really think Norm would be necessary for it. But if somehow no such tool exist...
Any ideas how this could be done?