code: def add_data(db, table, values):
      v = db.OpenView("SELECT * FROM `%s`" % table)
      count = v.GetColumnInfo(MSICOLINFO_NAMES).GetFieldCount()
      r = CreateRecord(count)
      for value in values:
          assert len(value) == count, value
          for i in range(count):
              field = value[i]
              if isinstance(field, int):
                  r.SetInteger(i + 1, field)
              elif isinstance(field, str):
                  r.SetString(i + 1, field)
              elif field is None:
                  pass
              elif isinstance(field, Binary):
                  r.SetStream(i + 1, field.name)
              else:
                  raise TypeError(
                      "Unsupported type %s" % field.__class__.__name__
                  )
          try:
              v.Modify(MSIMODIFY_INSERT, r)
          except Exception:
              raise MSIError(
                  "Could not insert " + repr(values) + " into " + table
              )
  
          r.ClearData()
      v.Close()
  
imports: from _msi import *
  import fnmatch
  import os
  import re
  import string
  import sys
  import warnings
label_desc: Use image node_id 2 for calling a global function with example usage: add_data(db, table, values) without return types