Skip to content

Commit

Permalink
fix fields
Browse files Browse the repository at this point in the history
  • Loading branch information
candiduslynx committed Jun 1, 2023
1 parent e54742b commit 8ab3ddd
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ github.com/apache/thrift v0.18.1 h1:lNhK/1nqjbwbiOPDBPFJVKxgDEGSepKuTh6OLiXW8kg=
github.com/apache/thrift v0.18.1/go.mod h1:rdQn/dCcDKEWjjylUeueum4vQEjG2v8v2PqriUnbr+I=
github.com/bradleyjkemp/cupaloy/v2 v2.8.0 h1:any4BmKE+jGIaMpnU8YgH/I2LPiLBufr6oMMlVBbn9M=
github.com/bradleyjkemp/cupaloy/v2 v2.8.0/go.mod h1:bm7JXdkRd4BHJk9HpwqAI8BoAY1lps46Enkdqw6aRX0=
github.com/cloudquery/arrow/go/v13 v13.0.0-20230526062000-b3fdc24ed8d6 h1:pXLimp7SeA1AiRYANtNto/uJu5aMjeXC8zeMS4BV3dg=
github.com/cloudquery/arrow/go/v13 v13.0.0-20230526062000-b3fdc24ed8d6/go.mod h1:/XatdE3kDIBqZKhZ7OBUHwP2jaASDFZHqF4puOWM8po=
github.com/cloudquery/arrow/go/v13 v13.0.0-20230531165153-1d8a95e9920c h1:C2tXw2EgIZ/I/Z0Wt7EjFrcQYQ7QDL7jwp6kyWMLLb8=
github.com/cloudquery/arrow/go/v13 v13.0.0-20230531165153-1d8a95e9920c/go.mod h1:/XatdE3kDIBqZKhZ7OBUHwP2jaASDFZHqF4puOWM8po=
github.com/cloudquery/plugin-pb-go v1.0.8 h1:wn3GXhcNItcP+6wUUZuzUFbvdL59liKBO37/izMi+FQ=
github.com/cloudquery/plugin-pb-go v1.0.8/go.mod h1:vAGA27psem7ZZNAY4a3S9TKuA/JDQWstjKcHPJX91Mc=
github.com/cloudquery/plugin-sdk/v3 v3.7.0 h1:aRazh17V+6AA00vmxPZRv2rudNEerSd3kqbyffRl6SA=
Expand Down
8 changes: 5 additions & 3 deletions parquet/write.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,12 @@ func convertSchema(sc *arrow.Schema) *arrow.Schema {
}

func convertFieldTypes(fields []arrow.Field) []arrow.Field {
for i := range fields {
fields[i].Type = transformDataType(fields[i].Type)
newFields := make([]arrow.Field, len(fields))
copy(newFields, fields)
for i := range newFields {
newFields[i].Type = transformDataType(newFields[i].Type)
}
return fields
return newFields
}

func transformDataType(t arrow.DataType) arrow.DataType {
Expand Down

0 comments on commit 8ab3ddd

Please sign in to comment.