Issue with reference fields in db manager - knex referencing wrong db settings

it is in .wappler/targets/development/databases/db.json
just at the end of the initial schema definition
I have corrected it now but this is where it was, i removed the contents which were as i showed above

Is this not for a specific table? I don't think we have global db options but per table. But if the tables were refreshed you shouldn't have old db options?

Like after i changed to SQLite and refreshed I got empty tables because my SQLite didn't existed yet:

image

OK I could now finally reproduce it :slight_smile:

indeed was per table and those weren't refreshed in sqlite fully because they had the same names so the db options were kept and that caused the problem

will see to fix it now

I have completely deleted the connection files and regenerated them and the process seems to be working now.

If it happens again i will report.
Wondering if there could have been some corruption in the schema file causing updates to fail in some way?

Great, thought i was going mad.

Also I have had the discussion recently about database connections and being per target.

Teodor insisted they were not per target although i could clearly see in the .wappler definition files they were.
Maybe been there so long everyone had forgot!

yes Wappler caches the database schema per target to see the changes.

anyway it will be all fixed in the next update

well done, quickly fixed

Fixed in Wappler 6.6.2

This topic was automatically closed after 32 hours. New replies are no longer allowed.