habe folgendes problem...
ich hab eine db in mysql
dann hab ich den python code...
Code: Alles auswählen
def GetTables(self):
""" returns a list with the table names """
tables = self.connection.execute('SHOW TABLES');
tableArray = []
for row in tables:
tableArray.append(row.Tables_in_fbuch)
return tableArray
ich will des allerdings dynamisch haben..
wenn ich also mal ein anderes dbmodell hab, welches z.b. adrbuch heißt, wird ja dann bei dem befehl "show tables" des ausgegeben "Tables_in_adrbuch"
Wie bekomm ich des in eine variable rein, dass ich die dann in die for-schleife einbaun kann?
gruß
bj