【发布时间】:2019-11-08 09:41:48
【问题描述】:
我得到了“1,2,3,4,5”作为参数。我想在没有东西的地方使用它(1,2,3,4,5) 如何在程序内部转换?
【问题讨论】:
标签: sql postgresql split type-conversion
我得到了“1,2,3,4,5”作为参数。我想在没有东西的地方使用它(1,2,3,4,5) 如何在程序内部转换?
【问题讨论】:
标签: sql postgresql split type-conversion
您可以将其转换为数组:
where something <> ALL (string_to_array('1,2,3,4,5', ',')::int[])
假设something 是一个整数。
【讨论】: