Kx Refinery连接及stock表数据获取问题求助
Kx Refinery连接与stock表数据获取问题解决
连接状态说明
你执行的\c :host:port 返回25 80i`是正常的连接成功标识:
25为当前连接的句柄ID80i代表使用的kdb+协议版本
getTicks函数报错的解决方向
检查函数定义
Kx Refinery无内置getTicks函数,若这是你自定义的函数,需先通过\l path/to/your/function.q加载函数定义文件;若为误写,需核对正确的函数名称。改用标准查询语法
直接使用kdb+标准语法查询stock表的时间范围数据即可,示例如下:
// 按date字段过滤 select from stock where date between (startDate; endDate) // 按时间戳字段(如time)过滤 select from stock where time between (startDate; endDate)
注意startDate和endDate需为kdb+可识别的时间格式,比如2024.01.01或2024.01.01D09:30:00。
- 校验参数定义
确认startDate和endDate已正确初始化,示例:
startDate: 2024.01.01; endDate: 2024.01.31;
内容的提问来源于stack exchange,提问作者Dhanuushri
相关产品推荐
相关产品推荐

