Skip to content

Commit 6e6706a

Browse files
committed
better header for schemaless tables
1 parent f7f1dab commit 6e6706a

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/TableView.jl

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,12 +20,11 @@ function _showtable(table, dark)
2020
rows = Tables.rows(table)
2121
schema = Tables.schema(table)
2222
if schema === nothing
23-
names = []
2423
types = []
2524
for (i, c) in enumerate(Tables.eachcolumn(first(rows)))
26-
push!(names, string(i))
2725
push!(types, typeof(c))
2826
end
27+
names = collect(propertynames(first(rows)))
2928
else
3029
names = schema.names
3130
types = schema.types

0 commit comments

Comments
 (0)