Hi there! I’m novice in anvil, have looked through tutorials and forum questions, but…still have some questions.
What I’m trying to do:
I"m trying out anvil app solution, since anvil looks amazing and very promising for our purposes.
Lets suppose there are database(s)(PostgreSQL) and some other services(not anvil) can use it. I want to add an anvil app(s) with UI to manage some of the data in the db.
The requested UI is thought to be pretty complex to implement(and expand later) it with Flask or Django (that’s why anvil:) )
Of course, I would like not to change the schema or duplicate the data in other tables, just use the database “as is”. For some new user-interface features, there is no restrictions how to store it (e.g. user access management, profiles, groups, dashboards etc)
What I’ve tried and what’s not working:
I created a small “hello postgres” app.
Having used the anvil database IDE I’ve got very specific schema for data, which does not look like a solution in our case.
If i use up-link and connect as external database I haven’t got how anvil.server manages this database.
From tutorial i see one can write directly (in each?) server.callable method: create connection, session, commit and close. It’s fine for some specific extra operations, but not for the main database.
Probably I haven’t found how to configure database connection, i see only single db configuration in yaml-file.
My questions are:
- is it possible to use my own PostgreSQL database schema instead of generated by anvil database IDE .
If yes, is any example, how proper to configure and try it out. What the flaws are in such case?
If not: - is it possible to use my own PostgreSQL database/schema for data storing and management as external db and another one (engined by anvil) for user management access e.g. or other features from anvil. Any examples how to configure app for this?
- Are there examples/experience of built anvil apps with manageable database schema? Including unsuccessful cases, sure.
Maybe I’m thinking wrong about what anvil is suitable for. Any advice on how to properly cook our case with the tool would be helpful.
Thank you in advance,
Stepan