import pickle def saveDbase(filename, table): file = open(filename, 'w') pickle.dump(table, file) # pickle to file file.close() def loadDbase(filename): file = open(filename, 'r') table = pickle.load(file) # unpickle from file file.close() return table