grr/server/grr_response_server/databases/mysql_utils.py
def NamedPlaceholders(iterable):
  """Returns named placeholders from all elements of the given iterable.

  Use this function for VALUES of MySQL INSERTs.

  To account for Iterables with undefined order (dicts before Python 3.6),
  this function sorts column names.

  Examples:
    >>> NamedPlaceholders({"password": "foo", "name": "bar"})
    u'(%(name)s, %(password)s)'

  Args:
    iterable: The iterable of strings to be used as placeholder keys.

  Returns:
    A string containing a tuple of comma-separated, sorted, named, placeholders.
  """
  placeholders = ", ".join("%({})s".format(key) for key in sorted(iterable))
  return "({})".format(placeholders)
Returns named placeholders from all elements of the given iterable.

  Use this function for VALUES of MySQL INSERTs.

  To account for Iterables with undefined order (dicts before Python 3.6),
  this function sorts column names.

  Examples:
    >>> NamedPlaceholders({"password": "foo", "name": "bar"})
    u'(%(name)s, %(password)s)'

  Args:
    iterable: The iterable of strings to be used as placeholder keys.

  Returns:
    A string containing a tuple of comma-separated, sorted, named, placeholders.
  
Returns named placeholders from all elements of the given iterable.
Use this function for VALUES of MySQL INSERTs.

To account for Iterables with undefined order (dicts before Python 3.6),
this function sorts column names.
Returns named placeholders from all elements of the given iterable . Use this function for VALUES of MySQL INSERTs . To account for Iterables with undefined order ( dicts before Python 3 . 6 ) this function sorts column names .
def NamedPlaceholders(iterable):
  placeholders = ", ".join("%({})s".format(key) for key in sorted(iterable))
  return "({})".format(placeholders)
def NamedPlaceholders ( iterable ) : placeholders = ", " . join ( "%({})s" . format ( key ) for key in sorted ( iterable ) ) return "({})" . format ( placeholders )
Returns named placeholders from all elements of the given iterable.
Returns named placeholders from all elements of the given iterable .
"""Returns named placeholders from all elements of the given iterable.

  Use this function for VALUES of MySQL INSERTs.

  To account for Iterables with undefined order (dicts before Python 3.6),
  this function sorts column names.

  Examples:
    >>> NamedPlaceholders({"password": "foo", "name": "bar"})
    u'(%(name)s, %(password)s)'

  Args:
    iterable: The iterable of strings to be used as placeholder keys.

  Returns:
    A string containing a tuple of comma-separated, sorted, named, placeholders.
  """
A string containing a tuple of comma-separated, sorted, named, placeholders.
A string containing a tuple of comma - separated sorted named placeholders .
iterable
The iterable of strings to be used as placeholder keys.
The iterable of strings to be used as placeholder keys .
examples
None