- Install Flask,Flask-SQLAlchemy, psycopg2 and PostgreSQL.
- Create a new Flask project and a new PostgreSQL database.
- In the PostgreSQL database, create two tables: one for messages and one for likes.
- In the messages table, include columns for the message text, the user who posted it, and the timestamp.
- In the likes table, include columns for the message ID, the user who liked it, and the timestamp.
- Use Flask to create routes for creating and querying messages and likes.
- Use PostgreSQL triggers to automatically update the "likes" count for a message whenever a new like is added or removed.
- Run the following command to create the tables in the database: db.create_all().
- Start the application by running 'flask run' command.
-
Notifications
You must be signed in to change notification settings - Fork 0
Backend Internship Assignment - Articuno Coding LLP
shourygupta28/Articuno-Coding-Intern-Assignment
Folders and files
| Name | Name | Last commit message | Last commit date | |
|---|---|---|---|---|
Repository files navigation
About
Backend Internship Assignment - Articuno Coding LLP
Topics
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published