I am seeing that most of the errors are captured i...
# troubleshooting
s
I am seeing that most of the errors are captured in the brokerResp rather than err variable. err is mostly null for all scenarios i have tested (segment error, column name error, table name error, query datatype error etc) hence it never enters err != nil block to handle any of these scenarios. Is this expected, shouldn’t all the errors be captured in err variable. How do I capture all the error scenarios. Thank you.
Copy code
query = "select * from pmm_metrics limit 10"
brokerResp, err := pinotClient.ExecuteSQL("fact_device_ux_logs", query)
if err != nil {
		fmt.Println("Suraj Pinot error", err)
	}
&{[] <nil> 0x1400008e7d0 [{305 null: 4 segments [pmm_metrics__9__10__20221005T1320Z, pmm_metrics__2__10__20221005T2125Z, pmm_metrics__17__9__20221004T2140Z, pmm_metrics__6__10__20221005T1315Z] unavailable}] map[] 14 14 28 0 0 28 0 0 0 false 0 5 0} <nil>