MeltanoLabs / meltano-map-transform

A map transformer which implements the `Stream Maps` capability from Meltano's tap and target SDK: https://sdk.meltano.com/
Apache License 2.0
18 stars 16 forks source link

test: Use env vars to alias a stream #297

Closed edgarrmondragon closed 1 month ago

edgarrmondragon commented 2 months ago

A little hacky, but does the trick:

MELTANO_MAP_TRANSFORMER_STREAM_MAPS_CUSTOMERS___ALIAS__=new_name meltano run tap-csv uses_env_vars target-sqlite
$ sqlite3 -markdown output/tap_csv.db 'select * from new_name limit 3'
|        email         | first_name | id |   ip_address   | last_name |        __loaded_at         |
|----------------------|------------|----|----------------|-----------|----------------------------|
| ebook0@twitter.com   | Ethe       | 1  | 67.61.243.220  | Book      | 2024-09-12 20:09:53.130891 |
| mtire1@vkontakte.ru  | Myranda    | 2  | 151.194.73.229 | Tire      | 2024-09-12 20:09:53.130924 |
| rdorian2@twitpic.com | Remus      | 3  | 204.220.73.121 | Dorian    | 2024-09-12 20:09:53.130949 |

In response to https://meltano.slack.com/archives/C06A1MD6A6L/p1726054308298569.

sonarcloud[bot] commented 1 month ago

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
0.0% Coverage on New Code
0.0% Duplication on New Code

See analysis details on SonarCloud