Hello,
what is the proper approach to handling 0 rows select results in the function like below:
def getValues(self, ts = datetime.utcnow().strftime('%Y/%m/%d %H:%M:%S')):
cursor = self.con.cursor()
cursor.execute("select ts_mi, stddev from v_bigview where ts_mi = to_Date(:times,'YYYY/MM/DD HH24:MI:SS') " , times=ts)
tim, val = cursor.fetchone()
cursor.close()
print(current_fn_name(), "Fetched for {} values - {}".format(ts, tim, val))
return (tim, val)
thank you.