code: def get_table_size(self):
      db = mysql.connector.connect(
          user="root",
          password="0xdata",
          host="172.16.2.178",
          database="h2o",
      )
      cursor = db.cursor()
      cursor.execute(
          " SELECT table_schema as `Database`,table_name AS `Table`,round(((data_length + index_length) / 1024 / 1024), 2) `Size in MB` "
          "FROM information_schema.TABLES ORDER BY (data_length + index_length) DESC;"
      )
  
      results = cursor.fetchall()
      widths = []
      columns = []
      pipe = "|"
      separator = "+"
  
      for cd in cursor.description:
          widths.append(max(cd[2], len(cd[0])))
          columns.append(cd[0])
  
      # Reallocate width length
      widths[0] = widths[1] = widths[2] = 50
  
      for w in widths:
          pipe += " %-" + "%ss |" % (w,)
          separator += "-" * w + "--+"
  
      print(
          "\n*****Size of every table in mysql server in MB (desc order):*****"
      )
      print(separator)
      print(pipe % tuple(columns))
      print(separator)
      for row in results:
          print(pipe % row)
      print(separator)
  
file_path: h2o-3/scripts/db_check.py
imports: import mysql.connector
label_desc: Use image node_id 6 for calling the CheckDB obj's underlying member method code with example usage: obj.get_table_size() without return types