docs: def sql_flush(self, style, tables, sequences, allow_cascade=False):
          """
          Returns a list of SQL statements required to remove all data from
          the given database tables (without actually removing the tables
          themselves).
  
          The `style` argument is a Style object as returned by either
          color_style() or no_style() in django.core.management.color.
          """
          if tables:
              # Cannot use TRUNCATE on tables that are referenced by a FOREIGN KEY
              # So must use the much slower DELETE
              from django.db import connections
              cursor = connections[self.connection.alias].cursor()
              # Try to minimize the risks of the braindeaded inconsistency in
              # DBCC CHEKIDENT(table, RESEED, n) behavior.
              seqs = []
              for seq in sequences:
                  cursor.execute("SELECT COUNT(*) FROM %s" % self.quote_name(seq["table"]))
                  rowcnt = cursor.fetchone()[0]
                  elem = {}
                  if rowcnt:
                      elem['start_id'] = 0
                  else:
                      elem['start_id'] = 1
                  elem.update(seq)
                  seqs.append(elem)
              cursor.execute("SELECT TABLE_NAME, CONSTRAINT_NAME FROM INFORMATION_SCHEMA.TABLE_CONSTRAINTS WHERE CONSTRAINT_TYPE not in ('PRIMARY KEY','UNIQUE')")
              fks = cursor.fetchall()
              sql_list = ['ALTER TABLE %s NOCHECK CONSTRAINT %s;' % \
                      (self.quote_name(fk[0]), self.quote_name(fk[1])) for fk in fks]
              sql_list.extend(['%s %s %s;' % (style.SQL_KEYWORD('DELETE'), style.SQL_KEYWORD('FROM'),
                               style.SQL_FIELD(self.quote_name(table)) ) for table in tables])
  
              if self.on_azure_sql_db:
                  import warnings
                  warnings.warn("The identity columns will never be reset " \
                                "on Windows Azure SQL Database.",
                                RuntimeWarning)
              else:
                  # Then reset the counters on each table.
                  sql_list.extend(['%s %s (%s, %s, %s) %s %s;' % (
                      style.SQL_KEYWORD('DBCC'),
                      style.SQL_KEYWORD('CHECKIDENT'),
                      style.SQL_FIELD(self.quote_name(seq["table"])),
                      style.SQL_KEYWORD('RESEED'),
                      style.SQL_FIELD('%d' % seq['start_id']),
                      style.SQL_KEYWORD('WITH'),
                      style.SQL_KEYWORD('NO_INFOMSGS'),
                      ) for seq in seqs])
  
              sql_list.extend(['ALTER TABLE %s CHECK CONSTRAINT %s;' % \
                      (self.quote_name(fk[0]), self.quote_name(fk[1])) for fk in fks])
              return sql_list
          else:
              return []