Lines Matching refs:query
173 def QueryExec(query, stmt): argument
174 ret = query.exec_(stmt)
176 raise Exception("Query failed: " + query.lastError().text())
521 query = QSqlQuery(self.glb.db)
526 …QueryExec(query, "SELECT call_path_id, name, short_name, COUNT(calls.id), SUM(return_time - call_t…
536 while query.next():
538 insn_cnt = int(query.value(5))
539 cyc_cnt = int(query.value(6))
540 branch_count = int(query.value(7))
544 branch_count = int(query.value(5))
545 …ld_count, self.comm_id, self.thread_id, query.value(0), query.value(1), query.value(2), query.valu…
608 query = QSqlQuery(self.glb.db)
609 QueryExec(query, "SELECT thread_id, pid, tid"
613 while query.next():
614 …oItem(self.glb, self.params, self.child_count, self.dbid, query.value(0), query.value(1), query.va…
629 query = QSqlQuery(glb.db)
630 QueryExec(query, "SELECT id, comm FROM comms" + if_has_calls)
631 while query.next():
632 if not query.value(0):
634 …child_item = CallGraphLevelOneItem(glb, params, self.child_count, query.value(0), query.value(1), …
652 def FindSelect(self, value, pattern, query): argument
670 self.DoFindSelect(query, match)
672 def Found(self, query, found): argument
674 return self.FindPath(query)
677 def FindValue(self, value, pattern, query, last_value, last_pattern): argument
679 found = query.first()
681 self.FindSelect(value, pattern, query)
682 found = query.next()
683 return self.Found(query, found)
685 def FindNext(self, query): argument
686 found = query.next()
688 found = query.first()
689 return self.Found(query, found)
691 def FindPrev(self, query): argument
692 found = query.previous()
694 found = query.last()
695 return self.Found(query, found)
699 ids = self.FindValue(c.value, c.pattern, c.query, c.last_value, c.last_pattern)
701 ids = self.FindNext(c.query)
703 ids = self.FindPrev(c.query)
709 self.value, self.direction, self.pattern, self.query, self.last_value, self.last_pattern = x
754 def DoFindSelect(self, query, match): argument
755 QueryExec(query, "SELECT call_path_id, comm_id, thread_id"
763 def FindPath(self, query): argument
767 parent_id = query.value(0)
780 ids.insert(0, query.value(2))
781 ids.insert(0, query.value(1))
808 query = QSqlQuery(self.glb.db)
809 …QueryExec(query, "SELECT calls.id, name, short_name, call_time, return_time - call_time" + ipc_str…
816 while query.next():
818 insn_cnt = int(query.value(5))
819 cyc_cnt = int(query.value(6))
820 branch_count = int(query.value(7))
824 branch_count = int(query.value(5))
825 …ld_count, self.comm_id, self.thread_id, query.value(0), query.value(1), query.value(2), query.valu…
888 query = QSqlQuery(self.glb.db)
889 QueryExec(query, "SELECT thread_id, pid, tid"
893 while query.next():
894 …oItem(self.glb, self.params, self.child_count, self.dbid, query.value(0), query.value(1), query.va…
909 query = QSqlQuery(glb.db)
910 QueryExec(query, "SELECT id, comm FROM comms" + if_has_calls)
911 while query.next():
912 if not query.value(0):
914 …child_item = CallTreeLevelOneItem(glb, params, self.child_count, query.value(0), query.value(1), s…
948 def DoFindSelect(self, query, match): argument
949 QueryExec(query, "SELECT calls.id, comm_id, thread_id"
956 def FindPath(self, query): argument
960 parent_id = query.value(0)
970 ids.insert(0, query.value(2))
971 ids.insert(0, query.value(1))
1167 self.query = QSqlQuery(self.db)
1181 QueryExec(self.query, stmt)
1184 if not self.query.next():
1186 if not self.query.next():
1188 self.last_id = self.query.value(0)
1189 return self.prep(self.query)
1527 query = QSqlQuery(self.glb.db)
1529 …QueryExec(query, "SELECT cpu, to_dso_id, to_symbol_id, to_sym_offset, short_name, long_name, build…
1534 if not query.next():
1536 cpu = query.value(0)
1537 dso = query.value(1)
1538 sym = query.value(2)
1541 off = query.value(3)
1542 short_name = query.value(4)
1543 long_name = query.value(5)
1544 build_id = query.value(6)
1545 sym_start = query.value(7)
1546 ip = query.value(8)
1548 QueryExec(query, "SELECT samples.dso_id, symbol_id, sym_offset, sym_start"
1554 if not query.next():
1556 if query.value(0) != dso:
1559 bsym = query.value(1)
1560 boff = query.value(2)
1561 bsym_start = query.value(3)
1654 def BranchDataPrepBr(query, data): argument
1655 data.append(tohex(query.value(8)).rjust(16) + " " + query.value(9) + offstr(query.value(10)) +
1656 " (" + dsoname(query.value(11)) + ")" + " -> " +
1657 tohex(query.value(12)) + " " + query.value(13) + offstr(query.value(14)) +
1658 " (" + dsoname(query.value(15)) + ")")
1660 def BranchDataPrepIPC(query, data): argument
1661 insn_cnt = query.value(16)
1662 cyc_cnt = query.value(17)
1668 def BranchDataPrep(query): argument
1671 data.append(query.value(i))
1672 BranchDataPrepBr(query, data)
1675 def BranchDataPrepWA(query): argument
1677 data.append(query.value(0))
1679 data.append("{:>19}".format(query.value(1)))
1681 data.append(query.value(i))
1682 BranchDataPrepBr(query, data)
1685 def BranchDataWithIPCPrep(query): argument
1688 data.append(query.value(i))
1689 BranchDataPrepIPC(query, data)
1690 BranchDataPrepBr(query, data)
1693 def BranchDataWithIPCPrepWA(query): argument
1695 data.append(query.value(0))
1697 data.append("{:>19}".format(query.value(1)))
1699 data.append(query.value(i))
1700 BranchDataPrepIPC(query, data)
1701 BranchDataPrepBr(query, data)
2026 query = QSqlQuery(self.glb.db)
2028 ret = query.exec_(stmt)
2030 while query.next():
2031 ids.append(str(query.value(0)))
2057 query = QSqlQuery(glb.db)
2058 QueryExec(query, "SELECT id, time FROM samples ORDER BY id DESC LIMIT 1")
2059 if query.next():
2060 self.last_id = int(query.value(0))
2061 self.last_time = int(query.value(1))
2062 QueryExec(query, "SELECT time FROM samples WHERE time != 0 ORDER BY id LIMIT 1")
2063 if query.next():
2064 self.first_time = int(query.value(0))
2070 def IdBetween(self, query, lower_id, higher_id, order): argument
2071 …QueryExec(query, "SELECT id FROM samples WHERE id > " + str(lower_id) + " AND id < " + str(higher_…
2072 if query.next():
2073 return True, int(query.value(0))
2078 query = QSqlQuery(self.glb.db)
2081 QueryExec(query, "SELECT time FROM samples WHERE id = " + str(next_id))
2082 if not query.next():
2083 ok, dbid = self.IdBetween(query, lower_id, next_id, "DESC")
2085 ok, dbid = self.IdBetween(query, next_id, higher_id, "")
2089 QueryExec(query, "SELECT time FROM samples WHERE id = " + str(next_id))
2090 next_time = int(query.value(0))
2269 query = QSqlQuery(db)
2270 QueryExec(query, "SELECT name FROM selected_events WHERE id > 0 ORDER BY id")
2271 while query.next():
2272 events.append(query.value(0))
2278 query = QSqlQuery(db)
2280 QueryExec(query, "SELECT " + columns + " FROM " + table + " " + sql + " LIMIT 1")
2352 def SQLTableDataPrep(self, query, count): argument
2355 data.append(query.value(i))
2368 query = QSqlQuery(glb.db)
2370 QueryExec(query, "PRAGMA table_info(" + table_name + ")")
2371 while query.next():
2372 column_headers.append(query.value(1))
2383 …QueryExec(query, "SELECT column_name FROM information_schema.columns WHERE table_schema = '" + sch…
2384 while query.next():
2385 column_headers.append(query.value(0))
2393 def samples_view_DataPrep(self, query, count): argument
2395 data.append(query.value(0))
2397 data.append("{:>19}".format(query.value(1)))
2399 data.append(query.value(i))
2402 def samples_DataPrep(self, query, count): argument
2405 data.append(query.value(i))
2407 data.append("{:>19}".format(query.value(9)))
2409 data.append(query.value(i))
2736 query = QSqlQuery(glb.db)
2738 …QueryExec(query, "SELECT name FROM sqlite_master WHERE type IN ( 'table' , 'view' ) ORDER BY name")
2740 …QueryExec(query, "SELECT table_name FROM information_schema.tables WHERE table_schema = 'public' A…
2741 while query.next():
2742 tables.append(query.value(0))
3099 query = QSqlQuery(db)
3100 QueryExec(query, "SELECT VERSION()")
3101 if query.next():
3102 v_str = query.value(0)
3112 query = QSqlQuery(db)
3113 QueryExec(query, "SELECT sqlite_version()")
3114 if query.next():
3115 return query.value(0)