Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

xmin error on view #564

Open
Cbudano opened this issue Aug 5, 2024 · 5 comments
Open

xmin error on view #564

Cbudano opened this issue Aug 5, 2024 · 5 comments

Comments

@Cbudano
Copy link

Cbudano commented Aug 5, 2024

PGSync version: 3.2

Postgres version: 14.5

Elasticsearch/OpenSearch version: OpenSearch 2.13

Redis version: 6.0.16

Python version: 3.10

Problem Description:
when trying to sync a view from postgres to opensearch i'm getting the followin error

sqlalchemy.exc.ProgrammingError: (psycopg2.errors.UndefinedColumn) column v_app_portal_1.xmin does not exist
LINE 3: WHERE CAST(CAST(v_app_portal_1.xmin AS TEXT) AS BIGINT) < 23...

This is my json schema:

[

{
"database": "xxxxx",
"index": "xxxx",
"nodes": {
"table": "v_app_portal",
"base_tables": ["xxxxxx"],
"schema": "xxxxx",
"columns":
[
"sec_id",
"comp_id",
"comp_name",
"cusip",
"symbol",
"status",
"issuer_name"
],
"primary_key": ["sec_id"]
}
}
]

Error Message (if any):



@toluaina
Copy link
Owner

Is v_app_portal a view or materialized view?

@Cbudano
Copy link
Author

Cbudano commented Aug 12, 2024

hi, it is a normal view

@Cbudano
Copy link
Author

Cbudano commented Aug 12, 2024

i tried a materialized view and it worked, but now i have the issue that the base tables of the materialized view are on diferent schemas, do you have an example of how can i make it work?, materialized view in 1 schema, base tables on 3 diferent schemas.

@Cbudano
Copy link
Author

Cbudano commented Aug 13, 2024

and also, do the pks needs to be the same on all the base tables?

@douglasrehem
Copy link

I am also having problems if views.
@Cbudano were you able to solve it without changing to materialized view?

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

No branches or pull requests

3 participants