Skip to content

Can i have oracle and postgres in subselect query inside select ? #1959

@pcouas

Description

@pcouas

Hello

I'm planning to use ora2pG to migrate a table A.

REPLACE_TABLES tableoracle:table_postgres_1

Columns to keep

COLUMNS table_postgres_1:ref_pays,libelle,code_pays,date_maj,user_maj

REPLACE_QUERY tableoracle[
SELECT TO_NUMBER(a.reference_pays),
a.libelle_pays,
a.code_pays,
a.date_maj,
a.user_maj
FROM tableoracle a
WHERE a.code_pays IS NOT NULL

]

But can I also have a link with another Postgres table, "table2postgres2"?
REPLACE_QUERY tableoracle[
SELECT TO_NUMBER(a.reference_pays),
a.libelle_pays,
a.code_pays,
a.date_maj,

a.user_maj,
(SELECT column
FROM table2postgres2 t2
WHERE t2.id = a.id) AS alias)

FROM tableoracle a
WHERE a.country_code IS NOT NULL
]

Regards
Phil

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions