Skip to content

Commit

Permalink
Fixes some S3 to Postgres types (#2940)
Browse files Browse the repository at this point in the history
  • Loading branch information
alishakawaguchi authored Nov 13, 2024
1 parent fbf964d commit 88313a4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ CREATE TABLE IF NOT EXISTS alltypes.all_postgres_types (
bigserial_col BIGSERIAL,

-- Monetary Types
-- money_col MONEY,
money_col MONEY,

-- Character Types
char_col CHAR(10),
Expand Down Expand Up @@ -93,7 +93,7 @@ INSERT INTO alltypes.all_postgres_types (
double_precision_col,
serial_col,
bigserial_col,
-- money_col,
money_col,
char_col,
varchar_col,
text_col,
Expand Down Expand Up @@ -142,7 +142,7 @@ INSERT INTO alltypes.all_postgres_types (
123456789.123456789, -- double_precision_col
1, -- serial_col (auto-incremented, will be generated)
1, -- bigserial_col (auto-incremented, will be generated)
-- '$100.00', -- money_col
'$100.00', -- money_col
'A', -- char_col
'DEFAULT', -- varchar_col
'default', -- text_col
Expand Down
2 changes: 1 addition & 1 deletion worker/pkg/benthos/sql/json_processor.go
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ func (p *jsonToSqlProcessor) transform(path string, root any) any {
return v
}
return validJson
case "uuid":
case "money", "uuid", "time with time zone", "timestamp with time zone":
// Convert UUID []byte to string before inserting since postgres driver stores uuid bytes in different order
return string(v)
}
Expand Down

0 comments on commit 88313a4

Please sign in to comment.