session := &vtgateproto.QueryResult{}
session.Rows = append(session.Rows, &vtgateproto.Row{ Lengths: []int64{10, 20, 30}, Values: [][]byte{ []byte("row1-value1"), []byte("row1-value2"), []byte("row1-value3"), }, })
for _, row := range session.Rows { for i, value := range row.Values { fmt.Printf("row %d, column %d: %v\n", i, value) } }Overall, the QueryResult Session is a useful data structure for managing query results in the Vitess system. The code examples show how to create a new session, add rows to it, and iterate through the rows to retrieve the results.