diff SMART/Java/Python/mySql/MySqlConnection.py @ 46:169d364ddd91

Uploaded
author m-zytnicki
date Mon, 30 Sep 2013 03:19:26 -0400
parents 44d5973c188c
children
line wrap: on
line diff
--- a/SMART/Java/Python/mySql/MySqlConnection.py	Wed Sep 18 08:51:22 2013 -0400
+++ b/SMART/Java/Python/mySql/MySqlConnection.py	Mon Sep 30 03:19:26 2013 -0400
@@ -88,18 +88,6 @@
             self.connection.commit()
 
 
-    def executeManyFormattedQueries(self, command, lines, insertion = False):
-        cursor = self.connection.cursor()
-        query = MySqlQuery(cursor, self.verbosity)
-        for line in lines:
-            result = query.executeFormat(command, line)
-        self.connection.commit()
-        if insertion:
-            return result
-        else:
-            return query
-
-
     def executeManyQueriesIterator(self, table):
         cursor = self.connection.cursor()
         query = MySqlQuery(cursor, self.verbosity)
@@ -113,25 +101,9 @@
             self.connection.commit()
 
 
-    def executeManyFormattedQueriesIterator(self, table):
+    def executeFormattedQuery(self, command, *parameters):
         cursor = self.connection.cursor()
         query = MySqlQuery(cursor, self.verbosity)
-        try:
-            for command, values in table.getIterator():
-                query.executeFormat(command, values)
-            self.connection.commit()
-        except:
-            for command, values in table.getIterator():
-                query.execute(command, values)
-            self.connection.commit()
-
-
-    def executeFormattedQuery(self, command, parameters, insertion = False):
-        cursor = self.connection.cursor()
-        query = MySqlQuery(cursor, self.verbosity)
-        result = query.executeFormat(command, parameters)
+        query.executeFormat(command, parameters)
         self.connection.commit()
-        if insertion:
-            return result
-        else:
-            return query
\ No newline at end of file
+        return query