Now, my local development is working properly. So, I can work on live data modeling. Before that, I tried to model the database structure for my project. It might be filled with some flaws and errors, but it’s my first time to model some real project. In that case, I will also welcome some comments on my database structure.
I will explain the structure. The authentication (auth) table is already provided by hasura with many advanced tools like email verification and mobile verification. This table has already useful columns. So, I will not be explaining that.
Next table is profile table, which will contain username and id for quick access. The id of the user will be the primary key. That will also be the foreign key for other tables which are required some user.
Next table is room owner table. Here id is again primary key and the foreign key from profile table. It has a field reply_time. This is time decided by the user to reply messages of inquiry.
Next table is a user table. It just says which user has logged. Here, I think I have to do some work in later.
Next table is room table. This table contains all information regarding the room. Here, id is the primary key. The room_owner_id has the foreign key from room_owner table. It will tell whose the room is.
Next table is images for storing images. Here, I have to tell a good thing about hasura platform. It also contains filestore. So, I have to be less worried how to manage images for my project.
I think I am done modeling and need to check the model working through Postman. If you don’t know postman, I would say it is an API testing tool. So, I will be working and refining my database structure. Till then 🙂