kdb 字符串转换时如何处理特殊字符
当将值转换为字符串时(通过“string”关键字)
Ex.
t:([]stuff:`a`b`c)
select string stuff from t
从 k 函数调用时(通过 C 客户端)在最终 0a
之前添加一个奇怪的特殊字符,
0x0180
这是什么?处理它的最佳方法是什么?有没有办法得到一个没有这个特殊字符的字符串?
stuff,more
a,1.2�
b,2.3�
c,3.4�
When casting a value to a string (via "string" keyword)
Ex.
t:([]stuff:`a`b`c)
select string stuff from t
Adds a weird special character before final 0a
when calling from k function (via C client)
0x0180
What is this ? What is best way of handling it ? Is there anyway to get a string without this special character ?
stuff,more
a,1.2�
b,2.3�
c,3.4�
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
特殊字符不会出现在 aq 会话中
,因此人们假设您的问题是由 C API。由于不熟悉 API,其余内容都是推测性的。对不起。
如果您正在使用 API,也许您不需要返回表,只需要列值。
exec
是否更接近您想要的?如果是这样,您还看到您所询问的角色吗?
The special character does not appear in a q session
so one supposes your problem arises from the C API. Not being familiar with the API, the rest of this is speculative. Sorry.
If you are working through the API, perhaps you do not need a table returned, only the column values. Is
exec
perhaps closer to what you want?If so, do you still see the character you ask about?