Uploaded image for project: 'RAML Module Builder'
  1. RAML Module Builder
  2. RMB-476

PgUtil.post: Return after-trigger value (INSERT ... RETURNING jsonb)

    XMLWordPrintable

Details

    • CP: sprint 74
    • 3
    • Core: Platform

    Description

      PgUtil.post returns the inserted entity, but it returns the entity data before any INSERT triggers were applied. Returning this data doesn't make sense because the client already knows them.
      Change the SQL to INSERT ... RETURNING jsonb so that it returns that entity data after the INSERT triggers were applied. This is very fast and avoids an additional SELECT round-trip.

      This was requested on https://github.com/folio-org/mod-inventory-storage/pull/327/files#r326601328

      TestRail: Results

        Attachments

          Issue Links

            Activity

              People

                hji Hongwei Ji
                julianladisch Julian Ladisch
                Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved:

                  TestRail: Runs

                    TestRail: Cases