I've got a SQLite database. I'd like to create a field and declare it as type Byte array but I don't know what SQLite calls something that would be of type Byte Array. How would I do this?
我有一个SQLite数据库。我想创建一个字段并将其声明为类型字节数组,但我不知道SQLite调用的是Byte Array类型的东西。我该怎么办?
2 个解决方案
#1
42
You're looking for BLOB.
你在寻找BLOB。
From the webpage:
来自网页:
BLOB - The value is a blob of data, stored exactly as it was input.
BLOB - 该值是一个数据块,与输入完全一样。
Here's an example of making a table with two columns - an id and some data, which is a BLOB:
这是一个使用两列创建表的示例 - 一个id和一些数据,这是一个BLOB:
CREATE TABLE t1 (id INTEGER PRIMARY KEY, data BLOB);
#2
2
To add an info - official is BLOB, but when building SQLite DB is Visual studio, use type "image" which is the alias for BLOB
添加信息 - 官方是BLOB,但是当构建SQLite DB是Visual Studio时,使用类型“image”这是BLOB的别名
#1
42
You're looking for BLOB.
你在寻找BLOB。
From the webpage:
来自网页:
BLOB - The value is a blob of data, stored exactly as it was input.
BLOB - 该值是一个数据块,与输入完全一样。
Here's an example of making a table with two columns - an id and some data, which is a BLOB:
这是一个使用两列创建表的示例 - 一个id和一些数据,这是一个BLOB:
CREATE TABLE t1 (id INTEGER PRIMARY KEY, data BLOB);
#2
2
To add an info - official is BLOB, but when building SQLite DB is Visual studio, use type "image" which is the alias for BLOB
添加信息 - 官方是BLOB,但是当构建SQLite DB是Visual Studio时,使用类型“image”这是BLOB的别名