您好,欢迎来到三六零分类信息网!老站,搜索引擎当天收录,欢迎发信息

CodeIgniter 数据库操作 -- 增删改查

2024/12/28 6:40:06发布22次查看
1、获取一个表的全部数据 $this-db-get('mytable'); // produces: select * from mytable 第二和第三个参数允许你设置一个结果集每页纪录数(limit)和结果集的偏移(offset) $query = $this-db-get('mytable', 10, 20); // produces: select * from mytable li
1、获取一个表的全部数据
$this->db->get('mytable');
// produces: select * from mytable
第二和第三个参数允许你设置一个结果集每页纪录数(limit)和结果集的偏移(offset)
$query = $this->db->get('mytable', 10, 20);
// produces: select * from mytable limit 20, 10
设置要查询的字段
$this->db->select('title, content, date');
$query = $this->db->get('mytable');
// produces: select title, content, date from mytable
该用户其它信息

VIP推荐

免费发布信息,免费发布B2B信息网站平台 - 三六零分类信息网 沪ICP备09012988号-2
企业名录 Product