Updated lib config and small stuff
This commit is contained in:
parent
6fa8d6b7c6
commit
b2bd1e373b
3
.gitignore
vendored
3
.gitignore
vendored
@ -8,3 +8,6 @@ engine.o
|
||||
zig-out
|
||||
test1
|
||||
test2
|
||||
fly.toml
|
||||
dockerfile
|
||||
.dockerignore
|
||||
|
@ -1,6 +1,6 @@
|
||||

|
||||
|
||||
ZipponDB is a relational database written entirely in Zig from scratch with 0 dependencies.
|
||||
ZipponDB is a database written entirely in Zig from scratch with 0 dependencies.
|
||||
|
||||
ZipponDB's goal is to be ACID, light, simple, and high-performance. It aims at small to medium applications that don't need fancy features but a simple and reliable database.
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
pub const BUFFER_SIZE = 1024 * 10; // Used a bit everywhere. The size for the schema for example. 10kB
|
||||
pub const MAX_FILE_SIZE = 1024 * 1024; // 1MB
|
||||
pub const CPU_CORE = 0;
|
||||
pub const MAX_FILE_SIZE = 1024 * 1024 * 5; // Tried multiple MAX_FILE_SIZE and found 5Mb is good
|
||||
pub const CPU_CORE = 0; // If 0, take maximum using std.Thread.getCpuCount()
|
||||
|
||||
// Debug
|
||||
pub const PRINT_STATE = false;
|
||||
|
@ -1,5 +1,5 @@
|
||||
pub const BUFFER_SIZE = 1024 * 1024; // Used a bit everywhere. The size for the schema for example. 10kB
|
||||
pub const MAX_FILE_SIZE = 1024 * 1024; // 1MB
|
||||
pub const MAX_FILE_SIZE = 1024 * 1024 * 5; // Tried multiple MAX_FILE_SIZE and found 5Mb is good
|
||||
pub const CPU_CORE = 16;
|
||||
|
||||
// Debug
|
||||
@ -17,7 +17,7 @@ pub const HELP_MESSAGE = struct {
|
||||
\\run To run a query.
|
||||
\\db Create or chose a database.
|
||||
\\schema Initialize the database schema.
|
||||
\\dump To export data in other format and backup.
|
||||
\\dump To export data in other format and backup. (experimental)
|
||||
\\quit Stop the CLI with memory safety.
|
||||
\\
|
||||
\\For more informations: https://mrbounty.github.io/ZipponDB/cli
|
||||
|
@ -1,12 +1,13 @@
|
||||
User (
|
||||
name: str,
|
||||
email: str,
|
||||
orders: []Order,
|
||||
)
|
||||
|
||||
Order (
|
||||
items: []Item,
|
||||
quantity: []int,
|
||||
at: datetime,
|
||||
from: User,
|
||||
)
|
||||
|
||||
Item (
|
||||
|
11
schema/test
Normal file
11
schema/test
Normal file
@ -0,0 +1,11 @@
|
||||
User (
|
||||
name: str,
|
||||
age: int,
|
||||
email: str,
|
||||
bday: date,
|
||||
last_order: datetime,
|
||||
a_time: time,
|
||||
scores: []int,
|
||||
best_friend: User,
|
||||
friends: []User,
|
||||
)
|
Loading…
x
Reference in New Issue
Block a user