Generate types for foreign tables
bastiaanv opened this issue · 5 comments
bastiaanv commented
Bug report
Describe the bug
When running Supabase gen typescript --db-url <URL> > database.ts
the tables that are connected via FDW to ClickHouse are not generating types
To Reproduce
- Setup FDW and create a ClickHouse handler. Then create a foreign table like this:
create foreign table glucose (
timestamp timestamp,
profile_id text,
sensor_id text,
glucose_mmol real,
glucose_mg integer
)
server clickhouse_server
options (
table 'glucose',
rowid_column 'timestamp'
);
- First create docker image:
docker run -e PG_META_DB_URL=<URL> -it supabase/postgres-meta:v0.65.0 bash
- Run generate types command:
node dist/server/app.js gen types typescript --include-schemas public > database.ts
- Notice the foreign tables are not listed in the
database.ts
Expected behavior
To have all foreign tables to be listed
System information
- OS: MacOS
- Version of Supabase-cli: 1.38.7
- Version of pgmeta: v0.65.0
- Version of Node.js: v19.6.1
thisisamir98 commented
@bastiaanv I'm also facing the same issue with my project but with stripe wrapper integration, have you found any workarounds on this?
bastiaanv commented
No I did not. Made the types myself
codingisforlosers commented
Upvoting!
zgiuricich7 commented
Also running into this issue for the stripe wrapper integration.