4paradigm / 4paradigm/OpenMLDB
api server: query with null input
- Ngôn ngữ chính
- C++
- Star
- 1.7k
- Fork
- 331
- Merge trung bình
- 12 ngày 12 giờ
- Pull request đã merge (30 ngày)
- 1
Mô tả
```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"}⏎
```
Hướng dẫn đóng góp
Hướng nghiên cứu
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.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- sql
- Lĩnh vực
- api, backend, databases
- Loại issue
- Lỗi
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Khá rõ ràng
- Mức phù hợp với người mới
- 45/100