diff --git a/.cursor/debug.log b/.cursor/debug.log index a8d9937..b687010 100644 --- a/.cursor/debug.log +++ b/.cursor/debug.log @@ -1,392 +1,181 @@ -{"data":null,"hypothesisId":"START","location":"main.go:35","message":"开始 HoTimeDB 全功能测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029763643} -{"data":null,"hypothesisId":"START","location":"main.go:35","message":"开始 HoTimeDB 全功能测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029768948} -{"data":null,"hypothesisId":"ALL_TESTS","location":"main.go:48","message":"开始所有测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776477} -{"data":null,"hypothesisId":"H1_CRUD","location":"main.go:103","message":"开始基础 CRUD 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776477} -{"data":{"success":false,"userId":0},"hypothesisId":"H1_INSERT","location":"main.go:118","message":"Insert 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776494} -{"data":{"success":false,"user":null},"hypothesisId":"H1_GET","location":"main.go:126","message":"Get 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776497} -{"data":{"count":0},"hypothesisId":"H1_SELECT1","location":"main.go:134","message":"Select 单条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776502} -{"data":{"count":0,"query":"SELECT * FROM `user` WHERE `age` \u003c? AND `age` \u003e? AND `status` =? ORDER BY id DESC LIMIT 5 ;"},"hypothesisId":"H1_SELECT2","location":"main.go:149","message":"Select 多条件自动AND测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776507} -{"data":{"affected":0},"hypothesisId":"H1_UPDATE","location":"main.go:160","message":"Update 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776510} -{"data":{"affected":0},"hypothesisId":"H1_DELETE","location":"main.go:175","message":"Delete 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776522} -{"data":null,"hypothesisId":"H2_CONDITION","location":"main.go:188","message":"开始条件查询语法测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776522} -{"data":{"count":0},"hypothesisId":"H2_EQUAL","location":"main.go:195","message":"等于条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776527} -{"data":{"count":0,"query":"SELECT id,name,status FROM `user` WHERE `status` !=? LIMIT 3 ;"},"hypothesisId":"H2_NOT_EQUAL","location":"main.go:204","message":"不等于条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776531} -{"data":{"count":0},"hypothesisId":"H2_GREATER_LESS","location":"main.go:216","message":"大于小于条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776534} -{"data":{"count":0},"hypothesisId":"H2_GTE_LTE","location":"main.go:228","message":"大于等于小于等于条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776538} -{"data":{"count":0,"query":"SELECT id,name FROM `user` WHERE `name` LIKE ? LIMIT 3 ;"},"hypothesisId":"H2_LIKE","location":"main.go:237","message":"LIKE 模糊查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776542} -{"data":{"count":0},"hypothesisId":"H2_LIKE_RIGHT","location":"main.go:245","message":"右模糊查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776547} -{"data":{"count":0,"query":"SELECT id,name,age FROM `user` WHERE `age` BETWEEN ? AND ? LIMIT 3 ;"},"hypothesisId":"H2_BETWEEN","location":"main.go:254","message":"BETWEEN 区间查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776552} -{"data":{"count":0},"hypothesisId":"H2_NOT_BETWEEN","location":"main.go:262","message":"NOT BETWEEN 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776558} -{"data":{"count":0,"query":"SELECT id,name FROM `user` WHERE (`id` BETWEEN ? AND ? ) LIMIT 5 ;"},"hypothesisId":"H2_IN","location":"main.go:271","message":"IN 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776564} -{"data":{"count":0},"hypothesisId":"H2_NOT_IN","location":"main.go:279","message":"NOT IN 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776573} -{"data":{"count":0},"hypothesisId":"H2_IS_NULL","location":"main.go:287","message":"IS NULL 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776577} -{"data":{"count":0},"hypothesisId":"H2_IS_NOT_NULL","location":"main.go:295","message":"IS NOT NULL 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776581} -{"data":{"count":0,"query":"SELECT id,name,created_time FROM `user` WHERE `created_time` =\u003e DATE_SUB(NOW(), INTERVAL 365 DAY) LIMIT 3 ;"},"hypothesisId":"H2_RAW_SQL","location":"main.go:307","message":"直接 SQL 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776586} -{"data":{"count":0},"hypothesisId":"H2_EXPLICIT_AND","location":"main.go:321","message":"显式 AND 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776589} -{"data":{"count":0},"hypothesisId":"H2_OR","location":"main.go:335","message":"OR 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776595} -{"data":{"count":0,"query":"SELECT id,name,age,level FROM `user` WHERE ( `age` \u003c? OR `level` =? ) AND `status` =? LIMIT 5 ;"},"hypothesisId":"H2_NESTED","location":"main.go:353","message":"嵌套 AND/OR 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776600} -{"data":null,"hypothesisId":"H3_CHAIN","location":"main.go:366","message":"开始链式查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776600} -{"data":{"count":0},"hypothesisId":"H3_BASIC","location":"main.go:375","message":"基本链式查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776605} -{"data":{"count":0},"hypothesisId":"H3_AND","location":"main.go:387","message":"链式 And 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776609} -{"data":{"count":0},"hypothesisId":"H3_OR","location":"main.go:401","message":"链式 Or 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776613} -{"data":{"count":0},"hypothesisId":"H3_ORDER","location":"main.go:413","message":"链式 Order 排序测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776618} -{"data":{"count":0},"hypothesisId":"H3_LIMIT","location":"main.go:424","message":"链式 Limit 限制测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776623} -{"data":{"user":null},"hypothesisId":"H3_GET","location":"main.go:434","message":"链式 Get 获取单条测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776628} -{"data":{"count":0},"hypothesisId":"H3_COUNT","location":"main.go:444","message":"链式 Count 统计测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776632} -{"data":{"count":0},"hypothesisId":"H3_PAGE","location":"main.go:455","message":"链式 Page 分页测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776639} -{"data":{"stats":[]},"hypothesisId":"H3_GROUP","location":"main.go:466","message":"链式 Group 分组测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776643} -{"data":{"name":"链式 Update 更新","note":"无可用测试数据","result":true},"hypothesisId":"H3_UPDATE","location":"main.go:483","message":"链式 Update 更新测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776647} -{"data":null,"hypothesisId":"H4_JOIN","location":"main.go:496","message":"开始 JOIN 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776647} -{"data":{"count":0},"hypothesisId":"H4_LEFT_JOIN","location":"main.go:508","message":"LEFT JOIN 链式查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776653} -{"data":{"count":0,"query":"SELECT app_order.id, app_order.amount, app_user.name as user_name FROM `order` LEFT JOIN `user` ON app_order.user_id = app_user.id WHERE app_order.status=? LIMIT 5 ;"},"hypothesisId":"H4_TRADITIONAL_JOIN","location":"main.go:525","message":"传统 JOIN 语法测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776657} -{"data":{"count":0},"hypothesisId":"H4_MULTI_JOIN","location":"main.go:539","message":"多表 JOIN 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776662} -{"data":{"count":0},"hypothesisId":"H4_INNER_JOIN","location":"main.go:551","message":"INNER JOIN 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776665} -{"data":null,"hypothesisId":"H5_AGGREGATE","location":"main.go:564","message":"开始聚合函数测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776665} -{"data":{"count":0},"hypothesisId":"H5_COUNT","location":"main.go:571","message":"Count 总数统计测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776672} -{"data":{"count":0},"hypothesisId":"H5_COUNT_WHERE","location":"main.go:579","message":"Count 条件统计测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776676} -{"data":{"sum":0},"hypothesisId":"H5_SUM","location":"main.go:587","message":"Sum 求和测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776684} -{"data":{"avg":0},"hypothesisId":"H5_AVG","location":"main.go:595","message":"Avg 平均值测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776689} -{"data":{"max":0},"hypothesisId":"H5_MAX","location":"main.go:603","message":"Max 最大值测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776696} -{"data":{"min":0},"hypothesisId":"H5_MIN","location":"main.go:611","message":"Min 最小值测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776699} -{"data":{"stats":[]},"hypothesisId":"H5_GROUP_BY","location":"main.go:625","message":"GROUP BY 分组统计测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776705} -{"data":null,"hypothesisId":"H6_PAGINATION","location":"main.go:638","message":"开始分页查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776705} -{"data":{"count":0},"hypothesisId":"H6_PAGE_SELECT","location":"main.go:648","message":"PageSelect 分页查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776713} -{"data":{"count":0},"hypothesisId":"H6_PAGE_2","location":"main.go:659","message":"PageSelect 第二页测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776721} -{"data":{"count":0},"hypothesisId":"H6_CHAIN_PAGE","location":"main.go:671","message":"链式 Page 分页测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776727} -{"data":{"count":0,"query":"SELECT `id,name` FROM `user` WHERE `status` =? LIMIT 3 OFFSET 2 ;"},"hypothesisId":"H6_OFFSET","location":"main.go:684","message":"Offset 偏移查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776734} -{"data":null,"hypothesisId":"H7_BATCH","location":"main.go:697","message":"开始批量插入测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776735} -{"data":{"affected":0,"query":"INSERT INTO `user_batch` (`email`, `name`, `status`) VALUES (?, ?, ?), (?, ?, ?), (?, ?, ?)"},"hypothesisId":"H7_BATCH_INSERT","location":"main.go:710","message":"BatchInsert 批量插入测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776740} -{"data":{"affected":0},"hypothesisId":"H7_BATCH_RAW","location":"main.go:722","message":"BatchInsert 带 [#] 标记测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776746} -{"data":null,"hypothesisId":"H8_UPSERT","location":"main.go:739","message":"开始 Upsert 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776758} -{"data":{"affected":0,"query":"INSERT INTO `user` (`name`, `email`, `age`, `status`, `level`, `balance`, `created_time`) VALUES (?, ?, ?, ?, ?, ?, NOW()) ON DUPLICATE KEY UPDATE `name` = VALUES(`name`), `age` = VALUES(`age`), `status` = VALUES(`status`), `level` = VALUES(`level`), `balance` = VALUES(`balance`)"},"hypothesisId":"H8_UPSERT_INSERT","location":"main.go:763","message":"Upsert 插入新记录测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776763} -{"data":{"affected":0},"hypothesisId":"H8_UPSERT_UPDATE","location":"main.go:783","message":"Upsert 更新已存在记录测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776769} -{"data":null,"hypothesisId":"H9_TRANSACTION","location":"main.go:803","message":"开始事务测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776781} -{"data":{"userId":0},"hypothesisId":"H9_TX_INSERT","location":"main.go:818","message":"事务内插入用户","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776805} -{"data":{"success":false,"userExists":false},"hypothesisId":"H9_TX_SUCCESS","location":"main.go:831","message":"事务成功提交测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776812} -{"data":{"userId":0},"hypothesisId":"H9_TX_ROLLBACK_INSERT","location":"main.go:846","message":"事务内插入(将回滚)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776817} -{"data":{"rolledBack":true,"success":false},"hypothesisId":"H9_TX_ROLLBACK","location":"main.go:856","message":"事务回滚测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776822} -{"data":null,"hypothesisId":"H10_RAW_SQL","location":"main.go:872","message":"开始原生 SQL 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776825} -{"data":{"count":0},"hypothesisId":"H10_QUERY","location":"main.go:879","message":"Query 原生查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776830} -{"data":{"name":"Exec 原生执行","note":"无可用测试数据","result":true},"hypothesisId":"H10_EXEC","location":"main.go:899","message":"Exec 原生执行测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776833} -{"data":{"10_raw_sql":{"name":"原生SQL测试","success":true,"tests":[{"count":0,"name":"Query 原生查询","result":true},{"name":"Exec 原生执行","note":"无可用测试数据","result":true}]},"1_basic_crud":{"name":"基础CRUD测试","success":true,"tests":[{"lastQuery":"INSERT INTO `user` (`email`,`age`,`status`,`balance`,`level`,`created_time`,`name`) VALUES (?,?,?,?,?,NOW(),?);","name":"Insert 插入测试","result":false,"userId":0},{"name":"Get 获取单条记录测试","result":false,"user":null},{"count":0,"name":"Select 单条件查询测试","result":false},{"count":0,"lastQuery":"SELECT * FROM `user` WHERE `age` \u003c? AND `age` \u003e? AND `status` =? ORDER BY id DESC LIMIT 5 ;","name":"Select 多条件自动AND测试","result":true},{"affected":0,"name":"Update 更新测试","result":false},{"affected":0,"name":"Delete 删除测试","result":false}]},"2_condition_syntax":{"name":"条件查询语法测试","success":true,"tests":[{"count":0,"name":"等于条件 (=)","result":true},{"count":0,"lastQuery":"SELECT id,name,status FROM `user` WHERE `status` !=? LIMIT 3 ;","name":"不等于条件 ([!])","result":true},{"count":0,"name":"大于小于条件 ([\u003e], [\u003c])","result":true},{"count":0,"name":"大于等于小于等于条件 ([\u003e=], [\u003c=])","result":true},{"count":0,"lastQuery":"SELECT id,name FROM `user` WHERE `name` LIKE ? LIMIT 3 ;","name":"LIKE 模糊查询 ([~])","result":true},{"count":0,"name":"右模糊查询 ([~!])","result":true},{"count":0,"lastQuery":"SELECT id,name,age FROM `user` WHERE `age` BETWEEN ? AND ? LIMIT 3 ;","name":"BETWEEN 区间查询 ([\u003c\u003e])","result":true},{"count":0,"name":"NOT BETWEEN 查询 ([\u003e\u003c])","result":true},{"count":0,"lastQuery":"SELECT id,name FROM `user` WHERE (`id` BETWEEN ? AND ? ) LIMIT 5 ;","name":"IN 查询","result":true},{"count":0,"name":"NOT IN 查询 ([!])","result":true},{"count":0,"name":"IS NULL 查询","result":true},{"count":0,"name":"IS NOT NULL 查询 ([!])","result":true},{"count":0,"lastQuery":"SELECT id,name,created_time FROM `user` WHERE `created_time` =\u003e DATE_SUB(NOW(), INTERVAL 365 DAY) LIMIT 3 ;","name":"直接 SQL 查询 ([#])","result":true},{"count":0,"name":"显式 AND 条件","result":true},{"count":0,"name":"OR 条件","result":true},{"count":0,"lastQuery":"SELECT id,name,age,level FROM `user` WHERE ( `age` \u003c? OR `level` =? ) AND `status` =? LIMIT 5 ;","name":"嵌套 AND/OR 条件","result":true}]},"3_chain_query":{"name":"链式查询测试","success":true,"tests":[{"count":0,"name":"基本链式查询 Table().Where().Select()","result":true},{"count":0,"name":"链式 And 条件","result":true},{"count":0,"name":"链式 Or 条件","result":true},{"count":0,"name":"链式 Order 排序","result":true},{"count":0,"name":"链式 Limit 限制","result":true},{"name":"链式 Get 获取单条","result":false,"user":null},{"count":0,"name":"链式 Count 统计","result":true},{"count":0,"name":"链式 Page 分页","result":true},{"name":"链式 Group 分组","result":true,"stats":[]},{"name":"链式 Update 更新","note":"无可用测试数据","result":true}]},"4_join_query":{"name":"JOIN查询测试","success":true,"tests":[{"count":0,"data":[],"name":"LEFT JOIN 链式查询","result":true},{"count":0,"lastQuery":"SELECT app_order.id, app_order.amount, app_user.name as user_name FROM `order` LEFT JOIN `user` ON app_order.user_id = app_user.id WHERE app_order.status=? LIMIT 5 ;","name":"传统 JOIN 语法","result":true},{"count":0,"data":[],"name":"多表 JOIN","result":true},{"count":0,"name":"INNER JOIN","result":true}]},"5_aggregate":{"name":"聚合函数测试","success":true,"tests":[{"count":0,"name":"Count 总数统计","result":true},{"count":0,"name":"Count 条件统计","result":true},{"name":"Sum 求和","result":true,"sum":0},{"avg":0,"name":"Avg 平均值","result":true},{"max":0,"name":"Max 最大值","result":true},{"min":0,"name":"Min 最小值","result":true},{"name":"GROUP BY 分组统计","result":true,"stats":[]}]},"6_pagination":{"name":"分页查询测试","success":true,"tests":[{"count":0,"name":"PageSelect 分页查询","result":true},{"count":0,"name":"PageSelect 第二页","result":true},{"count":0,"name":"链式 Page 分页","result":true},{"count":0,"lastQuery":"SELECT `id,name` FROM `user` WHERE `status` =? LIMIT 3 OFFSET 2 ;","name":"Offset 偏移查询","result":true}]},"7_batch_insert":{"name":"批量插入测试","success":true,"tests":[{"affected":0,"lastQuery":"INSERT INTO `user_batch` (`email`, `name`, `status`) VALUES (?, ?, ?), (?, ?, ?), (?, ?, ?)","name":"BatchInsert 批量插入","result":true},{"affected":0,"name":"BatchInsert 带 [#] 标记","result":true}]},"8_upsert":{"name":"Upsert测试","success":true,"tests":[{"affected":0,"lastQuery":"INSERT INTO `user` (`name`, `email`, `age`, `status`, `level`, `balance`, `created_time`) VALUES (?, ?, ?, ?, ?, ?, NOW()) ON DUPLICATE KEY UPDATE `name` = VALUES(`name`), `age` = VALUES(`age`), `status` = VALUES(`status`), `level` = VALUES(`level`), `balance` = VALUES(`balance`)","name":"Upsert 插入新记录","result":true},{"affected":0,"name":"Upsert 更新已存在记录","result":true,"updatedUser":null}]},"9_transaction":{"name":"事务测试","success":true,"tests":[{"name":"事务成功提交","result":false,"userExists":false},{"name":"事务回滚","result":true,"userRolledBack":true}]}},"hypothesisId":"ALL_TESTS_DONE","location":"main.go:80","message":"所有测试完成","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029776833} -{"data":null,"hypothesisId":"START","location":"main.go:35","message":"开始 HoTimeDB 全功能测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029852175} -{"data":null,"hypothesisId":"START","location":"main.go:35","message":"开始 HoTimeDB 全功能测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029941589} -{"data":null,"hypothesisId":"START","location":"main.go:35","message":"开始 HoTimeDB 全功能测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769029945151} -{"data":null,"hypothesisId":"START","location":"main.go:35","message":"开始 HoTimeDB 全功能测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030041708} -{"data":null,"hypothesisId":"START","location":"main.go:35","message":"开始 HoTimeDB 全功能测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030072829} -{"data":null,"hypothesisId":"START","location":"main.go:35","message":"开始 HoTimeDB 全功能测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030113956} -{"data":null,"hypothesisId":"ALL_TESTS","location":"main.go:48","message":"开始所有测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121459} -{"data":{"userCount":5},"hypothesisId":"INIT","location":"main.go:init","message":"测试表初始化完成","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121502} -{"data":null,"hypothesisId":"H1_CRUD","location":"main.go:103","message":"开始基础 CRUD 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121503} -{"data":{"success":false,"userId":0},"hypothesisId":"H1_INSERT","location":"main.go:118","message":"Insert 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121503} -{"data":{"success":false,"user":null},"hypothesisId":"H1_GET","location":"main.go:126","message":"Get 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121503} -{"data":{"count":4},"hypothesisId":"H1_SELECT1","location":"main.go:134","message":"Select 单条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121504} -{"data":{"count":4,"query":"SELECT * FROM `user` WHERE `age` \u003c? AND `age` \u003e? AND `status` =? ORDER BY id DESC LIMIT 5 ;"},"hypothesisId":"H1_SELECT2","location":"main.go:149","message":"Select 多条件自动AND测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121504} -{"data":{"affected":0},"hypothesisId":"H1_UPDATE","location":"main.go:160","message":"Update 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121504} -{"data":{"affected":0},"hypothesisId":"H1_DELETE","location":"main.go:175","message":"Delete 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121505} -{"data":null,"hypothesisId":"H2_CONDITION","location":"main.go:188","message":"开始条件查询语法测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121505} -{"data":{"count":3},"hypothesisId":"H2_EQUAL","location":"main.go:195","message":"等于条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121505} -{"data":{"count":3,"query":"SELECT id,name,status FROM `user` WHERE `status` !=? LIMIT 3 ;"},"hypothesisId":"H2_NOT_EQUAL","location":"main.go:204","message":"不等于条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121506} -{"data":{"count":3},"hypothesisId":"H2_GREATER_LESS","location":"main.go:216","message":"大于小于条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121506} -{"data":{"count":3},"hypothesisId":"H2_GTE_LTE","location":"main.go:228","message":"大于等于小于等于条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121506} -{"data":{"count":1,"query":"SELECT id,name FROM `user` WHERE `name` LIKE ? LIMIT 3 ;"},"hypothesisId":"H2_LIKE","location":"main.go:237","message":"LIKE 模糊查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121507} -{"data":{"count":0},"hypothesisId":"H2_LIKE_RIGHT","location":"main.go:245","message":"右模糊查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121508} -{"data":{"count":3,"query":"SELECT id,name,age FROM `user` WHERE `age` BETWEEN ? AND ? LIMIT 3 ;"},"hypothesisId":"H2_BETWEEN","location":"main.go:254","message":"BETWEEN 区间查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121508} -{"data":{"count":3},"hypothesisId":"H2_NOT_BETWEEN","location":"main.go:262","message":"NOT BETWEEN 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121509} -{"data":{"count":5,"query":"SELECT id,name FROM `user` WHERE (`id` BETWEEN ? AND ? ) LIMIT 5 ;"},"hypothesisId":"H2_IN","location":"main.go:271","message":"IN 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121509} -{"data":{"count":2},"hypothesisId":"H2_NOT_IN","location":"main.go:279","message":"NOT IN 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121509} -{"data":{"count":3},"hypothesisId":"H2_IS_NULL","location":"main.go:287","message":"IS NULL 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121509} -{"data":{"count":0},"hypothesisId":"H2_IS_NOT_NULL","location":"main.go:295","message":"IS NOT NULL 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121510} -{"data":{"count":0,"query":"SELECT id,name,created_time FROM `user` WHERE `[##]` =? LIMIT 3 ;"},"hypothesisId":"H2_RAW_SQL","location":"main.go:307","message":"直接 SQL 片段查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121510} -{"data":{"count":3},"hypothesisId":"H2_EXPLICIT_AND","location":"main.go:321","message":"显式 AND 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121511} -{"data":{"count":3},"hypothesisId":"H2_OR","location":"main.go:335","message":"OR 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121511} -{"data":{"count":3,"query":"SELECT id,name,age,level FROM `user` WHERE ( `age` \u003c? OR `level` =? ) AND `status` =? LIMIT 5 ;"},"hypothesisId":"H2_NESTED","location":"main.go:353","message":"嵌套 AND/OR 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121511} -{"data":null,"hypothesisId":"H3_CHAIN","location":"main.go:366","message":"开始链式查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121511} -{"data":{"count":0},"hypothesisId":"H3_BASIC","location":"main.go:375","message":"基本链式查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121512} -{"data":{"count":0},"hypothesisId":"H3_AND","location":"main.go:387","message":"链式 And 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121512} -{"data":{"count":0},"hypothesisId":"H3_OR","location":"main.go:401","message":"链式 Or 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121513} -{"data":{"count":0},"hypothesisId":"H3_ORDER","location":"main.go:413","message":"链式 Order 排序测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121513} -{"data":{"count":0},"hypothesisId":"H3_LIMIT","location":"main.go:424","message":"链式 Limit 限制测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121514} -{"data":{"user":null},"hypothesisId":"H3_GET","location":"main.go:434","message":"链式 Get 获取单条测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121514} -{"data":{"count":4},"hypothesisId":"H3_COUNT","location":"main.go:444","message":"链式 Count 统计测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121515} -{"data":{"count":0},"hypothesisId":"H3_PAGE","location":"main.go:455","message":"链式 Page 分页测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121515} -{"data":{"stats":[]},"hypothesisId":"H3_GROUP","location":"main.go:466","message":"链式 Group 分组测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121515} -{"data":{"affected":0,"name":"链式 Update 更新","result":true},"hypothesisId":"H3_UPDATE","location":"main.go:483","message":"链式 Update 更新测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121516} -{"data":null,"hypothesisId":"H4_JOIN","location":"main.go:496","message":"开始 JOIN 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121516} -{"data":{"count":0},"hypothesisId":"H4_LEFT_JOIN","location":"main.go:508","message":"LEFT JOIN 链式查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121516} -{"data":{"count":0,"query":"SELECT app_order.id, app_order.amount, app_user.name as user_name FROM `order` LEFT JOIN `user` ON app_order.user_id = app_user.id WHERE app_order.status=? LIMIT 5 ;"},"hypothesisId":"H4_TRADITIONAL_JOIN","location":"main.go:525","message":"传统 JOIN 语法测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121516} -{"data":{"count":0},"hypothesisId":"H4_MULTI_JOIN","location":"main.go:539","message":"多表 JOIN 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121518} -{"data":{"count":0},"hypothesisId":"H4_INNER_JOIN","location":"main.go:551","message":"INNER JOIN 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121518} -{"data":null,"hypothesisId":"H5_AGGREGATE","location":"main.go:564","message":"开始聚合函数测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121518} -{"data":{"count":5},"hypothesisId":"H5_COUNT","location":"main.go:571","message":"Count 总数统计测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121519} -{"data":{"count":4},"hypothesisId":"H5_COUNT_WHERE","location":"main.go:579","message":"Count 条件统计测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121519} -{"data":{"sum":16500},"hypothesisId":"H5_SUM","location":"main.go:587","message":"Sum 求和测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121519} -{"data":{"avg":29.5},"hypothesisId":"H5_AVG","location":"main.go:595","message":"Avg 平均值测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121520} -{"data":{"max":35},"hypothesisId":"H5_MAX","location":"main.go:603","message":"Max 最大值测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121520} -{"data":{"min":25},"hypothesisId":"H5_MIN","location":"main.go:611","message":"Min 最小值测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121520} -{"data":{"stats":[{"avg_age":30,"level":"normal","total_balance":1500,"user_count":2},{"avg_age":30,"level":"vip","total_balance":5000,"user_count":1},{"avg_age":28,"level":"svip","total_balance":10000,"user_count":1}]},"hypothesisId":"H5_GROUP_BY","location":"main.go:625","message":"GROUP BY 分组统计测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121521} -{"data":null,"hypothesisId":"H6_PAGINATION","location":"main.go:638","message":"开始分页查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121521} -{"data":{"count":4},"hypothesisId":"H6_PAGE_SELECT","location":"main.go:648","message":"PageSelect 分页查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121522} -{"data":{"count":0},"hypothesisId":"H6_PAGE_2","location":"main.go:659","message":"PageSelect 第二页测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121522} -{"data":{"count":0},"hypothesisId":"H6_CHAIN_PAGE","location":"main.go:671","message":"链式 Page 分页测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121522} -{"data":{"count":0,"query":"SELECT `id,name` FROM `user` WHERE `status` =? LIMIT 3 OFFSET 2 ;"},"hypothesisId":"H6_OFFSET","location":"main.go:684","message":"Offset 偏移查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121523} -{"data":null,"hypothesisId":"H7_BATCH","location":"main.go:697","message":"开始批量插入测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121523} -{"data":{"affected":3,"query":"INSERT INTO `user_batch` (`email`, `name`, `status`) VALUES (?, ?, ?), (?, ?, ?), (?, ?, ?)"},"hypothesisId":"H7_BATCH_INSERT","location":"main.go:710","message":"BatchInsert 批量插入测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121526} -{"data":{"affected":0},"hypothesisId":"H7_BATCH_RAW","location":"main.go:722","message":"BatchInsert 带 [#] 标记测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121526} -{"data":null,"hypothesisId":"H8_UPSERT","location":"main.go:739","message":"开始 Upsert 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121530} -{"data":{"affected":0,"query":"INSERT INTO \"user\" (\"age\", \"status\", \"level\", \"balance\", \"created_time\", \"name\", \"email\") VALUES (?, ?, ?, ?, NOW(), ?, ?) ON CONFLICT (\"email\") DO UPDATE SET \"name\" = excluded.\"name\", \"age\" = excluded.\"age\", \"status\" = excluded.\"status\", \"level\" = excluded.\"level\", \"balance\" = excluded.\"balance\""},"hypothesisId":"H8_UPSERT_INSERT","location":"main.go:763","message":"Upsert 插入新记录测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121531} -{"data":{"affected":0},"hypothesisId":"H8_UPSERT_UPDATE","location":"main.go:783","message":"Upsert 更新已存在记录测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121531} -{"data":null,"hypothesisId":"H9_TRANSACTION","location":"main.go:803","message":"开始事务测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121531} -{"data":{"userId":0},"hypothesisId":"H9_TX_INSERT","location":"main.go:818","message":"事务内插入用户","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121532} -{"data":{"success":false,"userExists":false},"hypothesisId":"H9_TX_SUCCESS","location":"main.go:831","message":"事务成功提交测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121533} -{"data":{"userId":0},"hypothesisId":"H9_TX_ROLLBACK_INSERT","location":"main.go:846","message":"事务内插入(将回滚)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121533} -{"data":{"rolledBack":true,"success":false},"hypothesisId":"H9_TX_ROLLBACK","location":"main.go:856","message":"事务回滚测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121533} -{"data":null,"hypothesisId":"H10_RAW_SQL","location":"main.go:872","message":"开始原生 SQL 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121534} -{"data":{"count":0},"hypothesisId":"H10_QUERY","location":"main.go:879","message":"Query 原生查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121535} -{"data":{"error":{"Code":1,"ExtendedCode":1,"SystemErrno":0},"name":"Exec 原生执行","result":false},"hypothesisId":"H10_EXEC","location":"main.go:899","message":"Exec 原生执行测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121536} -{"data":{"10_raw_sql":{"name":"原生SQL测试","success":true,"tests":[{"count":0,"name":"Query 原生查询","result":true},{"error":{"Code":1,"ExtendedCode":1,"SystemErrno":0},"name":"Exec 原生执行","result":false}]},"1_basic_crud":{"name":"基础CRUD测试","success":true,"tests":[{"lastQuery":"INSERT INTO `user` (`name`,`email`,`age`,`status`,`balance`,`level`,`created_time`) VALUES (?,?,?,?,?,?,NOW());","name":"Insert 插入测试","result":false,"userId":0},{"name":"Get 获取单条记录测试","result":false,"user":null},{"count":4,"name":"Select 单条件查询测试","result":true},{"count":4,"lastQuery":"SELECT * FROM `user` WHERE `age` \u003c? AND `age` \u003e? AND `status` =? ORDER BY id DESC LIMIT 5 ;","name":"Select 多条件自动AND测试","result":true},{"affected":0,"name":"Update 更新测试","result":false},{"affected":0,"name":"Delete 删除测试","result":false}]},"2_condition_syntax":{"name":"条件查询语法测试","success":true,"tests":[{"count":3,"name":"等于条件 (=)","result":true},{"count":3,"lastQuery":"SELECT id,name,status FROM `user` WHERE `status` !=? LIMIT 3 ;","name":"不等于条件 ([!])","result":true},{"count":3,"name":"大于小于条件 ([\u003e], [\u003c])","result":true},{"count":3,"name":"大于等于小于等于条件 ([\u003e=], [\u003c=])","result":true},{"count":1,"lastQuery":"SELECT id,name FROM `user` WHERE `name` LIKE ? LIMIT 3 ;","name":"LIKE 模糊查询 ([~])","result":true},{"count":0,"name":"右模糊查询 ([~!])","result":true},{"count":3,"lastQuery":"SELECT id,name,age FROM `user` WHERE `age` BETWEEN ? AND ? LIMIT 3 ;","name":"BETWEEN 区间查询 ([\u003c\u003e])","result":true},{"count":3,"name":"NOT BETWEEN 查询 ([\u003e\u003c])","result":true},{"count":5,"lastQuery":"SELECT id,name FROM `user` WHERE (`id` BETWEEN ? AND ? ) LIMIT 5 ;","name":"IN 查询","result":true},{"count":2,"name":"NOT IN 查询 ([!])","result":true},{"count":3,"name":"IS NULL 查询","result":true},{"count":0,"name":"IS NOT NULL 查询 ([!])","result":true},{"count":0,"lastQuery":"SELECT id,name,created_time FROM `user` WHERE `[##]` =? LIMIT 3 ;","name":"直接 SQL 片段查询 ([##])","result":true},{"count":3,"name":"显式 AND 条件","result":true},{"count":3,"name":"OR 条件","result":true},{"count":3,"lastQuery":"SELECT id,name,age,level FROM `user` WHERE ( `age` \u003c? OR `level` =? ) AND `status` =? LIMIT 5 ;","name":"嵌套 AND/OR 条件","result":true}]},"3_chain_query":{"name":"链式查询测试","success":true,"tests":[{"count":0,"name":"基本链式查询 Table().Where().Select()","result":true},{"count":0,"name":"链式 And 条件","result":true},{"count":0,"name":"链式 Or 条件","result":true},{"count":0,"name":"链式 Order 排序","result":true},{"count":0,"name":"链式 Limit 限制","result":true},{"name":"链式 Get 获取单条","result":false,"user":null},{"count":4,"name":"链式 Count 统计","result":true},{"count":0,"name":"链式 Page 分页","result":true},{"name":"链式 Group 分组","result":true,"stats":[]},{"affected":0,"name":"链式 Update 更新","result":true}]},"4_join_query":{"name":"JOIN查询测试","success":true,"tests":[{"count":0,"data":[],"name":"LEFT JOIN 链式查询","result":true},{"count":0,"lastQuery":"SELECT app_order.id, app_order.amount, app_user.name as user_name FROM `order` LEFT JOIN `user` ON app_order.user_id = app_user.id WHERE app_order.status=? LIMIT 5 ;","name":"传统 JOIN 语法","result":true},{"count":0,"data":[],"name":"多表 JOIN","result":true},{"count":0,"name":"INNER JOIN","result":true}]},"5_aggregate":{"name":"聚合函数测试","success":true,"tests":[{"count":5,"name":"Count 总数统计","result":true},{"count":4,"name":"Count 条件统计","result":true},{"name":"Sum 求和","result":true,"sum":16500},{"avg":29.5,"name":"Avg 平均值","result":true},{"max":35,"name":"Max 最大值","result":true},{"min":25,"name":"Min 最小值","result":true},{"name":"GROUP BY 分组统计","result":true,"stats":[{"avg_age":30,"level":"normal","total_balance":1500,"user_count":2},{"avg_age":30,"level":"vip","total_balance":5000,"user_count":1},{"avg_age":28,"level":"svip","total_balance":10000,"user_count":1}]}]},"6_pagination":{"name":"分页查询测试","success":true,"tests":[{"count":4,"name":"PageSelect 分页查询","result":true},{"count":0,"name":"PageSelect 第二页","result":true},{"count":0,"name":"链式 Page 分页","result":true},{"count":0,"lastQuery":"SELECT `id,name` FROM `user` WHERE `status` =? LIMIT 3 OFFSET 2 ;","name":"Offset 偏移查询","result":true}]},"7_batch_insert":{"name":"批量插入测试","success":true,"tests":[{"affected":3,"lastQuery":"INSERT INTO `user_batch` (`email`, `name`, `status`) VALUES (?, ?, ?), (?, ?, ?), (?, ?, ?)","name":"BatchInsert 批量插入","result":true},{"affected":0,"name":"BatchInsert 带 [#] 标记","result":true}]},"8_upsert":{"name":"Upsert测试","success":true,"tests":[{"affected":0,"lastQuery":"INSERT INTO \"user\" (\"age\", \"status\", \"level\", \"balance\", \"created_time\", \"name\", \"email\") VALUES (?, ?, ?, ?, NOW(), ?, ?) ON CONFLICT (\"email\") DO UPDATE SET \"name\" = excluded.\"name\", \"age\" = excluded.\"age\", \"status\" = excluded.\"status\", \"level\" = excluded.\"level\", \"balance\" = excluded.\"balance\"","name":"Upsert 插入新记录","result":true},{"affected":0,"name":"Upsert 更新已存在记录","result":true,"updatedUser":null}]},"9_transaction":{"name":"事务测试","success":true,"tests":[{"name":"事务成功提交","result":false,"userExists":false},{"name":"事务回滚","result":true,"userRolledBack":true}]}},"hypothesisId":"ALL_TESTS_DONE","location":"main.go:80","message":"所有测试完成","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030121537} -{"data":null,"hypothesisId":"START","location":"main.go:35","message":"开始 HoTimeDB 全功能测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030276943} -{"data":null,"hypothesisId":"ALL_TESTS","location":"main.go:48","message":"开始所有测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279608} -{"data":{"userCount":5},"hypothesisId":"INIT","location":"main.go:init","message":"测试表初始化完成","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279609} -{"data":null,"hypothesisId":"H1_CRUD","location":"main.go:103","message":"开始基础 CRUD 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279610} -{"data":{"success":false,"userId":0},"hypothesisId":"H1_INSERT","location":"main.go:118","message":"Insert 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279610} -{"data":{"success":false,"user":null},"hypothesisId":"H1_GET","location":"main.go:126","message":"Get 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279611} -{"data":{"count":4},"hypothesisId":"H1_SELECT1","location":"main.go:134","message":"Select 单条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279611} -{"data":{"count":4,"query":"SELECT * FROM `user` WHERE `age` \u003c? AND `age` \u003e? AND `status` =? ORDER BY id DESC LIMIT 5 ;"},"hypothesisId":"H1_SELECT2","location":"main.go:149","message":"Select 多条件自动AND测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279611} -{"data":{"affected":0},"hypothesisId":"H1_UPDATE","location":"main.go:160","message":"Update 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279612} -{"data":{"affected":0},"hypothesisId":"H1_DELETE","location":"main.go:175","message":"Delete 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279612} -{"data":null,"hypothesisId":"H2_CONDITION","location":"main.go:188","message":"开始条件查询语法测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279612} -{"data":{"count":3},"hypothesisId":"H2_EQUAL","location":"main.go:195","message":"等于条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279613} -{"data":{"count":3,"query":"SELECT id,name,status FROM `user` WHERE `status` !=? LIMIT 3 ;"},"hypothesisId":"H2_NOT_EQUAL","location":"main.go:204","message":"不等于条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279613} -{"data":{"count":3},"hypothesisId":"H2_GREATER_LESS","location":"main.go:216","message":"大于小于条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279614} -{"data":{"count":3},"hypothesisId":"H2_GTE_LTE","location":"main.go:228","message":"大于等于小于等于条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279614} -{"data":{"count":1,"query":"SELECT id,name FROM `user` WHERE `name` LIKE ? LIMIT 3 ;"},"hypothesisId":"H2_LIKE","location":"main.go:237","message":"LIKE 模糊查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279614} -{"data":{"count":0},"hypothesisId":"H2_LIKE_RIGHT","location":"main.go:245","message":"右模糊查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279615} -{"data":{"count":3,"query":"SELECT id,name,age FROM `user` WHERE `age` BETWEEN ? AND ? LIMIT 3 ;"},"hypothesisId":"H2_BETWEEN","location":"main.go:254","message":"BETWEEN 区间查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279615} -{"data":{"count":3},"hypothesisId":"H2_NOT_BETWEEN","location":"main.go:262","message":"NOT BETWEEN 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279615} -{"data":{"count":5,"query":"SELECT id,name FROM `user` WHERE (`id` BETWEEN ? AND ? ) LIMIT 5 ;"},"hypothesisId":"H2_IN","location":"main.go:271","message":"IN 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279615} -{"data":{"count":2},"hypothesisId":"H2_NOT_IN","location":"main.go:279","message":"NOT IN 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279616} -{"data":{"count":3},"hypothesisId":"H2_IS_NULL","location":"main.go:287","message":"IS NULL 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279616} -{"data":{"count":0},"hypothesisId":"H2_IS_NOT_NULL","location":"main.go:295","message":"IS NOT NULL 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279616} -{"data":{"count":0,"query":"SELECT id,name,created_time FROM `user` WHERE created_time \u003e DATE_SUB(NOW(), INTERVAL 365 DAY) LIMIT 3 ;"},"hypothesisId":"H2_RAW_SQL","location":"main.go:307","message":"直接 SQL 片段查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279617} -{"data":{"count":3},"hypothesisId":"H2_EXPLICIT_AND","location":"main.go:321","message":"显式 AND 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279618} -{"data":{"count":3},"hypothesisId":"H2_OR","location":"main.go:335","message":"OR 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279618} -{"data":{"count":3,"query":"SELECT id,name,age,level FROM `user` WHERE ( `age` \u003c? OR `level` =? ) AND `status` =? LIMIT 5 ;"},"hypothesisId":"H2_NESTED","location":"main.go:353","message":"嵌套 AND/OR 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279618} -{"data":null,"hypothesisId":"H3_CHAIN","location":"main.go:366","message":"开始链式查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279618} -{"data":{"count":4},"hypothesisId":"H3_BASIC","location":"main.go:375","message":"基本链式查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279619} -{"data":{"count":4},"hypothesisId":"H3_AND","location":"main.go:387","message":"链式 And 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279619} -{"data":{"count":2},"hypothesisId":"H3_OR","location":"main.go:401","message":"链式 Or 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279619} -{"data":{"count":4},"hypothesisId":"H3_ORDER","location":"main.go:413","message":"链式 Order 排序测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279620} -{"data":{"count":3},"hypothesisId":"H3_LIMIT","location":"main.go:424","message":"链式 Limit 限制测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279620} -{"data":{"user":{"email":"zhangsan@example.com","id":1,"name":"张三"}},"hypothesisId":"H3_GET","location":"main.go:434","message":"链式 Get 获取单条测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279620} -{"data":{"count":4},"hypothesisId":"H3_COUNT","location":"main.go:444","message":"链式 Count 统计测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279621} -{"data":{"count":4},"hypothesisId":"H3_PAGE","location":"main.go:455","message":"链式 Page 分页测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279621} -{"data":{"stats":[{"cnt":2,"level":"normal"},{"cnt":1,"level":"svip"},{"cnt":1,"level":"vip"}]},"hypothesisId":"H3_GROUP","location":"main.go:466","message":"链式 Group 分组测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279621} -{"data":{"affected":0,"name":"链式 Update 更新","result":true},"hypothesisId":"H3_UPDATE","location":"main.go:483","message":"链式 Update 更新测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279622} -{"data":null,"hypothesisId":"H4_JOIN","location":"main.go:496","message":"开始 JOIN 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279622} -{"data":{"count":0},"hypothesisId":"H4_LEFT_JOIN","location":"main.go:508","message":"LEFT JOIN 链式查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279622} -{"data":{"count":0,"query":"SELECT app_order.id, app_order.amount, app_user.name as user_name FROM `order` LEFT JOIN `user` ON app_order.user_id = app_user.id WHERE app_order.status=? LIMIT 5 ;"},"hypothesisId":"H4_TRADITIONAL_JOIN","location":"main.go:525","message":"传统 JOIN 语法测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279623} -{"data":{"count":0},"hypothesisId":"H4_MULTI_JOIN","location":"main.go:539","message":"多表 JOIN 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279624} -{"data":{"count":0},"hypothesisId":"H4_INNER_JOIN","location":"main.go:551","message":"INNER JOIN 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279625} -{"data":null,"hypothesisId":"H5_AGGREGATE","location":"main.go:564","message":"开始聚合函数测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279625} -{"data":{"count":5},"hypothesisId":"H5_COUNT","location":"main.go:571","message":"Count 总数统计测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279625} -{"data":{"count":4},"hypothesisId":"H5_COUNT_WHERE","location":"main.go:579","message":"Count 条件统计测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279626} -{"data":{"sum":16500},"hypothesisId":"H5_SUM","location":"main.go:587","message":"Sum 求和测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279626} -{"data":{"avg":29.5},"hypothesisId":"H5_AVG","location":"main.go:595","message":"Avg 平均值测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279626} -{"data":{"max":35},"hypothesisId":"H5_MAX","location":"main.go:603","message":"Max 最大值测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279627} -{"data":{"min":25},"hypothesisId":"H5_MIN","location":"main.go:611","message":"Min 最小值测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279627} -{"data":{"stats":[{"avg_age":30,"level":"normal","total_balance":1500,"user_count":2},{"avg_age":30,"level":"vip","total_balance":5000,"user_count":1},{"avg_age":28,"level":"svip","total_balance":10000,"user_count":1}]},"hypothesisId":"H5_GROUP_BY","location":"main.go:625","message":"GROUP BY 分组统计测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279627} -{"data":null,"hypothesisId":"H6_PAGINATION","location":"main.go:638","message":"开始分页查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279627} -{"data":{"count":4},"hypothesisId":"H6_PAGE_SELECT","location":"main.go:648","message":"PageSelect 分页查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279628} -{"data":{"count":0},"hypothesisId":"H6_PAGE_2","location":"main.go:659","message":"PageSelect 第二页测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279628} -{"data":{"count":3},"hypothesisId":"H6_CHAIN_PAGE","location":"main.go:671","message":"链式 Page 分页测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279628} -{"data":{"count":2,"query":"SELECT id,name FROM `user` WHERE `status` =? LIMIT 3 OFFSET 2 ;"},"hypothesisId":"H6_OFFSET","location":"main.go:684","message":"Offset 偏移查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279629} -{"data":null,"hypothesisId":"H7_BATCH","location":"main.go:697","message":"开始批量插入测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279629} -{"data":{"affected":3,"query":"INSERT INTO `user_batch` (`email`, `name`, `status`) VALUES (?, ?, ?), (?, ?, ?), (?, ?, ?)"},"hypothesisId":"H7_BATCH_INSERT","location":"main.go:710","message":"BatchInsert 批量插入测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279633} -{"data":{"affected":0},"hypothesisId":"H7_BATCH_RAW","location":"main.go:722","message":"BatchInsert 带 [#] 标记测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279634} -{"data":null,"hypothesisId":"H8_UPSERT","location":"main.go:739","message":"开始 Upsert 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279636} -{"data":{"affected":0,"query":"INSERT INTO \"user\" (\"status\", \"level\", \"balance\", \"created_time\", \"name\", \"email\", \"age\") VALUES (?, ?, ?, NOW(), ?, ?, ?) ON CONFLICT (\"email\") DO UPDATE SET \"name\" = excluded.\"name\", \"age\" = excluded.\"age\", \"status\" = excluded.\"status\", \"level\" = excluded.\"level\", \"balance\" = excluded.\"balance\""},"hypothesisId":"H8_UPSERT_INSERT","location":"main.go:763","message":"Upsert 插入新记录测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279637} -{"data":{"affected":0},"hypothesisId":"H8_UPSERT_UPDATE","location":"main.go:783","message":"Upsert 更新已存在记录测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279637} -{"data":null,"hypothesisId":"H9_TRANSACTION","location":"main.go:803","message":"开始事务测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279639} -{"data":{"userId":0},"hypothesisId":"H9_TX_INSERT","location":"main.go:818","message":"事务内插入用户","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279639} -{"data":{"success":false,"userExists":false},"hypothesisId":"H9_TX_SUCCESS","location":"main.go:831","message":"事务成功提交测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279639} -{"data":{"userId":0},"hypothesisId":"H9_TX_ROLLBACK_INSERT","location":"main.go:846","message":"事务内插入(将回滚)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279640} -{"data":{"rolledBack":true,"success":false},"hypothesisId":"H9_TX_ROLLBACK","location":"main.go:856","message":"事务回滚测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279640} -{"data":null,"hypothesisId":"H10_RAW_SQL","location":"main.go:872","message":"开始原生 SQL 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279640} -{"data":{"count":0},"hypothesisId":"H10_QUERY","location":"main.go:879","message":"Query 原生查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279640} -{"data":{"error":{"Code":1,"ExtendedCode":1,"SystemErrno":0},"name":"Exec 原生执行","result":false},"hypothesisId":"H10_EXEC","location":"main.go:899","message":"Exec 原生执行测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279642} -{"data":{"10_raw_sql":{"name":"原生SQL测试","success":true,"tests":[{"count":0,"name":"Query 原生查询","result":true},{"error":{"Code":1,"ExtendedCode":1,"SystemErrno":0},"name":"Exec 原生执行","result":false}]},"1_basic_crud":{"name":"基础CRUD测试","success":true,"tests":[{"lastQuery":"INSERT INTO `user` (`level`,`created_time`,`name`,`email`,`age`,`status`,`balance`) VALUES (?,NOW(),?,?,?,?,?);","name":"Insert 插入测试","result":false,"userId":0},{"name":"Get 获取单条记录测试","result":false,"user":null},{"count":4,"name":"Select 单条件查询测试","result":true},{"count":4,"lastQuery":"SELECT * FROM `user` WHERE `age` \u003c? AND `age` \u003e? AND `status` =? ORDER BY id DESC LIMIT 5 ;","name":"Select 多条件自动AND测试","result":true},{"affected":0,"name":"Update 更新测试","result":false},{"affected":0,"name":"Delete 删除测试","result":false}]},"2_condition_syntax":{"name":"条件查询语法测试","success":true,"tests":[{"count":3,"name":"等于条件 (=)","result":true},{"count":3,"lastQuery":"SELECT id,name,status FROM `user` WHERE `status` !=? LIMIT 3 ;","name":"不等于条件 ([!])","result":true},{"count":3,"name":"大于小于条件 ([\u003e], [\u003c])","result":true},{"count":3,"name":"大于等于小于等于条件 ([\u003e=], [\u003c=])","result":true},{"count":1,"lastQuery":"SELECT id,name FROM `user` WHERE `name` LIKE ? LIMIT 3 ;","name":"LIKE 模糊查询 ([~])","result":true},{"count":0,"name":"右模糊查询 ([~!])","result":true},{"count":3,"lastQuery":"SELECT id,name,age FROM `user` WHERE `age` BETWEEN ? AND ? LIMIT 3 ;","name":"BETWEEN 区间查询 ([\u003c\u003e])","result":true},{"count":3,"name":"NOT BETWEEN 查询 ([\u003e\u003c])","result":true},{"count":5,"lastQuery":"SELECT id,name FROM `user` WHERE (`id` BETWEEN ? AND ? ) LIMIT 5 ;","name":"IN 查询","result":true},{"count":2,"name":"NOT IN 查询 ([!])","result":true},{"count":3,"name":"IS NULL 查询","result":true},{"count":0,"name":"IS NOT NULL 查询 ([!])","result":true},{"count":0,"lastQuery":"SELECT id,name,created_time FROM `user` WHERE created_time \u003e DATE_SUB(NOW(), INTERVAL 365 DAY) LIMIT 3 ;","name":"直接 SQL 片段查询 ([##])","result":true},{"count":3,"name":"显式 AND 条件","result":true},{"count":3,"name":"OR 条件","result":true},{"count":3,"lastQuery":"SELECT id,name,age,level FROM `user` WHERE ( `age` \u003c? OR `level` =? ) AND `status` =? LIMIT 5 ;","name":"嵌套 AND/OR 条件","result":true}]},"3_chain_query":{"name":"链式查询测试","success":true,"tests":[{"count":4,"name":"基本链式查询 Table().Where().Select()","result":true},{"count":4,"name":"链式 And 条件","result":true},{"count":2,"name":"链式 Or 条件","result":true},{"count":4,"name":"链式 Order 排序","result":true},{"count":3,"name":"链式 Limit 限制","result":true},{"name":"链式 Get 获取单条","result":true,"user":{"email":"zhangsan@example.com","id":1,"name":"张三"}},{"count":4,"name":"链式 Count 统计","result":true},{"count":4,"name":"链式 Page 分页","result":true},{"name":"链式 Group 分组","result":true,"stats":[{"cnt":2,"level":"normal"},{"cnt":1,"level":"svip"},{"cnt":1,"level":"vip"}]},{"affected":0,"name":"链式 Update 更新","result":true}]},"4_join_query":{"name":"JOIN查询测试","success":true,"tests":[{"count":0,"data":[],"name":"LEFT JOIN 链式查询","result":true},{"count":0,"lastQuery":"SELECT app_order.id, app_order.amount, app_user.name as user_name FROM `order` LEFT JOIN `user` ON app_order.user_id = app_user.id WHERE app_order.status=? LIMIT 5 ;","name":"传统 JOIN 语法","result":true},{"count":0,"data":[],"name":"多表 JOIN","result":true},{"count":0,"name":"INNER JOIN","result":true}]},"5_aggregate":{"name":"聚合函数测试","success":true,"tests":[{"count":5,"name":"Count 总数统计","result":true},{"count":4,"name":"Count 条件统计","result":true},{"name":"Sum 求和","result":true,"sum":16500},{"avg":29.5,"name":"Avg 平均值","result":true},{"max":35,"name":"Max 最大值","result":true},{"min":25,"name":"Min 最小值","result":true},{"name":"GROUP BY 分组统计","result":true,"stats":[{"avg_age":30,"level":"normal","total_balance":1500,"user_count":2},{"avg_age":30,"level":"vip","total_balance":5000,"user_count":1},{"avg_age":28,"level":"svip","total_balance":10000,"user_count":1}]}]},"6_pagination":{"name":"分页查询测试","success":true,"tests":[{"count":4,"name":"PageSelect 分页查询","result":true},{"count":0,"name":"PageSelect 第二页","result":true},{"count":3,"name":"链式 Page 分页","result":true},{"count":2,"lastQuery":"SELECT id,name FROM `user` WHERE `status` =? LIMIT 3 OFFSET 2 ;","name":"Offset 偏移查询","result":true}]},"7_batch_insert":{"name":"批量插入测试","success":true,"tests":[{"affected":3,"lastQuery":"INSERT INTO `user_batch` (`email`, `name`, `status`) VALUES (?, ?, ?), (?, ?, ?), (?, ?, ?)","name":"BatchInsert 批量插入","result":true},{"affected":0,"name":"BatchInsert 带 [#] 标记","result":true}]},"8_upsert":{"name":"Upsert测试","success":true,"tests":[{"affected":0,"lastQuery":"INSERT INTO \"user\" (\"status\", \"level\", \"balance\", \"created_time\", \"name\", \"email\", \"age\") VALUES (?, ?, ?, NOW(), ?, ?, ?) ON CONFLICT (\"email\") DO UPDATE SET \"name\" = excluded.\"name\", \"age\" = excluded.\"age\", \"status\" = excluded.\"status\", \"level\" = excluded.\"level\", \"balance\" = excluded.\"balance\"","name":"Upsert 插入新记录","result":true},{"affected":0,"name":"Upsert 更新已存在记录","result":true,"updatedUser":null}]},"9_transaction":{"name":"事务测试","success":true,"tests":[{"name":"事务成功提交","result":false,"userExists":false},{"name":"事务回滚","result":true,"userRolledBack":true}]}},"hypothesisId":"ALL_TESTS_DONE","location":"main.go:80","message":"所有测试完成","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030279642} -{"data":null,"hypothesisId":"START","location":"main.go:35","message":"开始 HoTimeDB 全功能测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030486929} -{"data":null,"hypothesisId":"TABLES","location":"main.go:tables","message":"查询数据库表结构","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030489537} -{"data":[{"Tables_in_dgs-cms260122":"admin"},{"Tables_in_dgs-cms260122":"article"},{"Tables_in_dgs-cms260122":"cached"},{"Tables_in_dgs-cms260122":"ctg"},{"Tables_in_dgs-cms260122":"ctg_article"},{"Tables_in_dgs-cms260122":"ctg_copy"},{"Tables_in_dgs-cms260122":"ebw_annex"},{"Tables_in_dgs-cms260122":"ebw_attachment"},{"Tables_in_dgs-cms260122":"ebw_customer"},{"Tables_in_dgs-cms260122":"ebw_items"},{"Tables_in_dgs-cms260122":"ebw_jobs"},{"Tables_in_dgs-cms260122":"ebw_news"},{"Tables_in_dgs-cms260122":"ebw_news_addition_res"},{"Tables_in_dgs-cms260122":"ebw_res"},{"Tables_in_dgs-cms260122":"ebw_user"},{"Tables_in_dgs-cms260122":"ebw_vote"},{"Tables_in_dgs-cms260122":"ebw_vote_option"},{"Tables_in_dgs-cms260122":"ebw_vote_user"},{"Tables_in_dgs-cms260122":"logs"},{"Tables_in_dgs-cms260122":"mail"},{"Tables_in_dgs-cms260122":"mail_discipline"},{"Tables_in_dgs-cms260122":"mail_part"},{"Tables_in_dgs-cms260122":"org"},{"Tables_in_dgs-cms260122":"role"},{"Tables_in_dgs-cms260122":"swiper_bottom"},{"Tables_in_dgs-cms260122":"swiper_center"},{"Tables_in_dgs-cms260122":"swiper_fly"},{"Tables_in_dgs-cms260122":"swiper_point"},{"Tables_in_dgs-cms260122":"swiper_sys"},{"Tables_in_dgs-cms260122":"swiper_top"}],"hypothesisId":"TABLES","location":"main.go:tables","message":"表列表","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030489541} -{"data":{"columns":[{"Default":null,"Extra":"auto_increment","Field":"id","Key":"PRI","Null":"NO","Type":"int(11)"},{"Default":null,"Extra":"","Field":"name","Key":"","Null":"YES","Type":"varchar(20)"},{"Default":null,"Extra":"","Field":"phone","Key":"","Null":"YES","Type":"varchar(15)"},{"Default":"0","Extra":"","Field":"state","Key":"","Null":"YES","Type":"int(2)"},{"Default":null,"Extra":"","Field":"password","Key":"","Null":"YES","Type":"varchar(50)"},{"Default":null,"Extra":"","Field":"avatar_img","Key":"","Null":"YES","Type":"varchar(200)"},{"Default":null,"Extra":"","Field":"role_id","Key":"","Null":"YES","Type":"int(11)"},{"Default":null,"Extra":"","Field":"title","Key":"","Null":"YES","Type":"varchar(50)"},{"Default":null,"Extra":"","Field":"modify_time","Key":"","Null":"YES","Type":"datetime"},{"Default":null,"Extra":"","Field":"create_time","Key":"","Null":"YES","Type":"datetime"}],"data":[],"table":"admin"},"hypothesisId":"DESCRIBE","location":"main.go:describe","message":"表结构","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030496424} -{"data":{"columns":[{"Default":null,"Extra":"auto_increment","Field":"id","Key":"PRI","Null":"NO","Type":"int(11)"},{"Default":null,"Extra":"","Field":"title","Key":"","Null":"YES","Type":"varchar(300)"},{"Default":"0","Extra":"","Field":"sort","Key":"","Null":"YES","Type":"int(4)"},{"Default":null,"Extra":"","Field":"author","Key":"","Null":"YES","Type":"varchar(50)"},{"Default":null,"Extra":"","Field":"origin","Key":"","Null":"YES","Type":"varchar(200)"},{"Default":null,"Extra":"","Field":"img","Key":"","Null":"YES","Type":"varchar(500)"},{"Default":null,"Extra":"","Field":"ctg_id","Key":"","Null":"YES","Type":"int(11)"},{"Default":null,"Extra":"","Field":"admin_id","Key":"","Null":"YES","Type":"int(11)"},{"Default":null,"Extra":"","Field":"push_time","Key":"","Null":"YES","Type":"datetime"},{"Default":"0","Extra":"","Field":"click_num","Key":"","Null":"YES","Type":"int(11)"},{"Default":null,"Extra":"","Field":"description","Key":"","Null":"YES","Type":"varchar(500)"},{"Default":null,"Extra":"","Field":"content","Key":"","Null":"YES","Type":"longtext"},{"Default":null,"Extra":"","Field":"sn","Key":"","Null":"YES","Type":"varchar(500)"},{"Default":null,"Extra":"","Field":"modify_time","Key":"","Null":"YES","Type":"datetime"},{"Default":null,"Extra":"","Field":"create_time","Key":"","Null":"YES","Type":"datetime"},{"Default":"0","Extra":"","Field":"state","Key":"","Null":"YES","Type":"int(2)"}],"data":[],"table":"article"},"hypothesisId":"DESCRIBE","location":"main.go:describe","message":"表结构","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030501928} -{"data":{"columns":[{"Default":null,"Extra":"","Field":"id","Key":"PRI","Null":"NO","Type":"varchar(50)"},{"Default":null,"Extra":"","Field":"no","Key":"","Null":"YES","Type":"varchar(50)"},{"Default":null,"Extra":"","Field":"account","Key":"","Null":"YES","Type":"varchar(50)"},{"Default":null,"Extra":"","Field":"name","Key":"","Null":"YES","Type":"varchar(50)"},{"Default":null,"Extra":"","Field":"sex","Key":"","Null":"YES","Type":"varchar(50)"},{"Default":null,"Extra":"","Field":"pass","Key":"","Null":"YES","Type":"varchar(50)"},{"Default":null,"Extra":"","Field":"mpass","Key":"","Null":"YES","Type":"varchar(50)"},{"Default":null,"Extra":"","Field":"adrress","Key":"","Null":"YES","Type":"varchar(50)"},{"Default":null,"Extra":"","Field":"tel","Key":"","Null":"YES","Type":"varchar(50)"},{"Default":null,"Extra":"","Field":"mail","Key":"","Null":"YES","Type":"varchar(50)"},{"Default":null,"Extra":"","Field":"type","Key":"","Null":"YES","Type":"varchar(50)"},{"Default":null,"Extra":"","Field":"depNo","Key":"","Null":"YES","Type":"varchar(50)"},{"Default":null,"Extra":"","Field":"depName","Key":"","Null":"YES","Type":"varchar(50)"}],"data":[],"table":"ebw_user"},"hypothesisId":"DESCRIBE","location":"main.go:describe","message":"表结构","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030502990} -{"data":null,"hypothesisId":"START","location":"main.go:35","message":"开始 HoTimeDB 全功能测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030861539} -{"data":null,"hypothesisId":"ALL_TESTS","location":"main.go:48","message":"开始所有测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871152} -{"data":{"adminCount":13,"articleCount":16659,"dbType":"MySQL"},"hypothesisId":"INIT","location":"main.go:init","message":"MySQL数据库初始化检查完成","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871344} -{"data":null,"hypothesisId":"H1_CRUD","location":"main.go:103","message":"开始基础 CRUD 测试 (MySQL)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871345} -{"data":{"adminId":16,"query":"INSERT INTO `admin` (`create_time`,`modify_time`,`name`,`phone`,`state`,`password`,`role_id`,`title`) VALUES (NOW(),NOW(),?,?,?,?,?,?);","success":true},"hypothesisId":"H1_INSERT","location":"main.go:118","message":"Insert 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871361} -{"data":{"admin":{"avatar_img":null,"create_time":"2026-01-21 21:27:51","id":16,"modify_time":"2026-01-21 21:27:51","name":"测试管理员_1769030871","password":"test123456","phone":"13869030871","role_id":1,"state":1,"title":"测试职位"},"success":true},"hypothesisId":"H1_GET","location":"main.go:126","message":"Get 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871367} -{"data":{"count":1},"hypothesisId":"H1_SELECT1","location":"main.go:134","message":"Select 单条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871375} -{"data":{"count":1,"query":"SELECT * FROM `admin` WHERE `role_id` \u003e? AND `state` =? ORDER BY id DESC LIMIT 5 ;"},"hypothesisId":"H1_SELECT2","location":"main.go:149","message":"Select 多条件自动AND测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871383} -{"data":{"affected":1},"hypothesisId":"H1_UPDATE","location":"main.go:160","message":"Update 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871400} -{"data":{"affected":1},"hypothesisId":"H1_DELETE","location":"main.go:175","message":"Delete 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871408} -{"data":null,"hypothesisId":"H2_CONDITION","location":"main.go:188","message":"开始条件查询语法测试 (MySQL)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871408} -{"data":{"count":3},"hypothesisId":"H2_EQUAL","location":"main.go:195","message":"等于条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871413} -{"data":{"count":3,"query":"SELECT id,title,state FROM `article` WHERE `state` !=? LIMIT 3 ;"},"hypothesisId":"H2_NOT_EQUAL","location":"main.go:204","message":"不等于条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871416} -{"data":{"count":3},"hypothesisId":"H2_GREATER_LESS","location":"main.go:216","message":"大于小于条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871420} -{"data":{"count":3},"hypothesisId":"H2_GTE_LTE","location":"main.go:228","message":"大于等于小于等于条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871423} -{"data":{"count":3,"query":"SELECT id,title FROM `article` WHERE `title` LIKE ? LIMIT 3 ;"},"hypothesisId":"H2_LIKE","location":"main.go:237","message":"LIKE 模糊查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871428} -{"data":{"count":0},"hypothesisId":"H2_LIKE_RIGHT","location":"main.go:245","message":"右模糊查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871433} -{"data":{"count":3,"query":"SELECT id,title,click_num FROM `article` WHERE `click_num` BETWEEN ? AND ? LIMIT 3 ;"},"hypothesisId":"H2_BETWEEN","location":"main.go:254","message":"BETWEEN 区间查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871438} -{"data":{"count":0},"hypothesisId":"H2_NOT_BETWEEN","location":"main.go:262","message":"NOT BETWEEN 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871460} -{"data":{"count":5,"query":"SELECT id,title FROM `article` WHERE (`id` BETWEEN ? AND ? ) LIMIT 5 ;"},"hypothesisId":"H2_IN","location":"main.go:271","message":"IN 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871464} -{"data":{"count":5},"hypothesisId":"H2_NOT_IN","location":"main.go:279","message":"NOT IN 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871469} -{"data":{"count":3},"hypothesisId":"H2_IS_NULL","location":"main.go:287","message":"IS NULL 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871470} -{"data":{"count":3},"hypothesisId":"H2_IS_NOT_NULL","location":"main.go:295","message":"IS NOT NULL 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871473} -{"data":{"count":0,"query":"SELECT id,title,create_time FROM `article` WHERE create_time \u003e DATE_SUB(NOW(), INTERVAL 365 DAY) LIMIT 3 ;"},"hypothesisId":"H2_RAW_SQL","location":"main.go:307","message":"直接 SQL 片段查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871493} -{"data":{"count":3},"hypothesisId":"H2_EXPLICIT_AND","location":"main.go:321","message":"显式 AND 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871497} -{"data":{"count":5},"hypothesisId":"H2_OR","location":"main.go:335","message":"OR 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871501} -{"data":{"count":5,"query":"SELECT id,title,sort,state FROM `article` WHERE ( `click_num` \u003e? OR `sort` \u003e=? ) AND `state` =? LIMIT 5 ;"},"hypothesisId":"H2_NESTED","location":"main.go:353","message":"嵌套 AND/OR 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871505} -{"data":null,"hypothesisId":"H3_CHAIN","location":"main.go:366","message":"开始链式查询测试 (MySQL)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871505} -{"data":{"count":16659},"hypothesisId":"H3_BASIC","location":"main.go:375","message":"基本链式查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871561} -{"data":{"count":16659},"hypothesisId":"H3_AND","location":"main.go:387","message":"链式 And 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871598} -{"data":{"count":16659},"hypothesisId":"H3_OR","location":"main.go:401","message":"链式 Or 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871635} -{"data":{"count":5},"hypothesisId":"H3_ORDER","location":"main.go:413","message":"链式 Order 排序测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871658} -{"data":{"count":3},"hypothesisId":"H3_LIMIT","location":"main.go:424","message":"链式 Limit 限制测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871661} -{"data":{"article":{"author":"atestu","id":1,"title":"atestu"}},"hypothesisId":"H3_GET","location":"main.go:434","message":"链式 Get 获取单条测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871664} -{"data":{"count":16659},"hypothesisId":"H3_COUNT","location":"main.go:444","message":"链式 Count 统计测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871687} -{"data":{"count":5},"hypothesisId":"H3_PAGE","location":"main.go:455","message":"链式 Page 分页测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871691} -{"data":{"stats":[{"cnt":627,"ctg_id":null},{"cnt":36,"ctg_id":1},{"cnt":57,"ctg_id":2},{"cnt":8,"ctg_id":3},{"cnt":38,"ctg_id":4},{"cnt":11,"ctg_id":5},{"cnt":79,"ctg_id":6},{"cnt":59,"ctg_id":7},{"cnt":54,"ctg_id":8},{"cnt":1,"ctg_id":9},{"cnt":12,"ctg_id":10},{"cnt":3,"ctg_id":11},{"cnt":5,"ctg_id":12},{"cnt":1,"ctg_id":13},{"cnt":1,"ctg_id":17},{"cnt":1,"ctg_id":18},{"cnt":1,"ctg_id":19},{"cnt":10,"ctg_id":20},{"cnt":1857,"ctg_id":21},{"cnt":632,"ctg_id":22},{"cnt":4912,"ctg_id":23},{"cnt":1235,"ctg_id":24},{"cnt":1156,"ctg_id":25},{"cnt":1165,"ctg_id":26},{"cnt":111,"ctg_id":27},{"cnt":115,"ctg_id":28},{"cnt":40,"ctg_id":29},{"cnt":42,"ctg_id":30},{"cnt":76,"ctg_id":31},{"cnt":11,"ctg_id":32},{"cnt":6,"ctg_id":33},{"cnt":6,"ctg_id":34},{"cnt":185,"ctg_id":35},{"cnt":3,"ctg_id":40},{"cnt":1,"ctg_id":41},{"cnt":4,"ctg_id":43},{"cnt":28,"ctg_id":44},{"cnt":11,"ctg_id":45},{"cnt":2,"ctg_id":46},{"cnt":2,"ctg_id":48},{"cnt":5,"ctg_id":49},{"cnt":1,"ctg_id":50},{"cnt":5,"ctg_id":51},{"cnt":2,"ctg_id":52},{"cnt":52,"ctg_id":53},{"cnt":3,"ctg_id":54},{"cnt":8,"ctg_id":55},{"cnt":5,"ctg_id":57},{"cnt":8,"ctg_id":60},{"cnt":20,"ctg_id":61},{"cnt":1,"ctg_id":65},{"cnt":43,"ctg_id":66},{"cnt":46,"ctg_id":67},{"cnt":30,"ctg_id":68},{"cnt":17,"ctg_id":69},{"cnt":165,"ctg_id":70},{"cnt":29,"ctg_id":71},{"cnt":15,"ctg_id":72},{"cnt":28,"ctg_id":73},{"cnt":123,"ctg_id":76},{"cnt":6,"ctg_id":77},{"cnt":1,"ctg_id":79},{"cnt":1,"ctg_id":80},{"cnt":1,"ctg_id":81},{"cnt":23,"ctg_id":83},{"cnt":1,"ctg_id":85},{"cnt":1,"ctg_id":86},{"cnt":6,"ctg_id":87},{"cnt":2,"ctg_id":89},{"cnt":1,"ctg_id":90},{"cnt":4,"ctg_id":92},{"cnt":4,"ctg_id":93},{"cnt":2,"ctg_id":96},{"cnt":7,"ctg_id":97},{"cnt":1,"ctg_id":99},{"cnt":1,"ctg_id":100},{"cnt":1,"ctg_id":101},{"cnt":3,"ctg_id":103},{"cnt":3,"ctg_id":106},{"cnt":55,"ctg_id":107},{"cnt":2,"ctg_id":108},{"cnt":1,"ctg_id":109},{"cnt":1,"ctg_id":110},{"cnt":1,"ctg_id":111},{"cnt":5,"ctg_id":113},{"cnt":2,"ctg_id":117},{"cnt":3,"ctg_id":119},{"cnt":1,"ctg_id":123},{"cnt":2,"ctg_id":124},{"cnt":2,"ctg_id":125},{"cnt":12,"ctg_id":127},{"cnt":2,"ctg_id":131},{"cnt":1,"ctg_id":133},{"cnt":1,"ctg_id":134},{"cnt":3,"ctg_id":137},{"cnt":1,"ctg_id":138},{"cnt":3,"ctg_id":140},{"cnt":20,"ctg_id":141},{"cnt":1,"ctg_id":143},{"cnt":1,"ctg_id":144},{"cnt":1,"ctg_id":145},{"cnt":1,"ctg_id":153},{"cnt":1,"ctg_id":154},{"cnt":1,"ctg_id":155},{"cnt":3,"ctg_id":157},{"cnt":1,"ctg_id":158},{"cnt":3,"ctg_id":160},{"cnt":17,"ctg_id":161},{"cnt":1,"ctg_id":163},{"cnt":1,"ctg_id":164},{"cnt":1,"ctg_id":170},{"cnt":1,"ctg_id":173},{"cnt":1,"ctg_id":174},{"cnt":1,"ctg_id":175},{"cnt":22,"ctg_id":177},{"cnt":41,"ctg_id":179},{"cnt":3,"ctg_id":180},{"cnt":17,"ctg_id":181},{"cnt":1,"ctg_id":183},{"cnt":1,"ctg_id":184},{"cnt":1,"ctg_id":185},{"cnt":7,"ctg_id":187},{"cnt":2,"ctg_id":190},{"cnt":20,"ctg_id":191},{"cnt":7,"ctg_id":193},{"cnt":23,"ctg_id":194},{"cnt":4,"ctg_id":195},{"cnt":81,"ctg_id":196},{"cnt":3,"ctg_id":197},{"cnt":5,"ctg_id":199},{"cnt":2,"ctg_id":200},{"cnt":1,"ctg_id":201},{"cnt":25,"ctg_id":202},{"cnt":31,"ctg_id":203},{"cnt":20,"ctg_id":204},{"cnt":15,"ctg_id":205},{"cnt":7,"ctg_id":206},{"cnt":34,"ctg_id":207},{"cnt":21,"ctg_id":208},{"cnt":11,"ctg_id":213},{"cnt":3,"ctg_id":214},{"cnt":2814,"ctg_id":215},{"cnt":2,"ctg_id":216},{"cnt":1,"ctg_id":217},{"cnt":1,"ctg_id":231}]},"hypothesisId":"H3_GROUP","location":"main.go:466","message":"链式 Group 分组测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030871778} -{"data":{"affected":1,"name":"链式 Update 更新","result":true},"hypothesisId":"H3_UPDATE","location":"main.go:483","message":"链式 Update 更新测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030872026} -{"data":null,"hypothesisId":"H4_JOIN","location":"main.go:496","message":"开始 JOIN 查询测试 (MySQL)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030872026} -{"data":{"count":5},"hypothesisId":"H4_LEFT_JOIN","location":"main.go:508","message":"LEFT JOIN 链式查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030872517} -{"data":{"count":5,"query":"SELECT article.id, article.title, ctg.name as ctg_name FROM `article` LEFT JOIN `ctg` ON article.ctg_id = ctg.id WHERE article.state=? LIMIT 5 ;"},"hypothesisId":"H4_TRADITIONAL_JOIN","location":"main.go:525","message":"传统 JOIN 语法测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030872521} -{"data":{"count":5},"hypothesisId":"H4_MULTI_JOIN","location":"main.go:539","message":"多表 JOIN 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030872523} -{"data":{"count":5},"hypothesisId":"H4_INNER_JOIN","location":"main.go:551","message":"INNER JOIN 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030872525} -{"data":null,"hypothesisId":"H5_AGGREGATE","location":"main.go:564","message":"开始聚合函数测试 (MySQL)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030872525} -{"data":{"count":16659},"hypothesisId":"H5_COUNT","location":"main.go:571","message":"Count 总数统计测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030872545} -{"data":{"count":16659},"hypothesisId":"H5_COUNT_WHERE","location":"main.go:579","message":"Count 条件统计测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030872568} -{"data":{"sum":499106},"hypothesisId":"H5_SUM","location":"main.go:587","message":"Sum 求和测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030872592} -{"data":{"avg":29.9601},"hypothesisId":"H5_AVG","location":"main.go:595","message":"Avg 平均值测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030872615} -{"data":{"max":4803},"hypothesisId":"H5_MAX","location":"main.go:603","message":"Max 最大值测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030872649} -{"data":{"min":0},"hypothesisId":"H5_MIN","location":"main.go:611","message":"Min 最小值测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030872674} -{"data":{"stats":[{"article_count":4912,"avg_clicks":"34.7453","ctg_id":23,"total_clicks":"170669"},{"article_count":2814,"avg_clicks":"24.8856","ctg_id":215,"total_clicks":"70028"},{"article_count":1857,"avg_clicks":"55.4265","ctg_id":21,"total_clicks":"102927"},{"article_count":1235,"avg_clicks":"12.1061","ctg_id":24,"total_clicks":"14951"},{"article_count":1165,"avg_clicks":"2.6704","ctg_id":26,"total_clicks":"3111"},{"article_count":1156,"avg_clicks":"16.6176","ctg_id":25,"total_clicks":"19210"},{"article_count":632,"avg_clicks":"131.1487","ctg_id":22,"total_clicks":"82886"},{"article_count":627,"avg_clicks":"2.0335","ctg_id":null,"total_clicks":"1275"},{"article_count":185,"avg_clicks":"8.6757","ctg_id":35,"total_clicks":"1605"},{"article_count":165,"avg_clicks":"0.4242","ctg_id":70,"total_clicks":"70"}]},"hypothesisId":"H5_GROUP_BY","location":"main.go:625","message":"GROUP BY 分组统计测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030872702} -{"data":null,"hypothesisId":"H6_PAGINATION","location":"main.go:638","message":"开始分页查询测试 (MySQL)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030872702} -{"data":{"count":5},"hypothesisId":"H6_PAGE_SELECT","location":"main.go:648","message":"PageSelect 分页查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030872707} -{"data":{"count":5},"hypothesisId":"H6_PAGE_2","location":"main.go:659","message":"PageSelect 第二页测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030872710} -{"data":{"count":3},"hypothesisId":"H6_CHAIN_PAGE","location":"main.go:671","message":"链式 Page 分页测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030872713} -{"data":{"count":3,"query":"SELECT id,title FROM `article` WHERE `state` =? LIMIT 3 OFFSET 2 ;"},"hypothesisId":"H6_OFFSET","location":"main.go:684","message":"Offset 偏移查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030872716} -{"data":null,"hypothesisId":"H7_BATCH","location":"main.go:697","message":"开始批量插入测试 (MySQL)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030872716} -{"data":{"affected":3,"query":"INSERT INTO `test_batch` (`name`, `state`, `title`) VALUES (?, ?, ?), (?, ?, ?), (?, ?, ?)"},"hypothesisId":"H7_BATCH_INSERT","location":"main.go:710","message":"BatchInsert 批量插入测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030872719} -{"data":{"affected":2},"hypothesisId":"H7_BATCH_RAW","location":"main.go:722","message":"BatchInsert 带 [#] 标记测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030872723} -{"data":null,"hypothesisId":"H8_UPSERT","location":"main.go:739","message":"开始 Upsert 测试 (MySQL)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030872731} -{"data":{"affected":1,"query":"INSERT INTO `admin` (`password`, `role_id`, `title`, `create_time`, `modify_time`, `name`, `phone`, `state`) VALUES (?, ?, ?, NOW(), NOW(), ?, ?, ?) ON DUPLICATE KEY UPDATE `name` = VALUES(`name`), `state` = VALUES(`state`), `title` = VALUES(`title`), `modify_time` = NOW()"},"hypothesisId":"H8_UPSERT_INSERT","location":"main.go:763","message":"Upsert 插入新记录测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030873338} -{"data":{"affected":1},"hypothesisId":"H8_UPSERT_UPDATE","location":"main.go:783","message":"Upsert 更新已存在记录测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030874027} -{"data":null,"hypothesisId":"H9_TRANSACTION","location":"main.go:803","message":"开始事务测试 (MySQL)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030874997} -{"data":{"recordId":7},"hypothesisId":"H9_TX_INSERT","location":"main.go:818","message":"事务内插入记录","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030875002} -{"data":{"recordExists":true,"success":true},"hypothesisId":"H9_TX_SUCCESS","location":"main.go:831","message":"事务成功提交测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030875007} -{"data":{"recordId":8},"hypothesisId":"H9_TX_ROLLBACK_INSERT","location":"main.go:846","message":"事务内插入(将回滚)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030875011} -{"data":{"rolledBack":false,"success":false},"hypothesisId":"H9_TX_ROLLBACK","location":"main.go:856","message":"事务回滚测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030875018} -{"data":null,"hypothesisId":"H10_RAW_SQL","location":"main.go:872","message":"开始原生 SQL 测试 (MySQL)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030875021} -{"data":{"count":5},"hypothesisId":"H10_QUERY","location":"main.go:879","message":"Query 原生查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030875026} -{"data":{"affected":1,"name":"Exec 原生执行","result":true},"hypothesisId":"H10_EXEC","location":"main.go:899","message":"Exec 原生执行测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030875631} -{"data":{"10_raw_sql":{"name":"原生SQL测试","success":true,"tests":[{"count":5,"name":"Query 原生查询","result":true},{"affected":1,"name":"Exec 原生执行","result":true}]},"1_basic_crud":{"name":"基础CRUD测试","success":true,"tests":[{"adminId":16,"lastQuery":"INSERT INTO `admin` (`create_time`,`modify_time`,`name`,`phone`,`state`,`password`,`role_id`,`title`) VALUES (NOW(),NOW(),?,?,?,?,?,?);","name":"Insert 插入测试 (admin表)","result":true},{"admin":{"avatar_img":null,"create_time":"2026-01-21 21:27:51","id":16,"modify_time":"2026-01-21 21:27:51","name":"测试管理员_1769030871","password":"test123456","phone":"13869030871","role_id":1,"state":1,"title":"测试职位"},"name":"Get 获取单条记录测试","result":true},{"count":1,"name":"Select 单条件查询测试","result":true},{"count":1,"lastQuery":"SELECT * FROM `admin` WHERE `role_id` \u003e? AND `state` =? ORDER BY id DESC LIMIT 5 ;","name":"Select 多条件自动AND测试","result":true},{"affected":1,"name":"Update 更新测试","result":true},{"affected":1,"name":"Delete 删除测试","result":true}]},"2_condition_syntax":{"name":"条件查询语法测试","success":true,"tests":[{"count":3,"name":"等于条件 (=)","result":true},{"count":3,"lastQuery":"SELECT id,title,state FROM `article` WHERE `state` !=? LIMIT 3 ;","name":"不等于条件 ([!])","result":true},{"count":3,"name":"大于小于条件 ([\u003e], [\u003c])","result":true},{"count":3,"name":"大于等于小于等于条件 ([\u003e=], [\u003c=])","result":true},{"count":3,"lastQuery":"SELECT id,title FROM `article` WHERE `title` LIKE ? LIMIT 3 ;","name":"LIKE 模糊查询 ([~])","result":true},{"count":0,"name":"右模糊查询 ([~!])","result":true},{"count":3,"lastQuery":"SELECT id,title,click_num FROM `article` WHERE `click_num` BETWEEN ? AND ? LIMIT 3 ;","name":"BETWEEN 区间查询 ([\u003c\u003e])","result":true},{"count":0,"name":"NOT BETWEEN 查询 ([\u003e\u003c])","result":true},{"count":5,"lastQuery":"SELECT id,title FROM `article` WHERE (`id` BETWEEN ? AND ? ) LIMIT 5 ;","name":"IN 查询","result":true},{"count":5,"name":"NOT IN 查询 ([!])","result":true},{"count":3,"name":"IS NULL 查询","result":true},{"count":3,"name":"IS NOT NULL 查询 ([!])","result":true},{"count":0,"lastQuery":"SELECT id,title,create_time FROM `article` WHERE create_time \u003e DATE_SUB(NOW(), INTERVAL 365 DAY) LIMIT 3 ;","name":"直接 SQL 片段查询 ([##])","result":true},{"count":3,"name":"显式 AND 条件","result":true},{"count":5,"name":"OR 条件","result":true},{"count":5,"lastQuery":"SELECT id,title,sort,state FROM `article` WHERE ( `click_num` \u003e? OR `sort` \u003e=? ) AND `state` =? LIMIT 5 ;","name":"嵌套 AND/OR 条件","result":true}]},"3_chain_query":{"name":"链式查询测试","success":true,"tests":[{"count":16659,"name":"基本链式查询 Table().Where().Select()","result":true},{"count":16659,"name":"链式 And 条件","result":true},{"count":16659,"name":"链式 Or 条件","result":true},{"count":5,"name":"链式 Order 排序","result":true},{"count":3,"name":"链式 Limit 限制","result":true},{"article":{"author":"atestu","id":1,"title":"atestu"},"name":"链式 Get 获取单条","result":true},{"count":16659,"name":"链式 Count 统计","result":true},{"count":5,"name":"链式 Page 分页","result":true},{"name":"链式 Group 分组","result":true,"stats":[{"cnt":627,"ctg_id":null},{"cnt":36,"ctg_id":1},{"cnt":57,"ctg_id":2},{"cnt":8,"ctg_id":3},{"cnt":38,"ctg_id":4},{"cnt":11,"ctg_id":5},{"cnt":79,"ctg_id":6},{"cnt":59,"ctg_id":7},{"cnt":54,"ctg_id":8},{"cnt":1,"ctg_id":9},{"cnt":12,"ctg_id":10},{"cnt":3,"ctg_id":11},{"cnt":5,"ctg_id":12},{"cnt":1,"ctg_id":13},{"cnt":1,"ctg_id":17},{"cnt":1,"ctg_id":18},{"cnt":1,"ctg_id":19},{"cnt":10,"ctg_id":20},{"cnt":1857,"ctg_id":21},{"cnt":632,"ctg_id":22},{"cnt":4912,"ctg_id":23},{"cnt":1235,"ctg_id":24},{"cnt":1156,"ctg_id":25},{"cnt":1165,"ctg_id":26},{"cnt":111,"ctg_id":27},{"cnt":115,"ctg_id":28},{"cnt":40,"ctg_id":29},{"cnt":42,"ctg_id":30},{"cnt":76,"ctg_id":31},{"cnt":11,"ctg_id":32},{"cnt":6,"ctg_id":33},{"cnt":6,"ctg_id":34},{"cnt":185,"ctg_id":35},{"cnt":3,"ctg_id":40},{"cnt":1,"ctg_id":41},{"cnt":4,"ctg_id":43},{"cnt":28,"ctg_id":44},{"cnt":11,"ctg_id":45},{"cnt":2,"ctg_id":46},{"cnt":2,"ctg_id":48},{"cnt":5,"ctg_id":49},{"cnt":1,"ctg_id":50},{"cnt":5,"ctg_id":51},{"cnt":2,"ctg_id":52},{"cnt":52,"ctg_id":53},{"cnt":3,"ctg_id":54},{"cnt":8,"ctg_id":55},{"cnt":5,"ctg_id":57},{"cnt":8,"ctg_id":60},{"cnt":20,"ctg_id":61},{"cnt":1,"ctg_id":65},{"cnt":43,"ctg_id":66},{"cnt":46,"ctg_id":67},{"cnt":30,"ctg_id":68},{"cnt":17,"ctg_id":69},{"cnt":165,"ctg_id":70},{"cnt":29,"ctg_id":71},{"cnt":15,"ctg_id":72},{"cnt":28,"ctg_id":73},{"cnt":123,"ctg_id":76},{"cnt":6,"ctg_id":77},{"cnt":1,"ctg_id":79},{"cnt":1,"ctg_id":80},{"cnt":1,"ctg_id":81},{"cnt":23,"ctg_id":83},{"cnt":1,"ctg_id":85},{"cnt":1,"ctg_id":86},{"cnt":6,"ctg_id":87},{"cnt":2,"ctg_id":89},{"cnt":1,"ctg_id":90},{"cnt":4,"ctg_id":92},{"cnt":4,"ctg_id":93},{"cnt":2,"ctg_id":96},{"cnt":7,"ctg_id":97},{"cnt":1,"ctg_id":99},{"cnt":1,"ctg_id":100},{"cnt":1,"ctg_id":101},{"cnt":3,"ctg_id":103},{"cnt":3,"ctg_id":106},{"cnt":55,"ctg_id":107},{"cnt":2,"ctg_id":108},{"cnt":1,"ctg_id":109},{"cnt":1,"ctg_id":110},{"cnt":1,"ctg_id":111},{"cnt":5,"ctg_id":113},{"cnt":2,"ctg_id":117},{"cnt":3,"ctg_id":119},{"cnt":1,"ctg_id":123},{"cnt":2,"ctg_id":124},{"cnt":2,"ctg_id":125},{"cnt":12,"ctg_id":127},{"cnt":2,"ctg_id":131},{"cnt":1,"ctg_id":133},{"cnt":1,"ctg_id":134},{"cnt":3,"ctg_id":137},{"cnt":1,"ctg_id":138},{"cnt":3,"ctg_id":140},{"cnt":20,"ctg_id":141},{"cnt":1,"ctg_id":143},{"cnt":1,"ctg_id":144},{"cnt":1,"ctg_id":145},{"cnt":1,"ctg_id":153},{"cnt":1,"ctg_id":154},{"cnt":1,"ctg_id":155},{"cnt":3,"ctg_id":157},{"cnt":1,"ctg_id":158},{"cnt":3,"ctg_id":160},{"cnt":17,"ctg_id":161},{"cnt":1,"ctg_id":163},{"cnt":1,"ctg_id":164},{"cnt":1,"ctg_id":170},{"cnt":1,"ctg_id":173},{"cnt":1,"ctg_id":174},{"cnt":1,"ctg_id":175},{"cnt":22,"ctg_id":177},{"cnt":41,"ctg_id":179},{"cnt":3,"ctg_id":180},{"cnt":17,"ctg_id":181},{"cnt":1,"ctg_id":183},{"cnt":1,"ctg_id":184},{"cnt":1,"ctg_id":185},{"cnt":7,"ctg_id":187},{"cnt":2,"ctg_id":190},{"cnt":20,"ctg_id":191},{"cnt":7,"ctg_id":193},{"cnt":23,"ctg_id":194},{"cnt":4,"ctg_id":195},{"cnt":81,"ctg_id":196},{"cnt":3,"ctg_id":197},{"cnt":5,"ctg_id":199},{"cnt":2,"ctg_id":200},{"cnt":1,"ctg_id":201},{"cnt":25,"ctg_id":202},{"cnt":31,"ctg_id":203},{"cnt":20,"ctg_id":204},{"cnt":15,"ctg_id":205},{"cnt":7,"ctg_id":206},{"cnt":34,"ctg_id":207},{"cnt":21,"ctg_id":208},{"cnt":11,"ctg_id":213},{"cnt":3,"ctg_id":214},{"cnt":2814,"ctg_id":215},{"cnt":2,"ctg_id":216},{"cnt":1,"ctg_id":217},{"cnt":1,"ctg_id":231}]},{"affected":1,"name":"链式 Update 更新","result":true}]},"4_join_query":{"name":"JOIN查询测试","success":true,"tests":[{"count":5,"data":[{"ctg_name":null,"id":1,"title":"atestu"},{"ctg_name":null,"id":2,"title":"atestu"},{"ctg_name":null,"id":3,"title":"atestu"},{"ctg_name":null,"id":4,"title":"atestu"},{"ctg_name":"纪检监察","id":5,"title":"atestu"}],"name":"LEFT JOIN 链式查询","result":true},{"count":5,"lastQuery":"SELECT article.id, article.title, ctg.name as ctg_name FROM `article` LEFT JOIN `ctg` ON article.ctg_id = ctg.id WHERE article.state=? LIMIT 5 ;","name":"传统 JOIN 语法","result":true},{"count":5,"data":[{"admin_name":"admin","ctg_name":null,"id":1,"title":"atestu"},{"admin_name":"admin","ctg_name":null,"id":2,"title":"atestu"},{"admin_name":"admin","ctg_name":null,"id":3,"title":"atestu"},{"admin_name":"admin","ctg_name":null,"id":4,"title":"atestu"},{"admin_name":"admin","ctg_name":"纪检监察","id":5,"title":"atestu"}],"name":"多表 JOIN","result":true},{"count":5,"name":"INNER JOIN","result":true}]},"5_aggregate":{"name":"聚合函数测试","success":true,"tests":[{"count":16659,"name":"Count 总数统计","result":true},{"count":16659,"name":"Count 条件统计","result":true},{"name":"Sum 求和","result":true,"sum":499106},{"avg":29.9601,"name":"Avg 平均值","result":true},{"max":4803,"name":"Max 最大值","result":true},{"min":0,"name":"Min 最小值","result":true},{"name":"GROUP BY 分组统计","result":true,"stats":[{"article_count":4912,"avg_clicks":"34.7453","ctg_id":23,"total_clicks":"170669"},{"article_count":2814,"avg_clicks":"24.8856","ctg_id":215,"total_clicks":"70028"},{"article_count":1857,"avg_clicks":"55.4265","ctg_id":21,"total_clicks":"102927"},{"article_count":1235,"avg_clicks":"12.1061","ctg_id":24,"total_clicks":"14951"},{"article_count":1165,"avg_clicks":"2.6704","ctg_id":26,"total_clicks":"3111"},{"article_count":1156,"avg_clicks":"16.6176","ctg_id":25,"total_clicks":"19210"},{"article_count":632,"avg_clicks":"131.1487","ctg_id":22,"total_clicks":"82886"},{"article_count":627,"avg_clicks":"2.0335","ctg_id":null,"total_clicks":"1275"},{"article_count":185,"avg_clicks":"8.6757","ctg_id":35,"total_clicks":"1605"},{"article_count":165,"avg_clicks":"0.4242","ctg_id":70,"total_clicks":"70"}]}]},"6_pagination":{"name":"分页查询测试","success":true,"tests":[{"count":5,"name":"PageSelect 分页查询","result":true},{"count":5,"name":"PageSelect 第二页","result":true},{"count":3,"name":"链式 Page 分页","result":true},{"count":3,"lastQuery":"SELECT id,title FROM `article` WHERE `state` =? LIMIT 3 OFFSET 2 ;","name":"Offset 偏移查询","result":true}]},"7_batch_insert":{"name":"批量插入测试","success":true,"tests":[{"affected":3,"lastQuery":"INSERT INTO `test_batch` (`name`, `state`, `title`) VALUES (?, ?, ?), (?, ?, ?), (?, ?, ?)","name":"BatchInsert 批量插入","result":true},{"affected":2,"name":"BatchInsert 带 [#] 标记","result":true}]},"8_upsert":{"name":"Upsert测试","success":true,"tests":[{"affected":1,"lastQuery":"INSERT INTO `admin` (`password`, `role_id`, `title`, `create_time`, `modify_time`, `name`, `phone`, `state`) VALUES (?, ?, ?, NOW(), NOW(), ?, ?, ?) ON DUPLICATE KEY UPDATE `name` = VALUES(`name`), `state` = VALUES(`state`), `title` = VALUES(`title`), `modify_time` = NOW()","name":"Upsert 插入新记录 (admin表)","result":true},{"affected":1,"name":"Upsert 更新已存在记录","result":true,"updatedAdmin":{"avatar_img":null,"create_time":"2026-01-21 21:27:52","id":17,"modify_time":"2026-01-21 21:27:52","name":"Upsert测试管理员","password":"test123","phone":"19969030872","role_id":1,"state":1,"title":"测试职位"}}]},"9_transaction":{"name":"事务测试","success":true,"tests":[{"name":"事务成功提交","recordExists":true,"result":true},{"name":"事务回滚","recordRolledBack":false,"result":true}]}},"hypothesisId":"ALL_TESTS_DONE","location":"main.go:80","message":"所有测试完成","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030875631} -{"data":null,"hypothesisId":"H1_CRUD","location":"main.go:103","message":"开始基础 CRUD 测试 (MySQL)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030893205} -{"data":{"adminId":19,"query":"INSERT INTO `admin` (`role_id`,`title`,`create_time`,`modify_time`,`name`,`phone`,`state`,`password`) VALUES (?,?,NOW(),NOW(),?,?,?,?);","success":true},"hypothesisId":"H1_INSERT","location":"main.go:118","message":"Insert 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030893495} -{"data":{"admin":{"avatar_img":null,"create_time":"2026-01-21 21:28:13","id":19,"modify_time":"2026-01-21 21:28:13","name":"测试管理员_1769030893","password":"test123456","phone":"13869030893","role_id":1,"state":1,"title":"测试职位"},"success":true},"hypothesisId":"H1_GET","location":"main.go:126","message":"Get 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030893500} -{"data":{"count":2},"hypothesisId":"H1_SELECT1","location":"main.go:134","message":"Select 单条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030893504} -{"data":{"count":2,"query":"SELECT * FROM `admin` WHERE `role_id` \u003e? AND `state` =? ORDER BY id DESC LIMIT 5 ;"},"hypothesisId":"H1_SELECT2","location":"main.go:149","message":"Select 多条件自动AND测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030893508} -{"data":{"affected":1},"hypothesisId":"H1_UPDATE","location":"main.go:160","message":"Update 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030894408} -{"data":{"affected":1},"hypothesisId":"H1_DELETE","location":"main.go:175","message":"Delete 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030894417} -{"data":null,"hypothesisId":"H2_CONDITION","location":"main.go:188","message":"开始条件查询语法测试 (MySQL)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030900520} -{"data":{"count":3},"hypothesisId":"H2_EQUAL","location":"main.go:195","message":"等于条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030900523} -{"data":{"count":3,"query":"SELECT id,title,state FROM `article` WHERE `state` !=? LIMIT 3 ;"},"hypothesisId":"H2_NOT_EQUAL","location":"main.go:204","message":"不等于条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030900525} -{"data":{"count":3},"hypothesisId":"H2_GREATER_LESS","location":"main.go:216","message":"大于小于条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030900528} -{"data":{"count":3},"hypothesisId":"H2_GTE_LTE","location":"main.go:228","message":"大于等于小于等于条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030900531} -{"data":{"count":3,"query":"SELECT id,title FROM `article` WHERE `title` LIKE ? LIMIT 3 ;"},"hypothesisId":"H2_LIKE","location":"main.go:237","message":"LIKE 模糊查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030900534} -{"data":{"count":0},"hypothesisId":"H2_LIKE_RIGHT","location":"main.go:245","message":"右模糊查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030900538} -{"data":{"count":3,"query":"SELECT id,title,click_num FROM `article` WHERE `click_num` BETWEEN ? AND ? LIMIT 3 ;"},"hypothesisId":"H2_BETWEEN","location":"main.go:254","message":"BETWEEN 区间查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030900541} -{"data":{"count":0},"hypothesisId":"H2_NOT_BETWEEN","location":"main.go:262","message":"NOT BETWEEN 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030900561} -{"data":{"count":5,"query":"SELECT id,title FROM `article` WHERE (`id` BETWEEN ? AND ? ) LIMIT 5 ;"},"hypothesisId":"H2_IN","location":"main.go:271","message":"IN 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030900564} -{"data":{"count":5},"hypothesisId":"H2_NOT_IN","location":"main.go:279","message":"NOT IN 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030900568} -{"data":{"count":3},"hypothesisId":"H2_IS_NULL","location":"main.go:287","message":"IS NULL 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030900568} -{"data":{"count":3},"hypothesisId":"H2_IS_NOT_NULL","location":"main.go:295","message":"IS NOT NULL 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030900571} -{"data":{"count":0,"query":"SELECT id,title,create_time FROM `article` WHERE create_time \u003e DATE_SUB(NOW(), INTERVAL 365 DAY) LIMIT 3 ;"},"hypothesisId":"H2_RAW_SQL","location":"main.go:307","message":"直接 SQL 片段查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030900590} -{"data":{"count":3},"hypothesisId":"H2_EXPLICIT_AND","location":"main.go:321","message":"显式 AND 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030900593} -{"data":{"count":5},"hypothesisId":"H2_OR","location":"main.go:335","message":"OR 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030900594} -{"data":{"count":5,"query":"SELECT id,title,sort,state FROM `article` WHERE ( `click_num` \u003e? OR `sort` \u003e=? ) AND `state` =? LIMIT 5 ;"},"hypothesisId":"H2_NESTED","location":"main.go:353","message":"嵌套 AND/OR 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030900597} -{"data":null,"hypothesisId":"H10_RAW_SQL","location":"main.go:872","message":"开始原生 SQL 测试 (MySQL)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030905523} -{"data":{"count":5},"hypothesisId":"H10_QUERY","location":"main.go:879","message":"Query 原生查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030905528} -{"data":{"affected":1,"name":"Exec 原生执行","result":true},"hypothesisId":"H10_EXEC","location":"main.go:899","message":"Exec 原生执行测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030905811} -{"data":null,"hypothesisId":"ALL_TESTS","location":"main.go:48","message":"开始所有测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030913581} -{"data":{"adminCount":15,"articleCount":16659,"dbType":"MySQL"},"hypothesisId":"INIT","location":"main.go:init","message":"MySQL数据库初始化检查完成","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030913625} -{"data":null,"hypothesisId":"H1_CRUD","location":"main.go:103","message":"开始基础 CRUD 测试 (MySQL)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030913625} -{"data":{"adminId":20,"query":"INSERT INTO `admin` (`title`,`create_time`,`modify_time`,`name`,`phone`,`state`,`password`,`role_id`) VALUES (?,NOW(),NOW(),?,?,?,?,?);","success":true},"hypothesisId":"H1_INSERT","location":"main.go:118","message":"Insert 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030913924} -{"data":{"admin":{"avatar_img":null,"create_time":"2026-01-21 21:28:33","id":20,"modify_time":"2026-01-21 21:28:33","name":"测试管理员_1769030913","password":"test123456","phone":"13869030913","role_id":1,"state":1,"title":"测试职位"},"success":true},"hypothesisId":"H1_GET","location":"main.go:126","message":"Get 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030913928} -{"data":{"count":3},"hypothesisId":"H1_SELECT1","location":"main.go:134","message":"Select 单条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030913930} -{"data":{"count":3,"query":"SELECT * FROM `admin` WHERE `role_id` \u003e? AND `state` =? ORDER BY id DESC LIMIT 5 ;"},"hypothesisId":"H1_SELECT2","location":"main.go:149","message":"Select 多条件自动AND测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030913933} -{"data":{"affected":1},"hypothesisId":"H1_UPDATE","location":"main.go:160","message":"Update 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914297} -{"data":{"affected":1},"hypothesisId":"H1_DELETE","location":"main.go:175","message":"Delete 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914303} -{"data":null,"hypothesisId":"H2_CONDITION","location":"main.go:188","message":"开始条件查询语法测试 (MySQL)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914303} -{"data":{"count":3},"hypothesisId":"H2_EQUAL","location":"main.go:195","message":"等于条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914311} -{"data":{"count":3,"query":"SELECT id,title,state FROM `article` WHERE `state` !=? LIMIT 3 ;"},"hypothesisId":"H2_NOT_EQUAL","location":"main.go:204","message":"不等于条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914314} -{"data":{"count":3},"hypothesisId":"H2_GREATER_LESS","location":"main.go:216","message":"大于小于条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914318} -{"data":{"count":3},"hypothesisId":"H2_GTE_LTE","location":"main.go:228","message":"大于等于小于等于条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914320} -{"data":{"count":3,"query":"SELECT id,title FROM `article` WHERE `title` LIKE ? LIMIT 3 ;"},"hypothesisId":"H2_LIKE","location":"main.go:237","message":"LIKE 模糊查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914322} -{"data":{"count":0},"hypothesisId":"H2_LIKE_RIGHT","location":"main.go:245","message":"右模糊查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914327} -{"data":{"count":3,"query":"SELECT id,title,click_num FROM `article` WHERE `click_num` BETWEEN ? AND ? LIMIT 3 ;"},"hypothesisId":"H2_BETWEEN","location":"main.go:254","message":"BETWEEN 区间查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914331} -{"data":{"count":0},"hypothesisId":"H2_NOT_BETWEEN","location":"main.go:262","message":"NOT BETWEEN 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914353} -{"data":{"count":5,"query":"SELECT id,title FROM `article` WHERE (`id` BETWEEN ? AND ? ) LIMIT 5 ;"},"hypothesisId":"H2_IN","location":"main.go:271","message":"IN 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914358} -{"data":{"count":5},"hypothesisId":"H2_NOT_IN","location":"main.go:279","message":"NOT IN 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914362} -{"data":{"count":3},"hypothesisId":"H2_IS_NULL","location":"main.go:287","message":"IS NULL 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914363} -{"data":{"count":3},"hypothesisId":"H2_IS_NOT_NULL","location":"main.go:295","message":"IS NOT NULL 查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914364} -{"data":{"count":0,"query":"SELECT id,title,create_time FROM `article` WHERE create_time \u003e DATE_SUB(NOW(), INTERVAL 365 DAY) LIMIT 3 ;"},"hypothesisId":"H2_RAW_SQL","location":"main.go:307","message":"直接 SQL 片段查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914384} -{"data":{"count":3},"hypothesisId":"H2_EXPLICIT_AND","location":"main.go:321","message":"显式 AND 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914390} -{"data":{"count":5},"hypothesisId":"H2_OR","location":"main.go:335","message":"OR 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914394} -{"data":{"count":5,"query":"SELECT id,title,sort,state FROM `article` WHERE ( `click_num` \u003e? OR `sort` \u003e=? ) AND `state` =? LIMIT 5 ;"},"hypothesisId":"H2_NESTED","location":"main.go:353","message":"嵌套 AND/OR 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914398} -{"data":null,"hypothesisId":"H3_CHAIN","location":"main.go:366","message":"开始链式查询测试 (MySQL)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914398} -{"data":{"count":16659},"hypothesisId":"H3_BASIC","location":"main.go:375","message":"基本链式查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914438} -{"data":{"count":16659},"hypothesisId":"H3_AND","location":"main.go:387","message":"链式 And 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914468} -{"data":{"count":16659},"hypothesisId":"H3_OR","location":"main.go:401","message":"链式 Or 条件测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914497} -{"data":{"count":5},"hypothesisId":"H3_ORDER","location":"main.go:413","message":"链式 Order 排序测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914521} -{"data":{"count":3},"hypothesisId":"H3_LIMIT","location":"main.go:424","message":"链式 Limit 限制测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914525} -{"data":{"article":{"author":"atestu","id":1,"title":"atestu"}},"hypothesisId":"H3_GET","location":"main.go:434","message":"链式 Get 获取单条测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914529} -{"data":{"count":16659},"hypothesisId":"H3_COUNT","location":"main.go:444","message":"链式 Count 统计测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914550} -{"data":{"count":5},"hypothesisId":"H3_PAGE","location":"main.go:455","message":"链式 Page 分页测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914554} -{"data":{"stats":[{"cnt":627,"ctg_id":null},{"cnt":36,"ctg_id":1},{"cnt":57,"ctg_id":2},{"cnt":8,"ctg_id":3},{"cnt":38,"ctg_id":4},{"cnt":11,"ctg_id":5},{"cnt":79,"ctg_id":6},{"cnt":59,"ctg_id":7},{"cnt":54,"ctg_id":8},{"cnt":1,"ctg_id":9},{"cnt":12,"ctg_id":10},{"cnt":3,"ctg_id":11},{"cnt":5,"ctg_id":12},{"cnt":1,"ctg_id":13},{"cnt":1,"ctg_id":17},{"cnt":1,"ctg_id":18},{"cnt":1,"ctg_id":19},{"cnt":10,"ctg_id":20},{"cnt":1857,"ctg_id":21},{"cnt":632,"ctg_id":22},{"cnt":4912,"ctg_id":23},{"cnt":1235,"ctg_id":24},{"cnt":1156,"ctg_id":25},{"cnt":1165,"ctg_id":26},{"cnt":111,"ctg_id":27},{"cnt":115,"ctg_id":28},{"cnt":40,"ctg_id":29},{"cnt":42,"ctg_id":30},{"cnt":76,"ctg_id":31},{"cnt":11,"ctg_id":32},{"cnt":6,"ctg_id":33},{"cnt":6,"ctg_id":34},{"cnt":185,"ctg_id":35},{"cnt":3,"ctg_id":40},{"cnt":1,"ctg_id":41},{"cnt":4,"ctg_id":43},{"cnt":28,"ctg_id":44},{"cnt":11,"ctg_id":45},{"cnt":2,"ctg_id":46},{"cnt":2,"ctg_id":48},{"cnt":5,"ctg_id":49},{"cnt":1,"ctg_id":50},{"cnt":5,"ctg_id":51},{"cnt":2,"ctg_id":52},{"cnt":52,"ctg_id":53},{"cnt":3,"ctg_id":54},{"cnt":8,"ctg_id":55},{"cnt":5,"ctg_id":57},{"cnt":8,"ctg_id":60},{"cnt":20,"ctg_id":61},{"cnt":1,"ctg_id":65},{"cnt":43,"ctg_id":66},{"cnt":46,"ctg_id":67},{"cnt":30,"ctg_id":68},{"cnt":17,"ctg_id":69},{"cnt":165,"ctg_id":70},{"cnt":29,"ctg_id":71},{"cnt":15,"ctg_id":72},{"cnt":28,"ctg_id":73},{"cnt":123,"ctg_id":76},{"cnt":6,"ctg_id":77},{"cnt":1,"ctg_id":79},{"cnt":1,"ctg_id":80},{"cnt":1,"ctg_id":81},{"cnt":23,"ctg_id":83},{"cnt":1,"ctg_id":85},{"cnt":1,"ctg_id":86},{"cnt":6,"ctg_id":87},{"cnt":2,"ctg_id":89},{"cnt":1,"ctg_id":90},{"cnt":4,"ctg_id":92},{"cnt":4,"ctg_id":93},{"cnt":2,"ctg_id":96},{"cnt":7,"ctg_id":97},{"cnt":1,"ctg_id":99},{"cnt":1,"ctg_id":100},{"cnt":1,"ctg_id":101},{"cnt":3,"ctg_id":103},{"cnt":3,"ctg_id":106},{"cnt":55,"ctg_id":107},{"cnt":2,"ctg_id":108},{"cnt":1,"ctg_id":109},{"cnt":1,"ctg_id":110},{"cnt":1,"ctg_id":111},{"cnt":5,"ctg_id":113},{"cnt":2,"ctg_id":117},{"cnt":3,"ctg_id":119},{"cnt":1,"ctg_id":123},{"cnt":2,"ctg_id":124},{"cnt":2,"ctg_id":125},{"cnt":12,"ctg_id":127},{"cnt":2,"ctg_id":131},{"cnt":1,"ctg_id":133},{"cnt":1,"ctg_id":134},{"cnt":3,"ctg_id":137},{"cnt":1,"ctg_id":138},{"cnt":3,"ctg_id":140},{"cnt":20,"ctg_id":141},{"cnt":1,"ctg_id":143},{"cnt":1,"ctg_id":144},{"cnt":1,"ctg_id":145},{"cnt":1,"ctg_id":153},{"cnt":1,"ctg_id":154},{"cnt":1,"ctg_id":155},{"cnt":3,"ctg_id":157},{"cnt":1,"ctg_id":158},{"cnt":3,"ctg_id":160},{"cnt":17,"ctg_id":161},{"cnt":1,"ctg_id":163},{"cnt":1,"ctg_id":164},{"cnt":1,"ctg_id":170},{"cnt":1,"ctg_id":173},{"cnt":1,"ctg_id":174},{"cnt":1,"ctg_id":175},{"cnt":22,"ctg_id":177},{"cnt":41,"ctg_id":179},{"cnt":3,"ctg_id":180},{"cnt":17,"ctg_id":181},{"cnt":1,"ctg_id":183},{"cnt":1,"ctg_id":184},{"cnt":1,"ctg_id":185},{"cnt":7,"ctg_id":187},{"cnt":2,"ctg_id":190},{"cnt":20,"ctg_id":191},{"cnt":7,"ctg_id":193},{"cnt":23,"ctg_id":194},{"cnt":4,"ctg_id":195},{"cnt":81,"ctg_id":196},{"cnt":3,"ctg_id":197},{"cnt":5,"ctg_id":199},{"cnt":2,"ctg_id":200},{"cnt":1,"ctg_id":201},{"cnt":25,"ctg_id":202},{"cnt":31,"ctg_id":203},{"cnt":20,"ctg_id":204},{"cnt":15,"ctg_id":205},{"cnt":7,"ctg_id":206},{"cnt":34,"ctg_id":207},{"cnt":21,"ctg_id":208},{"cnt":11,"ctg_id":213},{"cnt":3,"ctg_id":214},{"cnt":2814,"ctg_id":215},{"cnt":2,"ctg_id":216},{"cnt":1,"ctg_id":217},{"cnt":1,"ctg_id":231}]},"hypothesisId":"H3_GROUP","location":"main.go:466","message":"链式 Group 分组测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914577} -{"data":{"affected":1,"name":"链式 Update 更新","result":true},"hypothesisId":"H3_UPDATE","location":"main.go:483","message":"链式 Update 更新测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914863} -{"data":null,"hypothesisId":"H4_JOIN","location":"main.go:496","message":"开始 JOIN 查询测试 (MySQL)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914863} -{"data":{"count":5},"hypothesisId":"H4_LEFT_JOIN","location":"main.go:508","message":"LEFT JOIN 链式查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914867} -{"data":{"count":5,"query":"SELECT article.id, article.title, ctg.name as ctg_name FROM `article` LEFT JOIN `ctg` ON article.ctg_id = ctg.id WHERE article.state=? LIMIT 5 ;"},"hypothesisId":"H4_TRADITIONAL_JOIN","location":"main.go:525","message":"传统 JOIN 语法测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914872} -{"data":{"count":5},"hypothesisId":"H4_MULTI_JOIN","location":"main.go:539","message":"多表 JOIN 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914875} -{"data":{"count":5},"hypothesisId":"H4_INNER_JOIN","location":"main.go:551","message":"INNER JOIN 测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914877} -{"data":null,"hypothesisId":"H5_AGGREGATE","location":"main.go:564","message":"开始聚合函数测试 (MySQL)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914877} -{"data":{"count":16659},"hypothesisId":"H5_COUNT","location":"main.go:571","message":"Count 总数统计测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914896} -{"data":{"count":16659},"hypothesisId":"H5_COUNT_WHERE","location":"main.go:579","message":"Count 条件统计测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914918} -{"data":{"sum":499106},"hypothesisId":"H5_SUM","location":"main.go:587","message":"Sum 求和测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914941} -{"data":{"avg":29.9601},"hypothesisId":"H5_AVG","location":"main.go:595","message":"Avg 平均值测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914962} -{"data":{"max":4803},"hypothesisId":"H5_MAX","location":"main.go:603","message":"Max 最大值测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030914984} -{"data":{"min":0},"hypothesisId":"H5_MIN","location":"main.go:611","message":"Min 最小值测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030915006} -{"data":{"stats":[{"article_count":4912,"avg_clicks":"34.7453","ctg_id":23,"total_clicks":"170669"},{"article_count":2814,"avg_clicks":"24.8856","ctg_id":215,"total_clicks":"70028"},{"article_count":1857,"avg_clicks":"55.4265","ctg_id":21,"total_clicks":"102927"},{"article_count":1235,"avg_clicks":"12.1061","ctg_id":24,"total_clicks":"14951"},{"article_count":1165,"avg_clicks":"2.6704","ctg_id":26,"total_clicks":"3111"},{"article_count":1156,"avg_clicks":"16.6176","ctg_id":25,"total_clicks":"19210"},{"article_count":632,"avg_clicks":"131.1487","ctg_id":22,"total_clicks":"82886"},{"article_count":627,"avg_clicks":"2.0335","ctg_id":null,"total_clicks":"1275"},{"article_count":185,"avg_clicks":"8.6757","ctg_id":35,"total_clicks":"1605"},{"article_count":165,"avg_clicks":"0.4242","ctg_id":70,"total_clicks":"70"}]},"hypothesisId":"H5_GROUP_BY","location":"main.go:625","message":"GROUP BY 分组统计测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030915033} -{"data":null,"hypothesisId":"H6_PAGINATION","location":"main.go:638","message":"开始分页查询测试 (MySQL)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030915033} -{"data":{"count":5},"hypothesisId":"H6_PAGE_SELECT","location":"main.go:648","message":"PageSelect 分页查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030915038} -{"data":{"count":5},"hypothesisId":"H6_PAGE_2","location":"main.go:659","message":"PageSelect 第二页测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030915042} -{"data":{"count":3},"hypothesisId":"H6_CHAIN_PAGE","location":"main.go:671","message":"链式 Page 分页测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030915043} -{"data":{"count":3,"query":"SELECT id,title FROM `article` WHERE `state` =? LIMIT 3 OFFSET 2 ;"},"hypothesisId":"H6_OFFSET","location":"main.go:684","message":"Offset 偏移查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030915045} -{"data":null,"hypothesisId":"H7_BATCH","location":"main.go:697","message":"开始批量插入测试 (MySQL)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030915045} -{"data":{"affected":3,"query":"INSERT INTO `test_batch` (`name`, `state`, `title`) VALUES (?, ?, ?), (?, ?, ?), (?, ?, ?)"},"hypothesisId":"H7_BATCH_INSERT","location":"main.go:710","message":"BatchInsert 批量插入测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030915048} -{"data":{"affected":2},"hypothesisId":"H7_BATCH_RAW","location":"main.go:722","message":"BatchInsert 带 [#] 标记测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030915053} -{"data":null,"hypothesisId":"H8_UPSERT","location":"main.go:739","message":"开始 Upsert 测试 (MySQL)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030915057} -{"data":{"affected":1,"query":"INSERT INTO `admin` (`modify_time`, `name`, `phone`, `state`, `password`, `role_id`, `title`, `create_time`) VALUES (NOW(), ?, ?, ?, ?, ?, ?, NOW()) ON DUPLICATE KEY UPDATE `name` = VALUES(`name`), `state` = VALUES(`state`), `title` = VALUES(`title`), `modify_time` = NOW()"},"hypothesisId":"H8_UPSERT_INSERT","location":"main.go:763","message":"Upsert 插入新记录测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030915786} -{"data":{"affected":1},"hypothesisId":"H8_UPSERT_UPDATE","location":"main.go:783","message":"Upsert 更新已存在记录测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030916267} -{"data":null,"hypothesisId":"H9_TRANSACTION","location":"main.go:803","message":"开始事务测试 (MySQL)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030918576} -{"data":{"recordId":16},"hypothesisId":"H9_TX_INSERT","location":"main.go:818","message":"事务内插入记录","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030918580} -{"data":{"recordExists":true,"success":true},"hypothesisId":"H9_TX_SUCCESS","location":"main.go:831","message":"事务成功提交测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030918585} -{"data":{"recordId":17},"hypothesisId":"H9_TX_ROLLBACK_INSERT","location":"main.go:846","message":"事务内插入(将回滚)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030918592} -{"data":{"rolledBack":false,"success":false},"hypothesisId":"H9_TX_ROLLBACK","location":"main.go:856","message":"事务回滚测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030918598} -{"data":null,"hypothesisId":"H10_RAW_SQL","location":"main.go:872","message":"开始原生 SQL 测试 (MySQL)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030918601} -{"data":{"count":5},"hypothesisId":"H10_QUERY","location":"main.go:879","message":"Query 原生查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030918606} -{"data":{"affected":1,"name":"Exec 原生执行","result":true},"hypothesisId":"H10_EXEC","location":"main.go:899","message":"Exec 原生执行测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030918976} -{"data":{"10_raw_sql":{"name":"原生SQL测试","success":true,"tests":[{"count":5,"name":"Query 原生查询","result":true},{"affected":1,"name":"Exec 原生执行","result":true}]},"1_basic_crud":{"name":"基础CRUD测试","success":true,"tests":[{"adminId":20,"lastQuery":"INSERT INTO `admin` (`title`,`create_time`,`modify_time`,`name`,`phone`,`state`,`password`,`role_id`) VALUES (?,NOW(),NOW(),?,?,?,?,?);","name":"Insert 插入测试 (admin表)","result":true},{"admin":{"avatar_img":null,"create_time":"2026-01-21 21:28:33","id":20,"modify_time":"2026-01-21 21:28:33","name":"测试管理员_1769030913","password":"test123456","phone":"13869030913","role_id":1,"state":1,"title":"测试职位"},"name":"Get 获取单条记录测试","result":true},{"count":3,"name":"Select 单条件查询测试","result":true},{"count":3,"lastQuery":"SELECT * FROM `admin` WHERE `role_id` \u003e? AND `state` =? ORDER BY id DESC LIMIT 5 ;","name":"Select 多条件自动AND测试","result":true},{"affected":1,"name":"Update 更新测试","result":true},{"affected":1,"name":"Delete 删除测试","result":true}]},"2_condition_syntax":{"name":"条件查询语法测试","success":true,"tests":[{"count":3,"name":"等于条件 (=)","result":true},{"count":3,"lastQuery":"SELECT id,title,state FROM `article` WHERE `state` !=? LIMIT 3 ;","name":"不等于条件 ([!])","result":true},{"count":3,"name":"大于小于条件 ([\u003e], [\u003c])","result":true},{"count":3,"name":"大于等于小于等于条件 ([\u003e=], [\u003c=])","result":true},{"count":3,"lastQuery":"SELECT id,title FROM `article` WHERE `title` LIKE ? LIMIT 3 ;","name":"LIKE 模糊查询 ([~])","result":true},{"count":0,"name":"右模糊查询 ([~!])","result":true},{"count":3,"lastQuery":"SELECT id,title,click_num FROM `article` WHERE `click_num` BETWEEN ? AND ? LIMIT 3 ;","name":"BETWEEN 区间查询 ([\u003c\u003e])","result":true},{"count":0,"name":"NOT BETWEEN 查询 ([\u003e\u003c])","result":true},{"count":5,"lastQuery":"SELECT id,title FROM `article` WHERE (`id` BETWEEN ? AND ? ) LIMIT 5 ;","name":"IN 查询","result":true},{"count":5,"name":"NOT IN 查询 ([!])","result":true},{"count":3,"name":"IS NULL 查询","result":true},{"count":3,"name":"IS NOT NULL 查询 ([!])","result":true},{"count":0,"lastQuery":"SELECT id,title,create_time FROM `article` WHERE create_time \u003e DATE_SUB(NOW(), INTERVAL 365 DAY) LIMIT 3 ;","name":"直接 SQL 片段查询 ([##])","result":true},{"count":3,"name":"显式 AND 条件","result":true},{"count":5,"name":"OR 条件","result":true},{"count":5,"lastQuery":"SELECT id,title,sort,state FROM `article` WHERE ( `click_num` \u003e? OR `sort` \u003e=? ) AND `state` =? LIMIT 5 ;","name":"嵌套 AND/OR 条件","result":true}]},"3_chain_query":{"name":"链式查询测试","success":true,"tests":[{"count":16659,"name":"基本链式查询 Table().Where().Select()","result":true},{"count":16659,"name":"链式 And 条件","result":true},{"count":16659,"name":"链式 Or 条件","result":true},{"count":5,"name":"链式 Order 排序","result":true},{"count":3,"name":"链式 Limit 限制","result":true},{"article":{"author":"atestu","id":1,"title":"atestu"},"name":"链式 Get 获取单条","result":true},{"count":16659,"name":"链式 Count 统计","result":true},{"count":5,"name":"链式 Page 分页","result":true},{"name":"链式 Group 分组","result":true,"stats":[{"cnt":627,"ctg_id":null},{"cnt":36,"ctg_id":1},{"cnt":57,"ctg_id":2},{"cnt":8,"ctg_id":3},{"cnt":38,"ctg_id":4},{"cnt":11,"ctg_id":5},{"cnt":79,"ctg_id":6},{"cnt":59,"ctg_id":7},{"cnt":54,"ctg_id":8},{"cnt":1,"ctg_id":9},{"cnt":12,"ctg_id":10},{"cnt":3,"ctg_id":11},{"cnt":5,"ctg_id":12},{"cnt":1,"ctg_id":13},{"cnt":1,"ctg_id":17},{"cnt":1,"ctg_id":18},{"cnt":1,"ctg_id":19},{"cnt":10,"ctg_id":20},{"cnt":1857,"ctg_id":21},{"cnt":632,"ctg_id":22},{"cnt":4912,"ctg_id":23},{"cnt":1235,"ctg_id":24},{"cnt":1156,"ctg_id":25},{"cnt":1165,"ctg_id":26},{"cnt":111,"ctg_id":27},{"cnt":115,"ctg_id":28},{"cnt":40,"ctg_id":29},{"cnt":42,"ctg_id":30},{"cnt":76,"ctg_id":31},{"cnt":11,"ctg_id":32},{"cnt":6,"ctg_id":33},{"cnt":6,"ctg_id":34},{"cnt":185,"ctg_id":35},{"cnt":3,"ctg_id":40},{"cnt":1,"ctg_id":41},{"cnt":4,"ctg_id":43},{"cnt":28,"ctg_id":44},{"cnt":11,"ctg_id":45},{"cnt":2,"ctg_id":46},{"cnt":2,"ctg_id":48},{"cnt":5,"ctg_id":49},{"cnt":1,"ctg_id":50},{"cnt":5,"ctg_id":51},{"cnt":2,"ctg_id":52},{"cnt":52,"ctg_id":53},{"cnt":3,"ctg_id":54},{"cnt":8,"ctg_id":55},{"cnt":5,"ctg_id":57},{"cnt":8,"ctg_id":60},{"cnt":20,"ctg_id":61},{"cnt":1,"ctg_id":65},{"cnt":43,"ctg_id":66},{"cnt":46,"ctg_id":67},{"cnt":30,"ctg_id":68},{"cnt":17,"ctg_id":69},{"cnt":165,"ctg_id":70},{"cnt":29,"ctg_id":71},{"cnt":15,"ctg_id":72},{"cnt":28,"ctg_id":73},{"cnt":123,"ctg_id":76},{"cnt":6,"ctg_id":77},{"cnt":1,"ctg_id":79},{"cnt":1,"ctg_id":80},{"cnt":1,"ctg_id":81},{"cnt":23,"ctg_id":83},{"cnt":1,"ctg_id":85},{"cnt":1,"ctg_id":86},{"cnt":6,"ctg_id":87},{"cnt":2,"ctg_id":89},{"cnt":1,"ctg_id":90},{"cnt":4,"ctg_id":92},{"cnt":4,"ctg_id":93},{"cnt":2,"ctg_id":96},{"cnt":7,"ctg_id":97},{"cnt":1,"ctg_id":99},{"cnt":1,"ctg_id":100},{"cnt":1,"ctg_id":101},{"cnt":3,"ctg_id":103},{"cnt":3,"ctg_id":106},{"cnt":55,"ctg_id":107},{"cnt":2,"ctg_id":108},{"cnt":1,"ctg_id":109},{"cnt":1,"ctg_id":110},{"cnt":1,"ctg_id":111},{"cnt":5,"ctg_id":113},{"cnt":2,"ctg_id":117},{"cnt":3,"ctg_id":119},{"cnt":1,"ctg_id":123},{"cnt":2,"ctg_id":124},{"cnt":2,"ctg_id":125},{"cnt":12,"ctg_id":127},{"cnt":2,"ctg_id":131},{"cnt":1,"ctg_id":133},{"cnt":1,"ctg_id":134},{"cnt":3,"ctg_id":137},{"cnt":1,"ctg_id":138},{"cnt":3,"ctg_id":140},{"cnt":20,"ctg_id":141},{"cnt":1,"ctg_id":143},{"cnt":1,"ctg_id":144},{"cnt":1,"ctg_id":145},{"cnt":1,"ctg_id":153},{"cnt":1,"ctg_id":154},{"cnt":1,"ctg_id":155},{"cnt":3,"ctg_id":157},{"cnt":1,"ctg_id":158},{"cnt":3,"ctg_id":160},{"cnt":17,"ctg_id":161},{"cnt":1,"ctg_id":163},{"cnt":1,"ctg_id":164},{"cnt":1,"ctg_id":170},{"cnt":1,"ctg_id":173},{"cnt":1,"ctg_id":174},{"cnt":1,"ctg_id":175},{"cnt":22,"ctg_id":177},{"cnt":41,"ctg_id":179},{"cnt":3,"ctg_id":180},{"cnt":17,"ctg_id":181},{"cnt":1,"ctg_id":183},{"cnt":1,"ctg_id":184},{"cnt":1,"ctg_id":185},{"cnt":7,"ctg_id":187},{"cnt":2,"ctg_id":190},{"cnt":20,"ctg_id":191},{"cnt":7,"ctg_id":193},{"cnt":23,"ctg_id":194},{"cnt":4,"ctg_id":195},{"cnt":81,"ctg_id":196},{"cnt":3,"ctg_id":197},{"cnt":5,"ctg_id":199},{"cnt":2,"ctg_id":200},{"cnt":1,"ctg_id":201},{"cnt":25,"ctg_id":202},{"cnt":31,"ctg_id":203},{"cnt":20,"ctg_id":204},{"cnt":15,"ctg_id":205},{"cnt":7,"ctg_id":206},{"cnt":34,"ctg_id":207},{"cnt":21,"ctg_id":208},{"cnt":11,"ctg_id":213},{"cnt":3,"ctg_id":214},{"cnt":2814,"ctg_id":215},{"cnt":2,"ctg_id":216},{"cnt":1,"ctg_id":217},{"cnt":1,"ctg_id":231}]},{"affected":1,"name":"链式 Update 更新","result":true}]},"4_join_query":{"name":"JOIN查询测试","success":true,"tests":[{"count":5,"data":[{"ctg_name":null,"id":1,"title":"atestu"},{"ctg_name":null,"id":2,"title":"atestu"},{"ctg_name":null,"id":3,"title":"atestu"},{"ctg_name":null,"id":4,"title":"atestu"},{"ctg_name":"纪检监察","id":5,"title":"atestu"}],"name":"LEFT JOIN 链式查询","result":true},{"count":5,"lastQuery":"SELECT article.id, article.title, ctg.name as ctg_name FROM `article` LEFT JOIN `ctg` ON article.ctg_id = ctg.id WHERE article.state=? LIMIT 5 ;","name":"传统 JOIN 语法","result":true},{"count":5,"data":[{"admin_name":"admin","ctg_name":null,"id":1,"title":"atestu"},{"admin_name":"admin","ctg_name":null,"id":2,"title":"atestu"},{"admin_name":"admin","ctg_name":null,"id":3,"title":"atestu"},{"admin_name":"admin","ctg_name":null,"id":4,"title":"atestu"},{"admin_name":"admin","ctg_name":"纪检监察","id":5,"title":"atestu"}],"name":"多表 JOIN","result":true},{"count":5,"name":"INNER JOIN","result":true}]},"5_aggregate":{"name":"聚合函数测试","success":true,"tests":[{"count":16659,"name":"Count 总数统计","result":true},{"count":16659,"name":"Count 条件统计","result":true},{"name":"Sum 求和","result":true,"sum":499106},{"avg":29.9601,"name":"Avg 平均值","result":true},{"max":4803,"name":"Max 最大值","result":true},{"min":0,"name":"Min 最小值","result":true},{"name":"GROUP BY 分组统计","result":true,"stats":[{"article_count":4912,"avg_clicks":"34.7453","ctg_id":23,"total_clicks":"170669"},{"article_count":2814,"avg_clicks":"24.8856","ctg_id":215,"total_clicks":"70028"},{"article_count":1857,"avg_clicks":"55.4265","ctg_id":21,"total_clicks":"102927"},{"article_count":1235,"avg_clicks":"12.1061","ctg_id":24,"total_clicks":"14951"},{"article_count":1165,"avg_clicks":"2.6704","ctg_id":26,"total_clicks":"3111"},{"article_count":1156,"avg_clicks":"16.6176","ctg_id":25,"total_clicks":"19210"},{"article_count":632,"avg_clicks":"131.1487","ctg_id":22,"total_clicks":"82886"},{"article_count":627,"avg_clicks":"2.0335","ctg_id":null,"total_clicks":"1275"},{"article_count":185,"avg_clicks":"8.6757","ctg_id":35,"total_clicks":"1605"},{"article_count":165,"avg_clicks":"0.4242","ctg_id":70,"total_clicks":"70"}]}]},"6_pagination":{"name":"分页查询测试","success":true,"tests":[{"count":5,"name":"PageSelect 分页查询","result":true},{"count":5,"name":"PageSelect 第二页","result":true},{"count":3,"name":"链式 Page 分页","result":true},{"count":3,"lastQuery":"SELECT id,title FROM `article` WHERE `state` =? LIMIT 3 OFFSET 2 ;","name":"Offset 偏移查询","result":true}]},"7_batch_insert":{"name":"批量插入测试","success":true,"tests":[{"affected":3,"lastQuery":"INSERT INTO `test_batch` (`name`, `state`, `title`) VALUES (?, ?, ?), (?, ?, ?), (?, ?, ?)","name":"BatchInsert 批量插入","result":true},{"affected":2,"name":"BatchInsert 带 [#] 标记","result":true}]},"8_upsert":{"name":"Upsert测试","success":true,"tests":[{"affected":1,"lastQuery":"INSERT INTO `admin` (`modify_time`, `name`, `phone`, `state`, `password`, `role_id`, `title`, `create_time`) VALUES (NOW(), ?, ?, ?, ?, ?, ?, NOW()) ON DUPLICATE KEY UPDATE `name` = VALUES(`name`), `state` = VALUES(`state`), `title` = VALUES(`title`), `modify_time` = NOW()","name":"Upsert 插入新记录 (admin表)","result":true},{"affected":1,"name":"Upsert 更新已存在记录","result":true,"updatedAdmin":{"avatar_img":null,"create_time":"2026-01-21 21:28:35","id":21,"modify_time":"2026-01-21 21:28:35","name":"Upsert测试管理员","password":"test123","phone":"19969030915","role_id":1,"state":1,"title":"测试职位"}}]},"9_transaction":{"name":"事务测试","success":true,"tests":[{"name":"事务成功提交","recordExists":true,"result":true},{"name":"事务回滚","recordRolledBack":false,"result":true}]}},"hypothesisId":"ALL_TESTS_DONE","location":"main.go:80","message":"所有测试完成","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769030918977} +{"data":null,"hypothesisId":"START","location":"main.go:35","message":"开始 HoTimeDB 全功能测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135400} +{"data":{"argsLen":1,"query":"SELECT TABLE_NAME as name,TABLE_COMMENT as label FROM INFORMATION_SCHEMA.TABLES WHERE `TABLE_SCHEMA` =? ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135412} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135412} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135412} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135432} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135432} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135433} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135433} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135437} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135437} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135437} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135438} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135442} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135443} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135443} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135444} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135447} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135447} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135447} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135448} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135451} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135451} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135451} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135451} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135455} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135456} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135456} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135457} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135460} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135460} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135460} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135461} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135464} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135465} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135465} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135465} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135468} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135468} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135468} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135469} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135473} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135473} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135473} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135473} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135477} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135477} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135478} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135478} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135482} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135482} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135482} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135482} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135485} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135485} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135486} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135486} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135491} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135492} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135492} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135492} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135495} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135495} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135495} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135495} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135499} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135499} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135499} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135500} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135502} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135502} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135503} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135503} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135506} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135506} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135506} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135506} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135510} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135510} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135510} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135511} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135514} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135514} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135514} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135514} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135518} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135519} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135519} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135520} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135522} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135522} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135522} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135524} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135533} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135533} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135534} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135534} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135539} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135540} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135540} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135541} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135544} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135545} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135545} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135545} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135551} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135551} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135551} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135551} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135556} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135556} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135556} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135556} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135559} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135560} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135560} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135561} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135565} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135565} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135565} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135565} +{"data":{"argsLen":2,"query":"SELECT COLUMN_NAME AS name,COLUMN_TYPE AS type,COLUMN_COMMENT AS label,IS_NULLABLE AS must,COLUMN_DEFAULT AS dflt_value FROM INFORMATION_SCHEMA.COLUMNS WHERE `TABLE_NAME` =? AND `TABLE_SCHEMA` =? ORDER BY ORDINAL_POSITION ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135569} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135569} +{"data":{"argType":"string"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135569} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037135569} +{"data":null,"hypothesisId":"H10_RAW_SQL","location":"main.go:872","message":"开始原生 SQL 测试 (MySQL)","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139813} +{"data":{"argsLen":2,"query":"SELECT id, title, author FROM `article` WHERE state = ? LIMIT ?"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139813} +{"data":{"argType":"int"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139814} +{"data":{"argType":"int"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139814} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139814} +{"data":{"count":5},"hypothesisId":"H10_QUERY","location":"main.go:879","message":"Query 原生查询测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139828} +{"data":{"argsLen":1,"query":"SELECT id FROM `article` WHERE `state` =? LIMIT 1 ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139829} +{"data":{"argType":"int"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139829} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139829} +{"data":{"argsLen":1,"query":"UPDATE `article` SET modify_time = NOW() WHERE id = ?"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139836} +{"data":{"argType":"int64"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139836} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139836} +{"data":{"affected":1,"name":"Exec 原生执行","result":true},"hypothesisId":"H10_EXEC","location":"main.go:899","message":"Exec 原生执行测试","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139842} +{"data":{"ids":[1,2,3,4,5]},"hypothesisId":"H1","location":"main.go:test3","message":"H1测试开始: IN非空数组","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139842} +{"data":{"argsLen":1,"query":"SELECT id, title FROM `article` WHERE id IN (?) LIMIT 10"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139843} +{"data":{"argType":"[]int"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139843} +{"data":{"isInPattern":true,"isNotIn":false,"matchIndex":40,"prevPart":"SELECT id, title FROM `article` WHERE id IN ("},"hypothesisId":"EXPAND_IN_PATTERN","location":"query.go:expandArrayPlaceholder:inPattern","message":"IN模式检测","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139844} +{"data":{"argListLen":5,"isNotIn":false},"hypothesisId":"EXPAND_ARG_LIST","location":"query.go:expandArrayPlaceholder:argList","message":"数组转换结果","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139844} +{"data":{"argListLen":5},"hypothesisId":"EXPAND_MULTI","location":"query.go:expandArrayPlaceholder:multiArray","message":"多元素数组展开","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139845} +{"data":{"newArgsLen":5,"resultQuery":"SELECT id, title FROM `article` WHERE id IN (?, ?, ?, ?, ?) LIMIT 10"},"hypothesisId":"EXPAND_EXIT","location":"query.go:expandArrayPlaceholder:exit","message":"函数退出","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139845} +{"data":{"count":5,"data":[{"id":1,"title":"atestu"},{"id":2,"title":"atestu"},{"id":3,"title":"atestu"},{"id":4,"title":"atestu"},{"id":5,"title":"atestu"}],"lastQuery":"SELECT id, title FROM `article` WHERE id IN (?, ?, ?, ?, ?) LIMIT 10"},"hypothesisId":"H1","location":"main.go:test3","message":"H1测试结果: IN非空数组","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139849} +{"data":{"ids":[]},"hypothesisId":"H2","location":"main.go:test4","message":"H2测试开始: IN空数组","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139849} +{"data":{"argsLen":1,"query":"SELECT id, title FROM `article` WHERE id IN (?) LIMIT 10"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139850} +{"data":{"argType":"[]int"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139850} +{"data":{"isInPattern":true,"isNotIn":false,"matchIndex":40,"prevPart":"SELECT id, title FROM `article` WHERE id IN ("},"hypothesisId":"EXPAND_IN_PATTERN","location":"query.go:expandArrayPlaceholder:inPattern","message":"IN模式检测","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139851} +{"data":{"argListLen":0,"isNotIn":false},"hypothesisId":"EXPAND_ARG_LIST","location":"query.go:expandArrayPlaceholder:argList","message":"数组转换结果","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139851} +{"data":{"isNotIn":false,"matchIndex":40,"prevPart":"SELECT id, title FROM `article` WHERE ","truncateIndex":38},"hypothesisId":"EXPAND_EMPTY","location":"query.go:expandArrayPlaceholder:emptyArray","message":"空数组处理","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139851} +{"data":{"newArgsLen":0,"resultQuery":"SELECT id, title FROM `article` WHERE 1=0 LIMIT 10"},"hypothesisId":"EXPAND_EXIT","location":"query.go:expandArrayPlaceholder:exit","message":"函数退出","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139852} +{"data":{"count":0,"expected":"应包含1=0,返回0条记录","lastQuery":"SELECT id, title FROM `article` WHERE 1=0 LIMIT 10"},"hypothesisId":"H2","location":"main.go:test4","message":"H2测试结果: IN空数组","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139854} +{"data":{"ids":[]},"hypothesisId":"H3","location":"main.go:test5","message":"H3测试开始: NOT IN空数组","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139855} +{"data":{"argsLen":1,"query":"SELECT id, title FROM `article` WHERE id NOT IN (?) LIMIT 10"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139855} +{"data":{"argType":"[]int"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139855} +{"data":{"isInPattern":true,"isNotIn":true,"matchIndex":40,"prevPart":"SELECT id, title FROM `article` WHERE id NOT IN ("},"hypothesisId":"EXPAND_IN_PATTERN","location":"query.go:expandArrayPlaceholder:inPattern","message":"IN模式检测","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139856} +{"data":{"argListLen":0,"isNotIn":true},"hypothesisId":"EXPAND_ARG_LIST","location":"query.go:expandArrayPlaceholder:argList","message":"数组转换结果","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139856} +{"data":{"isNotIn":true,"matchIndex":40,"prevPart":"SELECT id, title FROM `article` WHERE ","truncateIndex":38},"hypothesisId":"EXPAND_EMPTY","location":"query.go:expandArrayPlaceholder:emptyArray","message":"空数组处理","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139856} +{"data":{"newArgsLen":0,"resultQuery":"SELECT id, title FROM `article` WHERE 1=1 LIMIT 10"},"hypothesisId":"EXPAND_EXIT","location":"query.go:expandArrayPlaceholder:exit","message":"函数退出","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139857} +{"data":{"count":10,"expected":"应包含1=1,返回所有记录(限制10条)","lastQuery":"SELECT id, title FROM `article` WHERE 1=1 LIMIT 10"},"hypothesisId":"H3","location":"main.go:test5","message":"H3测试结果: NOT IN空数组","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139858} +{"data":{"ids":[1,2,3]},"hypothesisId":"H4","location":"main.go:test6","message":"H4测试开始: NOT IN非空数组","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139859} +{"data":{"argsLen":1,"query":"SELECT id, title FROM `article` WHERE id NOT IN (?) LIMIT 10"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139859} +{"data":{"argType":"[]int"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139860} +{"data":{"isInPattern":true,"isNotIn":true,"matchIndex":40,"prevPart":"SELECT id, title FROM `article` WHERE id NOT IN ("},"hypothesisId":"EXPAND_IN_PATTERN","location":"query.go:expandArrayPlaceholder:inPattern","message":"IN模式检测","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139860} +{"data":{"argListLen":3,"isNotIn":true},"hypothesisId":"EXPAND_ARG_LIST","location":"query.go:expandArrayPlaceholder:argList","message":"数组转换结果","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139861} +{"data":{"argListLen":3},"hypothesisId":"EXPAND_MULTI","location":"query.go:expandArrayPlaceholder:multiArray","message":"多元素数组展开","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139861} +{"data":{"newArgsLen":3,"resultQuery":"SELECT id, title FROM `article` WHERE id NOT IN (?, ?, ?) LIMIT 10"},"hypothesisId":"EXPAND_EXIT","location":"query.go:expandArrayPlaceholder:exit","message":"函数退出","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139861} +{"data":{"count":10,"lastQuery":"SELECT id, title FROM `article` WHERE id NOT IN (?, ?, ?) LIMIT 10"},"hypothesisId":"H4","location":"main.go:test6","message":"H4测试结果: NOT IN非空数组","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139866} +{"data":{"limit":5,"state":0},"hypothesisId":"H5","location":"main.go:test7","message":"H5测试开始: 普通占位符","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139866} +{"data":{"argsLen":2,"query":"SELECT id, title FROM `article` WHERE state = ? LIMIT ?"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139866} +{"data":{"argType":"int"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139866} +{"data":{"argType":"int"},"hypothesisId":"EXPAND_ARG_TYPE","location":"query.go:expandArrayPlaceholder:argType","message":"参数类型检查","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139867} +{"data":null,"hypothesisId":"EXPAND_NO_ARRAY","location":"query.go:expandArrayPlaceholder:noArray","message":"无数组参数,直接返回","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139867} +{"data":{"count":5,"lastQuery":"SELECT id, title FROM `article` WHERE state = ? LIMIT ?"},"hypothesisId":"H5","location":"main.go:test7","message":"H5测试结果: 普通占位符","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139871} +{"data":null,"hypothesisId":"H2_ORM","location":"main.go:test8","message":"ORM测试开始: Select IN空数组","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139871} +{"data":{"argsLen":0,"query":"SELECT id,title FROM `article` WHERE 1=0 LIMIT 10 ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139871} +{"data":{"count":0,"lastQuery":"SELECT id,title FROM `article` WHERE 1=0 LIMIT 10 ;"},"hypothesisId":"H2_ORM","location":"main.go:test8","message":"ORM测试结果: Select IN空数组","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139874} +{"data":null,"hypothesisId":"H3_ORM","location":"main.go:test9","message":"ORM测试开始: Select NOT IN空数组","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139874} +{"data":{"argsLen":0,"query":"SELECT id,title FROM `article` LIMIT 10 ;"},"hypothesisId":"EXPAND_ENTRY","location":"query.go:expandArrayPlaceholder:entry","message":"函数入口","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139875} +{"data":{"count":10,"lastQuery":"SELECT id,title FROM `article` LIMIT 10 ;"},"hypothesisId":"H3_ORM","location":"main.go:test9","message":"ORM测试结果: Select NOT IN空数组","runId":"hotimedb-test-run","sessionId":"debug-session","timestamp":1769037139877} diff --git a/.cursor/plans/多数据库方言与前缀支持_979672ee.plan.md b/.cursor/plans/多数据库方言与前缀支持_979672ee.plan.md new file mode 100644 index 0000000..e244c73 --- /dev/null +++ b/.cursor/plans/多数据库方言与前缀支持_979672ee.plan.md @@ -0,0 +1,208 @@ +--- +name: 多数据库方言与前缀支持 +overview: 为 HoTimeDB ORM 实现完整的多数据库(MySQL/PostgreSQL/SQLite)方言支持和自动表前缀功能,同时保持完全向后兼容。 +todos: + - id: dialect-interface + content: 扩展 Dialect 接口,添加 QuoteIdentifier 和 QuoteChar 方法 + status: pending + - id: identifier-processor + content: 实现 IdentifierProcessor 结构体及其方法 + status: pending + - id: db-integration + content: 在 HoTimeDB 中集成处理器,添加辅助方法 + status: pending + - id: crud-update + content: 修改 crud.go 中的所有 CRUD 方法使用新处理器 + status: pending + - id: where-update + content: 修改 where.go 中的条件处理逻辑 + status: pending + - id: builder-update + content: 修改 builder.go 中的链式 JOIN 方法 + status: pending + - id: testing + content: 测试多数据库和前缀功能 + status: pending +--- + +# HoTimeDB 多数据库方言与自动前缀支持计划 + +## 目标 + +1. **多数据库方言支持**:让所有 ORM 方法正确支持 MySQL、PostgreSQL、SQLite 的标识符引号格式 +2. **自动表前缀**:在主表、JOIN 表、WHERE/ON 条件中自动识别并添加表前缀 +3. **完全向后兼容**:用户现有写法(`order.name`、`` `order`.name ``)无需修改 + +## 核心设计 + +### 标识符处理流程 + +```mermaid +flowchart TD + Input["用户输入: order.name 或 `order`.name"] + Parse["解析标识符"] + AddPrefix["添加表前缀"] + QuoteByDialect["根据数据库类型添加引号"] + Output["输出: `app_order`.`name` (MySQL) 或 \"app_order\".\"name\" (PG)"] + + Input --> Parse + Parse --> AddPrefix + AddPrefix --> QuoteByDialect + QuoteByDialect --> Output +``` + +## 实现步骤 + +### 第1步:扩展 Dialect 接口([db/dialect.go](db/dialect.go)) + +在现有 `Dialect` 接口中添加新方法: + +```go +// QuoteIdentifier 处理标识符(支持 table.column 格式) +// 输入: "order" 或 "order.name" 或 "`order`.name" +// 输出: 带正确引号的标识符 +QuoteIdentifier(name string) string + +// QuoteChar 获取引号字符(用于字符串中的替换检测) +QuoteChar() string +``` + +为三种数据库实现这些方法,核心逻辑: + +- 去除已有的引号(支持反引号和双引号) +- 按点号分割,对每部分单独加引号 +- MySQL 使用反引号,PostgreSQL/SQLite 使用双引号 + +### 第2步:添加标识符处理器([db/dialect.go](db/dialect.go)) + +新增 `IdentifierProcessor` 结构体: + +```go +type IdentifierProcessor struct { + dialect Dialect + prefix string +} + +// ProcessTableName 处理表名(添加前缀+引号) +func (p *IdentifierProcessor) ProcessTableName(name string) string + +// ProcessColumn 处理字段名(table.column 格式,自动给表名加前缀) +func (p *IdentifierProcessor) ProcessColumn(name string) string + +// ProcessCondition 处理 ON/WHERE 条件字符串中的 table.column +func (p *IdentifierProcessor) ProcessCondition(condition string) string +``` + +关键实现细节: + +- 使用正则表达式识别条件字符串中的 `table.column` 模式 +- 识别已有的引号包裹(`` `table`.column `` 或 `"table".column`) +- 避免误处理字符串字面量中的内容 + +### 第3步:在 HoTimeDB 中集成处理器([db/db.go](db/db.go)) + +```go +// GetProcessor 获取标识符处理器(懒加载) +func (that *HoTimeDB) GetProcessor() *IdentifierProcessor + +// processTable 内部方法:处理表名 +func (that *HoTimeDB) processTable(table string) string + +// processColumn 内部方法:处理字段名 +func (that *HoTimeDB) processColumn(column string) string +``` + +### 第4步:修改 CRUD 方法([db/crud.go](db/crud.go)) + +需要修改的方法及位置: + +| 方法 | 修改内容 | + +|------|---------| + +| `Select` (L77-153) | 表名、字段名处理 | + +| `buildJoin` (L156-222) | JOIN 表名、ON 条件处理 | + +| `Insert` (L248-302) | 表名、字段名处理 | + +| `BatchInsert` (L316-388) | 表名、字段名处理 | + +| `Update` (L598-638) | 表名、字段名处理 | + +| `Delete` (L640-661) | 表名处理 | + +核心改动模式(以 Select 为例): + +```go +// 之前 +query += " FROM `" + that.Prefix + table + "` " +// 之后 +query += " FROM " + that.processTable(table) + " " +``` + +### 第5步:修改 WHERE 条件处理([db/where.go](db/where.go)) + +修改 `varCond` 方法(L205-338)中的字段名处理: + +```go +// 之前 +if !strings.Contains(k, ".") { + k = "`" + k + "`" +} +// 之后 +k = that.processColumn(k) +``` + +同样修改 `handlePlainField`、`handleDefaultCondition` 等方法。 + +### 第6步:修改链式构建器([db/builder.go](db/builder.go)) + +`LeftJoin`、`RightJoin` 等方法中的表名和条件字符串也需要处理: + +```go +func (that *HotimeDBBuilder) LeftJoin(table, joinStr string) *HotimeDBBuilder { + // 处理表名和 ON 条件 + table = that.HoTimeDB.processTable(table) + joinStr = that.HoTimeDB.GetProcessor().ProcessCondition(joinStr) + that.Join(Map{"[>]" + table: joinStr}) + return that +} +``` + +## 安全考虑 + +1. **避免误替换数据**:条件处理只处理 SQL 语法结构中的标识符,不处理: + + - 字符串字面量内的内容(通过检测引号边界) + - 已经是占位符 `?` 的参数值 + +2. **正则表达式设计**:识别 `table.column` 模式时排除: + + - 数字开头的标识符 + - 函数调用如 `NOW()` + - 特殊运算符如 `>=`、`<=` + +## 测试要点 + +1. 多数据库类型切换 +2. 带前缀和不带前缀场景 +3. 复杂 JOIN 查询 +4. 嵌套条件查询 +5. 特殊字符和保留字作为表名/字段名 + +## 文件修改清单 + +| 文件 | 修改类型 | + +|------|---------| + +| [db/dialect.go](db/dialect.go) | 扩展接口,添加 IdentifierProcessor | + +| [db/db.go](db/db.go) | 添加 GetProcessor 和辅助方法 | + +| [db/crud.go](db/crud.go) | 修改所有 CRUD 方法 | + +| [db/where.go](db/where.go) | 修改条件处理逻辑 | + +| [db/builder.go](db/builder.go) | 修改链式构建器的 JOIN 方法 | \ No newline at end of file diff --git a/.gitignore b/.gitignore index d0b59c3..668562c 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,5 @@ /.idea/* .idea /example/tpt/demo/ -/*.exe +*.exe /example/config \ No newline at end of file diff --git a/db/crud.go b/db/crud.go index a5ab209..d8acf4d 100644 --- a/db/crud.go +++ b/db/crud.go @@ -223,15 +223,16 @@ func (that *HoTimeDB) buildJoin(joinData interface{}) string { // Get 获取单条记录 func (that *HoTimeDB) Get(table string, qu ...interface{}) Map { - if len(qu) == 1 { + if len(qu) == 0 { + // 没有参数时,添加默认字段和 LIMIT + qu = append(qu, "*", Map{"LIMIT": 1}) + } else if len(qu) == 1 { qu = append(qu, Map{"LIMIT": 1}) - } - if len(qu) == 2 { + } else if len(qu) == 2 { temp := qu[1].(Map) temp["LIMIT"] = 1 qu[1] = temp - } - if len(qu) == 3 { + } else if len(qu) == 3 { temp := qu[2].(Map) temp["LIMIT"] = 1 qu[2] = temp diff --git a/db/query.go b/db/query.go index 984ce1c..22d371b 100644 --- a/db/query.go +++ b/db/query.go @@ -1,12 +1,13 @@ package db import ( - . "code.hoteas.com/golang/hotime/common" "database/sql" "encoding/json" "errors" "reflect" "strings" + + . "code.hoteas.com/golang/hotime/common" ) // md5 生成查询的 MD5 哈希(用于缓存) @@ -23,6 +24,9 @@ func (that *HoTimeDB) Query(query string, args ...interface{}) []Map { // queryWithRetry 内部查询方法,支持重试标记 func (that *HoTimeDB) queryWithRetry(query string, retried bool, args ...interface{}) []Map { + // 预处理数组占位符 ?[] + query, args = that.expandArrayPlaceholder(query, args) + // 保存调试信息(加锁保护) that.mu.Lock() that.LastQuery = query @@ -82,6 +86,9 @@ func (that *HoTimeDB) Exec(query string, args ...interface{}) (sql.Result, *Erro // execWithRetry 内部执行方法,支持重试标记 func (that *HoTimeDB) execWithRetry(query string, retried bool, args ...interface{}) (sql.Result, *Error) { + // 预处理数组占位符 ?[] + query, args = that.expandArrayPlaceholder(query, args) + // 保存调试信息(加锁保护) that.mu.Lock() that.LastQuery = query @@ -155,6 +162,202 @@ func (that *HoTimeDB) processArgs(args []interface{}) []interface{} { return processedArgs } +// expandArrayPlaceholder 展开 IN (?) / NOT IN (?) 中的数组参数 +// 自动识别 IN/NOT IN (?) 模式,当参数是数组时展开为多个 ? +// +// 示例: +// +// db.Query("SELECT * FROM user WHERE id IN (?)", []int{1, 2, 3}) +// // 展开为: SELECT * FROM user WHERE id IN (?, ?, ?) 参数: [1, 2, 3] +// +// db.Query("SELECT * FROM user WHERE id IN (?)", []int{}) +// // 展开为: SELECT * FROM user WHERE 1=0 参数: [] (空集合的IN永假) +// +// db.Query("SELECT * FROM user WHERE id NOT IN (?)", []int{}) +// // 展开为: SELECT * FROM user WHERE 1=1 参数: [] (空集合的NOT IN永真) +// +// db.Query("SELECT * FROM user WHERE id = ?", 1) +// // 保持不变: SELECT * FROM user WHERE id = ? 参数: [1] +func (that *HoTimeDB) expandArrayPlaceholder(query string, args []interface{}) (string, []interface{}) { + if len(args) == 0 || !strings.Contains(query, "?") { + return query, args + } + + // 检查是否有数组参数 + hasArray := false + for _, arg := range args { + if arg == nil { + continue + } + argType := reflect.ValueOf(arg).Type().String() + if strings.Contains(argType, "[]") || strings.Contains(argType, "Slice") { + hasArray = true + break + } + } + if !hasArray { + return query, args + } + + newArgs := make([]interface{}, 0, len(args)) + result := strings.Builder{} + argIndex := 0 + + for i := 0; i < len(query); i++ { + if query[i] == '?' && argIndex < len(args) { + arg := args[argIndex] + argIndex++ + + if arg == nil { + result.WriteByte('?') + newArgs = append(newArgs, nil) + continue + } + + argType := reflect.ValueOf(arg).Type().String() + if strings.Contains(argType, "[]") || strings.Contains(argType, "Slice") { + // 是数组参数,检查是否在 IN (...) 或 NOT IN (...) 中 + prevPart := result.String() + prevUpper := strings.ToUpper(prevPart) + + // 查找最近的 NOT IN ( 模式 + notInIndex := strings.LastIndex(prevUpper, " NOT IN (") + notInIndex2 := strings.LastIndex(prevUpper, " NOT IN(") + if notInIndex2 > notInIndex { + notInIndex = notInIndex2 + } + + // 查找最近的 IN ( 模式(但要排除 NOT IN 的情况) + inIndex := strings.LastIndex(prevUpper, " IN (") + inIndex2 := strings.LastIndex(prevUpper, " IN(") + if inIndex2 > inIndex { + inIndex = inIndex2 + } + + // 判断是 NOT IN 还是 IN + // 注意:" NOT IN (" 包含 " IN (",所以如果找到的 IN 位置在 NOT IN 范围内,应该优先判断为 NOT IN + isNotIn := false + matchIndex := -1 + if notInIndex != -1 { + // 检查 inIndex 是否在 notInIndex 范围内(即 NOT IN 的 IN 部分) + // NOT IN ( 的 IN ( 部分从 notInIndex + 4 开始 + if inIndex != -1 && inIndex >= notInIndex && inIndex <= notInIndex+5 { + // inIndex 是 NOT IN 的一部分,使用 NOT IN + isNotIn = true + matchIndex = notInIndex + } else if inIndex == -1 || notInIndex > inIndex { + // 没有独立的 IN,或 NOT IN 在 IN 之后 + isNotIn = true + matchIndex = notInIndex + } else { + // 有独立的 IN 且在 NOT IN 之后 + matchIndex = inIndex + } + } else if inIndex != -1 { + matchIndex = inIndex + } + + // 检查 IN ( 后面是否只有空格(即当前 ? 紧跟在 IN ( 后面) + isInPattern := false + if matchIndex != -1 { + afterIn := prevPart[matchIndex:] + // 找到 ( 的位置 + parenIdx := strings.Index(afterIn, "(") + if parenIdx != -1 { + afterParen := strings.TrimSpace(afterIn[parenIdx+1:]) + if afterParen == "" { + isInPattern = true + } + } + } + + if isInPattern { + // 在 IN (...) 或 NOT IN (...) 模式中 + argList := ObjToSlice(arg) + if len(argList) == 0 { + // 空数组处理:需要找到字段名的开始位置 + // 往前找最近的 AND/OR/WHERE/(,以确定条件的开始位置 + truncateIndex := matchIndex + searchPart := prevUpper[:matchIndex] + + // 找最近的分隔符位置 + andIdx := strings.LastIndex(searchPart, " AND ") + orIdx := strings.LastIndex(searchPart, " OR ") + whereIdx := strings.LastIndex(searchPart, " WHERE ") + parenIdx := strings.LastIndex(searchPart, "(") + + // 取最靠后的分隔符 + sepIndex := -1 + sepLen := 0 + if andIdx > sepIndex { + sepIndex = andIdx + sepLen = 5 // " AND " + } + if orIdx > sepIndex { + sepIndex = orIdx + sepLen = 4 // " OR " + } + if whereIdx > sepIndex { + sepIndex = whereIdx + sepLen = 7 // " WHERE " + } + if parenIdx > sepIndex { + sepIndex = parenIdx + sepLen = 1 // "(" + } + + if sepIndex != -1 { + truncateIndex = sepIndex + sepLen + } + + result.Reset() + result.WriteString(prevPart[:truncateIndex]) + if isNotIn { + // NOT IN 空集合 = 永真 + result.WriteString(" 1=1 ") + } else { + // IN 空集合 = 永假 + result.WriteString(" 1=0 ") + } + // 跳过后面的 ) + for j := i + 1; j < len(query); j++ { + if query[j] == ')' { + i = j + break + } + } + } else if len(argList) == 1 { + // 单元素数组 + result.WriteByte('?') + newArgs = append(newArgs, argList[0]) + } else { + // 多元素数组,展开为多个 ? + for j := 0; j < len(argList); j++ { + if j > 0 { + result.WriteString(", ") + } + result.WriteByte('?') + newArgs = append(newArgs, argList[j]) + } + } + } else { + // 不在 IN 模式中,保持原有行为(数组会被 processArgs 转为逗号字符串) + result.WriteByte('?') + newArgs = append(newArgs, arg) + } + } else { + // 非数组参数 + result.WriteByte('?') + newArgs = append(newArgs, arg) + } + } else { + result.WriteByte(query[i]) + } + } + + return result.String(), newArgs +} + // Row 数据库数据解析 func (that *HoTimeDB) Row(resl *sql.Rows) []Map { dest := make([]Map, 0) diff --git a/db/where.go b/db/where.go index 4371387..270aadf 100644 --- a/db/where.go +++ b/db/where.go @@ -90,10 +90,29 @@ func (that *HoTimeDB) where(data Map) (string, []interface{}) { } // 处理普通条件字段 + // 空切片的 IN 条件应该生成永假条件(1=0),而不是跳过 if v != nil && reflect.ValueOf(v).Type().String() == "common.Slice" && len(v.(Slice)) == 0 { + // 检查是否是 NOT IN(带 [!] 后缀)- NOT IN 空数组永真,跳过即可 + if !strings.HasSuffix(k, "[!]") { + // IN 空数组 -> 生成永假条件 + if normalCondCount > 0 { + where += " AND " + } + where += "1=0 " + normalCondCount++ + } continue } if v != nil && strings.Contains(reflect.ValueOf(v).Type().String(), "[]") && len(ObjToSlice(v)) == 0 { + // 检查是否是 NOT IN(带 [!] 后缀)- NOT IN 空数组永真,跳过即可 + if !strings.HasSuffix(k, "[!]") { + // IN 空数组 -> 生成永假条件 + if normalCondCount > 0 { + where += " AND " + } + where += "1=0 " + normalCondCount++ + } continue } @@ -110,17 +129,22 @@ func (that *HoTimeDB) where(data Map) (string, []interface{}) { } // 添加 WHERE 关键字 - if len(where) != 0 { + // 先去除首尾空格,检查是否有实际条件内容 + trimmedWhere := strings.TrimSpace(where) + if len(trimmedWhere) != 0 { hasWhere := true for _, v := range vcond { - if strings.Index(where, v) == 0 { + if strings.Index(trimmedWhere, v) == 0 { hasWhere = false } } if hasWhere { - where = " WHERE " + where + " " + where = " WHERE " + trimmedWhere + " " } + } else { + // 没有实际条件内容,重置 where + where = "" } // 处理特殊字符(按固定顺序:GROUP, HAVING, ORDER, LIMIT, OFFSET) @@ -322,6 +346,8 @@ func (that *HoTimeDB) handleDefaultCondition(k string, v interface{}, where stri if reflect.ValueOf(v).Type().String() == "common.Slice" || strings.Contains(reflect.ValueOf(v).Type().String(), "[]") { vs := ObjToSlice(v) if len(vs) == 0 { + // IN 空数组 -> 生成永假条件 + where += "1=0 " return where, res } @@ -352,6 +378,8 @@ func (that *HoTimeDB) handlePlainField(k string, v interface{}, where string, re } else if reflect.ValueOf(v).Type().String() == "common.Slice" || strings.Contains(reflect.ValueOf(v).Type().String(), "[]") { vs := ObjToSlice(v) if len(vs) == 0 { + // IN 空数组 -> 生成永假条件 + where += "1=0 " return where, res } diff --git a/example/main.go b/example/main.go index 17f4bed..cf1dd76 100644 --- a/example/main.go +++ b/example/main.go @@ -1,9 +1,7 @@ package main import ( - "encoding/json" "fmt" - "os" "time" . "code.hoteas.com/golang/hotime" @@ -11,33 +9,7 @@ import ( . "code.hoteas.com/golang/hotime/db" ) -// 调试日志文件路径 -const debugLogPath = `d:\work\hotimev1\.cursor\debug.log` - -// debugLog 写入调试日志 -func debugLog(location, message string, data interface{}, hypothesisId string) { - // #region agent log - logEntry := Map{ - "location": location, - "message": message, - "data": data, - "timestamp": time.Now().UnixMilli(), - "sessionId": "debug-session", - "runId": "hotimedb-test-run", - "hypothesisId": hypothesisId, - } - jsonBytes, _ := json.Marshal(logEntry) - f, err := os.OpenFile(debugLogPath, os.O_APPEND|os.O_CREATE|os.O_WRONLY, 0644) - if err == nil { - f.WriteString(string(jsonBytes) + "\n") - f.Close() - } - // #endregion -} - func main() { - debugLog("main.go:35", "开始 HoTimeDB 全功能测试", nil, "START") - appIns := Init("config/config.json") appIns.SetConnectListener(func(that *Context) (isFinished bool) { return isFinished @@ -49,7 +21,6 @@ func main() { // 测试入口 - 运行所有测试 "all": func(that *Context) { results := Map{} - debugLog("main.go:48", "开始所有测试", nil, "ALL_TESTS") // 初始化测试表 initTestTables(that) @@ -84,16 +55,13 @@ func main() { // 10. 原生 SQL 测试 results["10_raw_sql"] = testRawSQL(that) - debugLog("main.go:80", "所有测试完成", results, "ALL_TESTS_DONE") that.Display(0, results) }, // 查询数据库表结构 "tables": func(that *Context) { - debugLog("main.go:tables", "查询数据库表结构", nil, "TABLES") // 查询所有表 tables := that.Db.Query("SHOW TABLES") - debugLog("main.go:tables", "表列表", tables, "TABLES") that.Display(0, Map{"tables": tables}) }, @@ -108,7 +76,6 @@ func main() { columns := that.Db.Query("DESCRIBE " + tableName) // 查询表数据(前10条) data := that.Db.Select(tableName, Map{"LIMIT": 10}) - debugLog("main.go:describe", "表结构", Map{"table": tableName, "columns": columns, "data": data}, "DESCRIBE") that.Display(0, Map{"table": tableName, "columns": columns, "sample_data": data}) }, @@ -144,11 +111,6 @@ func initTestTables(that *Context) { adminCount := that.Db.Count("admin") articleCount := that.Db.Count("article") - debugLog("main.go:init", "MySQL数据库初始化检查完成", Map{ - "adminCount": adminCount, - "articleCount": articleCount, - "dbType": "MySQL", - }, "INIT") } // ==================== 1. 基础 CRUD 测试 ==================== @@ -156,8 +118,6 @@ func testBasicCRUD(that *Context) Map { result := Map{"name": "基础CRUD测试", "tests": Slice{}} tests := Slice{} - debugLog("main.go:103", "开始基础 CRUD 测试 (MySQL)", nil, "H1_CRUD") - // 1.1 Insert 测试 - 使用 admin 表 insertTest := Map{"name": "Insert 插入测试 (admin表)"} adminId := that.Db.Insert("admin", Map{ @@ -173,7 +133,6 @@ func testBasicCRUD(that *Context) Map { insertTest["result"] = adminId > 0 insertTest["adminId"] = adminId insertTest["lastQuery"] = that.Db.LastQuery - debugLog("main.go:118", "Insert 测试", Map{"adminId": adminId, "success": adminId > 0, "query": that.Db.LastQuery}, "H1_INSERT") tests = append(tests, insertTest) // 1.2 Get 测试 @@ -181,7 +140,6 @@ func testBasicCRUD(that *Context) Map { admin := that.Db.Get("admin", "*", Map{"id": adminId}) getTest["result"] = admin != nil && admin.GetInt64("id") == adminId getTest["admin"] = admin - debugLog("main.go:126", "Get 测试", Map{"admin": admin, "success": admin != nil}, "H1_GET") tests = append(tests, getTest) // 1.3 Select 测试 - 单条件 @@ -189,7 +147,6 @@ func testBasicCRUD(that *Context) Map { admins1 := that.Db.Select("admin", "*", Map{"state": 1, "LIMIT": 5}) selectTest1["result"] = len(admins1) >= 0 // 可能表中没有数据 selectTest1["count"] = len(admins1) - debugLog("main.go:134", "Select 单条件测试", Map{"count": len(admins1)}, "H1_SELECT1") tests = append(tests, selectTest1) // 1.4 Select 测试 - 多条件(自动 AND) @@ -203,7 +160,6 @@ func testBasicCRUD(that *Context) Map { selectTest2["result"] = true // 只要不报错就算成功 selectTest2["count"] = len(admins2) selectTest2["lastQuery"] = that.Db.LastQuery - debugLog("main.go:149", "Select 多条件自动AND测试", Map{"count": len(admins2), "query": that.Db.LastQuery}, "H1_SELECT2") tests = append(tests, selectTest2) // 1.5 Update 测试 @@ -214,7 +170,6 @@ func testBasicCRUD(that *Context) Map { }, Map{"id": adminId}) updateTest["result"] = affected > 0 updateTest["affected"] = affected - debugLog("main.go:160", "Update 测试", Map{"affected": affected}, "H1_UPDATE") tests = append(tests, updateTest) // 1.6 Delete 测试 - 使用 test_batch 表 @@ -956,6 +911,131 @@ func testRawSQL(that *Context) Map { debugLog("main.go:899", "Exec 原生执行测试", test2, "H10_EXEC") tests = append(tests, test2) + // ==================== IN/NOT IN 数组测试 ==================== + // H1: IN (?) 配合非空数组能正确展开 + test3 := Map{"name": "H1: IN (?) 非空数组展开"} + // #region agent log + debugLog("main.go:test3", "H1测试开始: IN非空数组", Map{"ids": []int{1, 2, 3, 4, 5}}, "H1") + // #endregion + articles3 := that.Db.Query("SELECT id, title FROM `article` WHERE id IN (?) LIMIT 10", []int{1, 2, 3, 4, 5}) + // #region agent log + debugLog("main.go:test3", "H1测试结果: IN非空数组", Map{ + "count": len(articles3), + "lastQuery": that.Db.LastQuery, + "data": articles3, + }, "H1") + // #endregion + test3["result"] = len(articles3) >= 0 + test3["count"] = len(articles3) + test3["lastQuery"] = that.Db.LastQuery + tests = append(tests, test3) + + // H2: IN (?) 配合空数组替换为 1=0 + test4 := Map{"name": "H2: IN (?) 空数组替换为1=0"} + // #region agent log + debugLog("main.go:test4", "H2测试开始: IN空数组", Map{"ids": []int{}}, "H2") + // #endregion + articles4 := that.Db.Query("SELECT id, title FROM `article` WHERE id IN (?) LIMIT 10", []int{}) + // #region agent log + debugLog("main.go:test4", "H2测试结果: IN空数组", Map{ + "count": len(articles4), + "lastQuery": that.Db.LastQuery, + "expected": "应包含1=0,返回0条记录", + }, "H2") + // #endregion + test4["result"] = len(articles4) == 0 // 空数组的IN应该返回0条 + test4["count"] = len(articles4) + test4["lastQuery"] = that.Db.LastQuery + test4["expected"] = "count=0, SQL应包含1=0" + tests = append(tests, test4) + + // H3: NOT IN (?) 配合空数组替换为 1=1 + test5 := Map{"name": "H3: NOT IN (?) 空数组替换为1=1"} + // #region agent log + debugLog("main.go:test5", "H3测试开始: NOT IN空数组", Map{"ids": []int{}}, "H3") + // #endregion + articles5 := that.Db.Query("SELECT id, title FROM `article` WHERE id NOT IN (?) LIMIT 10", []int{}) + // #region agent log + debugLog("main.go:test5", "H3测试结果: NOT IN空数组", Map{ + "count": len(articles5), + "lastQuery": that.Db.LastQuery, + "expected": "应包含1=1,返回所有记录(限制10条)", + }, "H3") + // #endregion + test5["result"] = len(articles5) > 0 // NOT IN空数组应该返回记录 + test5["count"] = len(articles5) + test5["lastQuery"] = that.Db.LastQuery + test5["expected"] = "count>0, SQL应包含1=1" + tests = append(tests, test5) + + // H4: NOT IN (?) 配合非空数组正常展开 + test6 := Map{"name": "H4: NOT IN (?) 非空数组展开"} + // #region agent log + debugLog("main.go:test6", "H4测试开始: NOT IN非空数组", Map{"ids": []int{1, 2, 3}}, "H4") + // #endregion + articles6 := that.Db.Query("SELECT id, title FROM `article` WHERE id NOT IN (?) LIMIT 10", []int{1, 2, 3}) + // #region agent log + debugLog("main.go:test6", "H4测试结果: NOT IN非空数组", Map{ + "count": len(articles6), + "lastQuery": that.Db.LastQuery, + }, "H4") + // #endregion + test6["result"] = len(articles6) >= 0 + test6["count"] = len(articles6) + test6["lastQuery"] = that.Db.LastQuery + tests = append(tests, test6) + + // H5: 普通 ? 占位符保持原有行为 + test7 := Map{"name": "H5: 普通?占位符不受影响"} + // #region agent log + debugLog("main.go:test7", "H5测试开始: 普通占位符", Map{"state": 0, "limit": 5}, "H5") + // #endregion + articles7 := that.Db.Query("SELECT id, title FROM `article` WHERE state = ? LIMIT ?", 0, 5) + // #region agent log + debugLog("main.go:test7", "H5测试结果: 普通占位符", Map{ + "count": len(articles7), + "lastQuery": that.Db.LastQuery, + }, "H5") + // #endregion + test7["result"] = len(articles7) >= 0 + test7["count"] = len(articles7) + test7["lastQuery"] = that.Db.LastQuery + tests = append(tests, test7) + + // 额外测试: Select ORM方法的空数组处理 + test8 := Map{"name": "ORM Select: IN空数组"} + // #region agent log + debugLog("main.go:test8", "ORM测试开始: Select IN空数组", nil, "H2_ORM") + // #endregion + articles8 := that.Db.Select("article", "id,title", Map{"id": []int{}, "LIMIT": 10}) + // #region agent log + debugLog("main.go:test8", "ORM测试结果: Select IN空数组", Map{ + "count": len(articles8), + "lastQuery": that.Db.LastQuery, + }, "H2_ORM") + // #endregion + test8["result"] = len(articles8) == 0 + test8["count"] = len(articles8) + test8["lastQuery"] = that.Db.LastQuery + tests = append(tests, test8) + + // 额外测试: Select ORM方法的NOT IN空数组处理 + test9 := Map{"name": "ORM Select: NOT IN空数组"} + // #region agent log + debugLog("main.go:test9", "ORM测试开始: Select NOT IN空数组", nil, "H3_ORM") + // #endregion + articles9 := that.Db.Select("article", "id,title", Map{"id[!]": []int{}, "LIMIT": 10}) + // #region agent log + debugLog("main.go:test9", "ORM测试结果: Select NOT IN空数组", Map{ + "count": len(articles9), + "lastQuery": that.Db.LastQuery, + }, "H3_ORM") + // #endregion + test9["result"] = len(articles9) > 0 // NOT IN 空数组应返回记录 + test9["count"] = len(articles9) + test9["lastQuery"] = that.Db.LastQuery + tests = append(tests, test9) + result["tests"] = tests result["success"] = true return result