Skip to content

Change View Doesn't exist in the postgres #219

@kotha32

Description

@kotha32

Hello there,

I am using Change Tracking for data deletion and updates in an application, but I am encountering the following error:

"msg": "500 - error: relation \"konnekt_changeview\" does not exist\n    at /home/vcap/app/node_modules/pg/lib/client.js:545:17\n    at async Object.all (/home/vcap/app/node_modules/@cap-js/postgres/lib/PostgresService.js:176:26)\n    at async PostgresService.onSELECT (/home/vcap/app/node_modules/@cap-js/db-service/lib/SQLService.js:146:72)\n    at async next (/home/vcap/app/node_modules/@sap/cds/lib/srv/srv-dispatch.js:57:17)\n    at async PostgresService.handle (/home/vcap/app/node_modules/@sap/cds/lib/srv/srv-dispatch.js:55:10)\n    at async ApplicationService.handle_crud_requests (/home/vcap/app/node_modules/@sap/cds/libx/_runtime/common/generic/crud.js:57:20)\n    at async next (/home/vcap/app/node_modules/@sap/cds/lib/srv/srv-dispatch.js:57:17)\n    at async ApplicationService.handle (/home/vcap/app/node_modules/@sap/cds/lib/srv/srv-dispatch.js:55:10) {\n  length: 118,\n  severity: 'ERROR',\n  code: '42P01',\n  detail: undefined,\n  hint: undefined,\n  position: '754',\n  internalPosition: undefined,\n  internalQuery: undefined,\n  where: undefined,\n  schema: undefined,\n  table: undefined,\n  column: undefined,\n  dataType: undefined,\n  constraint: undefined,\n  file: 'parse_relation.c',\n  line: '1452',\n  routine: 'parserOpenTable',\n  query: `SELECT to_jsonb(\"$c\".*) as _json_ FROM (SELECT \"$c\".ID as \"ID\",\"$c\".attribute as \"attribute\",to_char(\"$c\".createdAt, 'YYYY-MM-DD\"T\"HH24:MI:SS.FF3\"Z\"') as \"createdAt\",\"$c\".createdBy as \"createdBy\",\"$c\".entity as \"entity\",\"$c\".modification as \"modification\",\"$c\".objectID as \"objectID\",\"$c\".parentKey as \"parentKey\",\"$c\".serviceEntity as \"serviceEntity\",\"$c\".serviceEntityPath as \"serviceEntityPath\",\"$c\".valueChangedFrom as \"valueChangedFrom\",\"$c\".valueChangedTo as \"valueChangedTo\",\"$c\".valueDataType as \"valueDataType\" FROM (SELECT \"$c\".ID,\"$c\".attribute,\"$c\".createdAt,\"$c\".createdBy,\"$c\".entity,\"$c\".modification,\"$c\".objectID,\"$c\".parentKey,\"$c\".serviceEntity,\"$c\".serviceEntityPath,\"$c\".valueChangedFrom,\"$c\".valueChangedTo,\"$c\".valueDataType FROM Konnekt_ChangeView as \"$c\" WHERE exists (SELECT 1 as \"1\" FROM Konnekt_BillingDocuments as \"$b\" WHERE \"$c\".entityKey = \"$b\".ID and \"$b\".ID = $1) ORDER BY createdAt DESC NULLS LAST,ID ASC NULLS FIRST LIMIT $2 OFFSET $3) as \"$c\") as \"$c\"\n` +\n    ' ^'\n}",

Could you please help me resolve this issue as soon as possible?

This Issue in SAP CAPM

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions