Skip to content

Implement SQLite database adapter #30

@anitnilay20

Description

@anitnilay20

Description

Create SQLite database adapter for development and lightweight applications.

Requirements

  • Implement Database trait for SQLite
  • SQLite connection handling with rusqlite or sqlx
  • File-based database support
  • In-memory database option
  • SQLite-specific SQL syntax handling
  • Write comprehensive tests

Acceptance Criteria

  • SQLite adapter implements Database trait
  • Support for file and in-memory databases
  • SQLite-specific SQL generation
  • Feature flag for SQLite support

Files to create

  • beatrix_core/src/relational/db/sqlite.rs
  • Update beatrix_core/Cargo.toml with SQLite dependencies

Example Usage

use beatrix::relational::SQLite;

// File database
let db = SQLite::new("database.db").await?;

// In-memory database
let db = SQLite::memory().await?;

let users = User::select().fetch_all(&db).await?;

Metadata

Metadata

Assignees

No one assigned

    Labels

    coreCore ORM functionalityhigh-priorityHigh priority itemsqliteSQLite database support

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions