Database

Storing and retrieving data from sqlite with python

For making everything simpler we will use peewee orm with python sqlite3…. First create and connect to our database from peewee import * # SQLite database setup with Peewee db = SqliteDatabase(‘cv_database.db’) class User(Model): username = CharField(unique=True) # Add more user details as needed class Meta: database = db class CV(Model): user = ForeignKeyField(User, backref=’cv’) […]

MongoDB Indexing Basics with Python

MongoDB Improve performance Why you should use Indexing in Databases Faster Searches Indexes act as efficient lookup structures, enabling rapid retrieval of data matching query criteria. Optimized Query Execution By using indexes, databases can strategically navigate the data path, minimizing processing time for queries. Reduced Disk I/O Indexes allow the database to locate data directly, […]