Postgres vector computation. ERROR on Alibaba Cloud

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Andrea1701
    New Member
    • Nov 2017
    • 34

    Postgres vector computation. ERROR on Alibaba Cloud

    Postgres vector computation. ERROR: row is too big: size 16392, maximum size 8160
    Database version: Postgres 10.3
    OS: CentOS 7
    Recently, I have been looking at Postgres VOPS. When I used the populate function of VOPS to convert data from the primitive data type table to the VOPS data type table, I got the the following error prompt:
    select populate(destin ation:='vops_ta ble'::regclass, source:='std_ta ble'::regclass)
    ERROR: row is too big: size 16392, maximum size 8160
    The data type of my primitive data type table is int2 int4 int8 float4, with 64 fields, and 27,855 rows in total.
    When I run SELECT pg_column_size( t.*) FROM std_table AS t; the minimal result is 122, and the maximum result is 240, averaged at 157.52.
    Please can anyone tell me how I can solve this problem?
    P.S.: 1) I searched on the internet and someone said that the Postgres data block size is 8 Kb. Does the problem have something to do with this size limit? If so, how can I increase the data block size?
    2) Do the “blocks” of a database and the “pages” of an operating system refer to the same thing? I tried to set hugePage in CentOS 7 and huge_pages = on in the postgresql.conf file of Postgre.
    After I restarted the VOPS extension and executed the populate function, the error persisted.
  • TimoHa
    New Member
    • Nov 2017
    • 22

    #2
    In PostgreSQL, the data block size is 8 Kb. This value can be specified at initdb.
    In this case, the “block” of a database has little to do with the “page” of an operating system.
    I guess the problem is because you used the Plain mode to store the table during conversion. In this mode, each record cannot exceed the size of a page. See https://www.postgresql.org/docs/curr...ltertable.html for details.
    I recommend you use Toast tables.

    Comment

    • TimoHa
      New Member
      • Nov 2017
      • 22

      #3
      In PostgreSQL, the data block size is 8 Kb. This value can be specified at initdb.
      In this case, the “block” of a database has little to do with the “page” of an operating system.
      I guess the problem is because you used the Plain mode to store the table during conversion. In this mode, each record cannot exceed the size of a page. See https://www.postgresql.org/docs/curr...ltertable.html for details.
      I recommend you use Toast tables.

      Comment

      Working...