Michael Sandt
04/28/2025, 1:52 PMtarget-redshift
repos that meltano endorses? Or at least graceful upgrading of columns over time?
Context: previously we were using https://github.com/transferwise/pipelinewise-target-redshift - which makes an interesting assumption that all numeric columns should get persisted as double precision
.
This isn't exactly ideal for financial information - which is the use case we're solving for.
I took a look at the version that's maintained https://github.com/TicketSwap/target-redshift - and it looks like it also makes the same assumption. https://github.com/TicketSwap/target-redshift/blob/main/target_redshift/connector.py#L237Edgar RamÃrez (Arch.dev)
04/28/2025, 10:17 PMIs there a good pattern for configuring destination column types with theYes, there is. That's what the schema _extra_ is for. The target is unfortunately not on the singer-sdk 0.45.x version, but if you are able to fork their repo to bump it, then you could use therepos that meltano endorses? Or at least graceful upgrading of columns over time?target-redshift
x-singer.decimal
string format:
extractors:
- name: <tap-yourtap>
schema:
<some_stream_id>:
<some_numeric_field>:
type: ["string", "null"]
format: x-singer.decimal
scale: ...
precision: ...
Edgar RamÃrez (Arch.dev)
04/28/2025, 10:22 PMto_sql_type
implementation to look like Snowflake's: https://github.com/MeltanoLabs/target-snowflake/blob/1a7d43a67c78189b7bba8a5335801313d9e6a9ae/target_snowflake/connector.py#L320-L329