def main(): dbConnect = DbConnect(BaseDAO.getDbDir()) connector = dbConnect.getConnection() baseDAO = BaseDAO(connector, g_tableName, g_columnHeaders) # testCreateAnEntry(baseDAO) testGetPriKeys(baseDAO) testSelectAnEntry(baseDAO) testSelectAllEntries(baseDAO) testSelectAColumn(baseDAO) testSelectMax(baseDAO) testSelectDistinct(baseDAO) testDelete(baseDAO) testUpdate(baseDAO)
import sys from Service.DbConnect import DbConnect from DAO.BaseDAO import BaseDAO from DAO.BarcodeDAO import BarcodeDAO from DAO.CustomerDAO import CustomerDAO from DAO.FootwearDesignDAO import FootwearDesignDAO from DAO.FootwearSelectionDAO import FootwearSelectionDAO from DAO.InventoryDAO import InventoryDAO from DAO.VirtualCartDAO import VirtualCartDAO from Tables.TableStructs import * gc_dbConnect = DbConnect("/Users/jeongwon/Desktop/University_of_Waterloo/4YDP/4B/gitdir/3.14Modules/DataBaseAccess/ProductionData.db") gc_connector = gc_dbConnect.getConnection() def populateFootwearDesignDetails(): print(sys._getframe().f_code.co_name + ": ") dao = FootwearDesignDAO(gc_connector) entries = [ ("HAUGHNEY-70", "Haughney", ".", 69.99), ("GRADUATE PNL SPM BLK CANVAS", "LACOSTE", ".", 99.99), ("UA MICRO G ELEVATE", "UNDER ARMOUR", ".", 49.99), ("FRIDOLPH-27", "FRIDOLPH", ".", 59.99), ("JACOU-70", "JACOU", ".", 59.00), ("AGREWIEL-36", "AGREWIEL", ".", 59.99), ("GRAD VULC TSP US SPM WHT", "LACOSTE", ".", 74.99),