ɾ��������
| 126 | |
| 127 | // ɾ�������� |
| 128 | static bool tbl_delete(acl::db_handle& db, int n) |
| 129 | { |
| 130 | const char* sql_fmt = "delete from group_tbl where group_name='���-%d'"; |
| 131 | |
| 132 | acl::string sql; |
| 133 | sql.format(sql_fmt, n); |
| 134 | |
| 135 | if (db.sql_update(sql.c_str()) == false) |
| 136 | { |
| 137 | printf("delete sql error\r\n"); |
| 138 | return (false); |
| 139 | } |
| 140 | |
| 141 | for (size_t i = 0; i < db.length(); i++) |
| 142 | { |
| 143 | const acl::db_row* row = db[i]; |
| 144 | for (size_t j = 0; j < row->length(); j++) |
| 145 | printf("%s, ", (*row)[j]); |
| 146 | printf("\r\n"); |
| 147 | } |
| 148 | // �ͷŲ�ѯ��� |
| 149 | db.free_result(); |
| 150 | |
| 151 | return (true); |
| 152 | } |
| 153 | |
| 154 | class db_thread : public acl::thread |
| 155 | { |
no test coverage detected
searching dependent graphs…