SQL = '''SELECT O.OrderNumber, O.OrderDate, TotalAmount, O.CustomerID
FROM [Order] O, Customer C
WHERE O.CustomerID = C.Id
AND C.Id = :custID'''
for row in cursor.execute(SQL, {'custID':inputid}):
print(row)
cursor.close()
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter