SQL to SequoiaDB shell to C
SequoiaDB 巨杉数据库的查询用 json(bson)对象表示,下表以示例的形式展示 SQL 语句、SDB Shell 语句和 SequoiaDB C 驱动程序语法之间的对照。
SQL
SDB Shell
C Driver
insert into employee( a, b ) values( 1, -1 )
db.sample.employee.insert( { a: 1, b: -1 } )
const char *r = "{ a: 1, b: -1 }" ; jsonToBson ( &obj, r ); sdbInsert( collection, &obj );
select a,b from employee
db.sample.employee.find( null, { a: "", b
文档