To convert from Python arrays to PostgreSQL quickly?
问题 This is a follow-up question to: How to cast to int array in PostgreSQL? I am thinking how to convert Python's datatype of array-array of signed integer into to int of PostgreSQL quickly: import numpy as np; # use any data format of Python here event = np.array([[1,2],[3,4]]); where [] should be replaced by {} and surrounded by ' if manually. In PostgreSQL, the following is accepted as the syntax of the datatype ... FOR EACH ROW EXECUTE PROCEDURE insaft_function('{{1,2},{3,4}}'); @JohnMee's