MCPcopy Create free account
hub / github.com/apache/iotdb-client-go / printDataSet2

Function printDataSet2

example/session_pool/session_pool_example.go:705–725  ·  view source on GitHub ↗
(sds *client.SessionDataSet)

Source from the content-addressed store, hash-verified

703}
704
705func printDataSet2(sds *client.SessionDataSet) {
706 columnNames := sds.GetColumnNames()
707 for _, value := range columnNames {
708 fmt.Printf("%s\t", value)
709 }
710 fmt.Println()
711
712 for next, err := sds.Next(); err == nil && next; next, err = sds.Next() {
713 for i := int32(0); i < int32(len(columnNames)); i++ {
714 isNull, _ := sds.IsNullByIndex(i)
715
716 if isNull {
717 fmt.Printf("%v\t\t", "null")
718 } else {
719 v, _ := sds.GetStringByIndex(i)
720 fmt.Printf("%v\t\t", v)
721 }
722 }
723 fmt.Println()
724 }
725}
726
727func checkError(err error) {
728 if err != nil {

Callers 1

executeRawDataQueryFunction · 0.70

Calls 4

GetColumnNamesMethod · 0.80
IsNullByIndexMethod · 0.80
GetStringByIndexMethod · 0.80
NextMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…