MCPcopy Create free account
hub / github.com/cloudspannerecosystem/spanner-cli / extractColumnNames

Function extractColumnNames

statement.go:277–283  ·  view source on GitHub ↗

extractColumnNames extract column names from ResultSetMetadata.RowType.Fields.

(fields []*pb.StructType_Field)

Source from the content-addressed store, hash-verified

275
276// extractColumnNames extract column names from ResultSetMetadata.RowType.Fields.
277func extractColumnNames(fields []*pb.StructType_Field) []string {
278 var names []string
279 for _, field := range fields {
280 names = append(names, field.GetName())
281 }
282 return names
283}
284
285// parseQueryResult parses rows and columnNames from spanner.RowIterator.
286// A caller is responsible for calling iterator.Stop().

Callers 1

parseQueryResultFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected