mirror of
https://github.com/aljazceru/turso.git
synced 2026-01-04 00:44:19 +01:00
Better support for BLOBs
- Limbo command line shell supports e.g. `SELECT x'616263';` - `EXPLAIN SELECT x'616263';` lists the opcode Missing: - Command line shell not entirely compatible with SQLite when blobs have non-printable characters in the middle (e.g. `SELECT x'610062';`) - Python bindings not supported (incoming soon)
This commit is contained in:
@@ -275,7 +275,9 @@ fn query(
|
||||
Value::Integer(i) => print!("{}", i),
|
||||
Value::Float(f) => print!("{:?}", f),
|
||||
Value::Text(s) => print!("{}", s),
|
||||
Value::Blob(b) => print!("{:?}", b),
|
||||
Value::Blob(b) => {
|
||||
print!("{}", String::from_utf8_lossy(b))
|
||||
}
|
||||
}
|
||||
}
|
||||
println!();
|
||||
@@ -305,7 +307,9 @@ fn query(
|
||||
Value::Integer(i) => i.to_string().cell(),
|
||||
Value::Float(f) => f.to_string().cell(),
|
||||
Value::Text(s) => s.cell(),
|
||||
Value::Blob(b) => format!("{:?}", b).cell(),
|
||||
Value::Blob(b) => {
|
||||
format!("{}", String::from_utf8_lossy(b)).cell()
|
||||
}
|
||||
})
|
||||
.collect(),
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user