4paradigm / 4paradigm/OpenMLDB
api server: query with null input
- 主要语言
- C++
- 星标
- 1.7k
- 派生
- 331
- 平均合并
- 12 天 12 小时
- 30 天内合并 PR
- 1
描述
```sh
> curl -X POST http://127.0.0.1:9527/dbs/test_db -d '{"mode":"online","sql": "select * from tx where id = ?", "input": {"schema": ["int16"], "data": [null]}}'
{"code":-1,"msg":"Json parse failed, INVALID_ARGUMENT: append failed on 0 type 1"}⏎
```
贡献指南
调研方向
The issue shows a curl command that fails when querying with a null input parameter. Start by examining the API server code that handles POST requests to /dbs/{db_name}, likely in a file like server/api_server.cc. Look for the SQL parsing and parameter binding logic, particularly how the 'input' field with schema and data is processed. The error message suggests a type mismatch or append failure when handling null for an int16 parameter. Check the data type handling and null value serialization in the database engine. Running the provided curl command against a local instance will reproduce the error.
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- sql
- 领域
- api, backend, databases
- Issue 类型
- 缺陷
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 活跃度
- 停滞
- 描述清晰度
- 基本清楚
- 新手友好度
- 45/100