Skip to content
This repository has been archived by the owner on Jul 14, 2023. It is now read-only.

Delta data load generates wrong SELECT statement #187

Open
sedacrivity opened this issue Apr 22, 2022 · 1 comment
Open

Delta data load generates wrong SELECT statement #187

sedacrivity opened this issue Apr 22, 2022 · 1 comment

Comments

@sedacrivity
Copy link

Hi,

I am trying to upload a CSV data for a table which is defined like

entity UsersCompanies: ca.active, managed { key user: Association to one UsersInfo; key company: Association to one Companies; }

When doing a full load everything works fine.
When doing a delta load then an error is thrown

error: column "company" does not exist

The SQL statement generated is

STATEMENT: SELECT activeIs AS "activeIs", createdAt AS "createdAt", createdBy AS "createdBy", modifiedAt AS "modifiedAt", modifiedBy AS "modifiedBy", user_ID AS "user_ID", company_code AS "company_code" FROM UsersCompanies ALIAS_1 WHERE user = $1 AND company = $2 LIMIT 1
which indeed has the where clause fields incorrectly defined.

It seems the associations are not correctly resolved into the proper 'company_code' and 'user_ID' fields.

@luizcarlospedrosogomes
Copy link

news?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants