On Wed, 06 May 2020 15:39:24 +0200 Ingeborg Hellemo ingeborg.hellemo@uit.no wrote:
sql/changes/sc.05.00.0010.sql: operator is not unique: unknown || integer LINE 29: 'SNMP v' || snmp_version || ' read profile #' || row AS na... ^ HINT: Could not choose a best candidate operator. You might need to add explicit type casts.
Server version Postgresql 9.6.17
Since this is a newly created database with imported data it might be missing some environment variables or something.
This has worked successfully on every other installation I've had the pleasure of fiddling with, so I'm not quite sure why it would be a problem on your PostgreSQL server. Our versions are the same, and the catalog of `||` operators is the same.
What puzzles me is that the 'SNMP v' value seems to be listed as an "unknown" type in the error message.
You might want to try to explicitly cast the integers in the concatenation to text, and see if that helps your PostgreSQL select the correct operator from the catalog.
Something like:
'SNMP v' || snmp_version::TEXT || ' read profile #' || row::TEXT AS name,