Compare commits
4 commits
feature/pr
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b1a9657d8e | ||
|
|
4c65bf7297 | ||
|
|
730df7b534 | ||
|
|
51c6a932dd |
3 changed files with 11 additions and 2 deletions
8
CHANGELOG.MD
Normal file
8
CHANGELOG.MD
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
# Changelog
|
||||
|
||||
## [0.2.0] - 2022-07-26
|
||||
|
||||
### Added
|
||||
- Sessions will now print the number of rows obtained from each successfully executed query.
|
||||
- The tool version is now printed at the beginning of each session to leave a proper trace of what was the running
|
||||
version for a results file.
|
||||
|
|
@ -1 +1 @@
|
|||
__version__ = "latest"
|
||||
__version__ = "0.2.0"
|
||||
|
|
|
|||
|
|
@ -61,6 +61,7 @@ def measure_query_runtime(
|
|||
cur = connection.cursor()
|
||||
cur.execute(query_to_measure.query_string)
|
||||
rows = cur.fetchall()
|
||||
obtained_rows = len(rows)
|
||||
print(
|
||||
f"Query '{query_to_measure.name}' took {int(time.time() - start_time)} seconds to run."
|
||||
f"Query '{query_to_measure.name}' took {int(time.time() - start_time)} seconds to run and returned {obtained_rows} rows."
|
||||
)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue