Closed SuperEdison closed 11 months ago
type AllTypes struct { F1 string `parquet:"name=f1, type=BYTE_ARRAY, convertedtype=UTF8, encoding=PLAIN_DICTIONARY"` F2 string `parquet:"name=f2, type=BYTE_ARRAY, convertedtype=UTF8, encoding=PLAIN_DICTIONARY"` } func TestClient_HandleParquet(t *testing.T) { fw, err := local.NewLocalFileWriter("all-nil.parquet") if err != nil { fmt.Println("Can't create local file", err) return } pw, err := writer.NewParquetWriter(fw, new(AllTypes), 4) if err != nil { fmt.Println("Can't create parquet writer", err) return } for i := 0; i < 10; i++ { value := &AllTypes{ F1: fmt.Sprintf("f%d", i), F2: fmt.Sprintf("f%d", i), } if err = pw.Write(value); err != nil { fmt.Println("Write error", err) } } if err = pw.WriteStop(); err != nil { fmt.Println("WriteStop error", err) return } fw.Close() }
i want to insert some data, but there is only one successful @hangxie
that's to read pq file tool problem
i want to insert some data, but there is only one successful @hangxie