8 releases (4 breaking)

0.24.0 Jan 10, 2024
0.23.2 Nov 2, 2023
0.23.1 Oct 22, 2023
0.23.0 Jan 31, 2023
0.20.0 Aug 31, 2022

#2117 in Database interfaces

MIT license

245KB
5.5K SLoC

Firebird adapter for diesel ORM

Diesel is a safe, extensible ORM and Query Builder for Rust. With this crate you can use it for access the Firebird database.

This crate only implements the firebird backend for Diesel. To use diesel features, you must import it.

By default the lib will use the native client. If you want use the pure rust client, enable the pure_rust feature.

Establishing a connection

use diesel::prelude::*;
use rsfbclient_diesel::FbConnection;

let conn = FbConnection::establish("firebird://SYSDBA:masterkey@localhost/test.fdb");

CRUD example

We also provide a CRUD example with employee.fdb database.


lib.rs:

The Firebird Diesel

This crate only implements the firebird backend for Diesel. To use diesel features, you must import it.

By default the lib will use the native client. If you want use the pure rust client, enable the pure_rust feature.

Establishing a connection

use diesel::prelude::*;
use rsfbclient_diesel::FbConnection;

let conn = FbConnection::establish("firebird://SYSDBA:masterkey@localhost/test.fdb");

Dependencies

~10–18MB
~251K SLoC