input: Write a function to convert the given SQL query into a Python program. The function should establish a connection to the database, execute the SQL query with the given condition, and print the results. The SQL query selects all records from the 'orders' table where the 'order_date' is in the year 2020. If no records are found, the function should handle the case appropriately without raising errors.
  
  def convert_sql_to_python():
      import datetime, pyodbc
  
      # Establish a connection to the database
      conn = pyodbc.connect("<connection details>")
      cursor = conn.cursor()
  
      # Get the year of the order date
      sql = "SELECT * FROM orders"
      query_date = datetime.date.today().year
      where_clause = "WHERE YEAR(order_date) = ?"
  
      # Execute the query
      cursor.execute(sql + " " + where_clause, query_date)
      results = cursor.fetchall()
  
      # Output the results
      for result in results:
          print(result)
  
  assert convert_sql_to_python() # No assert statement needed as the function prints results
  assert convert_sql_to_python() # Test case for no records found, should not raise an error
output: def convert_sql_to_python():
      import datetime, pyodbc
  
      conn = pyodbc.connect("<connection details>")
      cursor = conn.cursor()
  
      sql = "SELECT * FROM orders"
      query_date = 2020
      where_clause = "WHERE YEAR(order_date) = ?"
  
      cursor.execute(sql + " " + where_clause, query_date)
      results = cursor.fetchall()
  
      for result in results:
          print(result)