def get_all_companies_stock(self): result = self.db.query("select Symbol from company_info;") if result: l = [] for i in range(len(result)): c = Company_base() c.set_symbol(result[i]['Symbol']) l.append(c) return l
def get_ask_comp(self, symbols): result = self.db.query("select symbol, ask from company_info where symbol in (" + symbols + ");") if result: l = [] for i in range(len(result)): c = Company_base() c.set_ask(result[i]['ask']) c.set_symbol(result[i]['symbol']) l.append(c) return l
def get_all_ask(self): result = self.db.query("select Symbol, Name, Ask from company_info;") if result: l = [] for i in range(len(result)): if result[i]['Ask'] != None: c = Company_base() c.set_name(result[i]['Name']) c.set_ask(result[i]['Ask']) c.set_symbol(result[i]['Symbol']) l.append(c) return l
def get_all_ask(self): result = self.db.query("select Symbol, Name, Ask from company_info;") if result: l=[] for i in range(len(result)): if result[i]['Ask'] != None: c = Company_base() c.set_name(result[i]['Name']) c.set_ask(result[i]['Ask']) c.set_symbol(result[i]['Symbol']) l.append(c) return l
def get_ask_comp(self, symbols): result = self.db.query( "select symbol, ask from company_info where symbol in (" + symbols + ");") if result: l = [] for i in range(len(result)): c = Company_base() c.set_ask(result[i]['ask']) c.set_symbol(result[i]['symbol']) l.append(c) return l