mirror of
https://github.com/mariadb-corporation/mariadb-connector-python.git
synced 2025-08-11 02:43:15 +00:00

- added a thin python wrapper around mariadb module - added constansts under mariadb.constants (CLIENT, CURSOR, INDICATOR) - bench and test are now in testing subdirectory - updated documentation
17 lines
363 B
Python
17 lines
363 B
Python
#!/usr/bin/env python3 -O
|
|
# -*- coding: utf-8 -*-
|
|
|
|
import pyperf
|
|
|
|
|
|
def select_1_mysql_user(loops, conn):
|
|
range_it = range(loops)
|
|
t0 = pyperf.perf_counter()
|
|
cursor = conn.cursor()
|
|
for value in range_it:
|
|
cursor.execute("select * from mysql.user LIMIT 1")
|
|
row = cursor.fetchall()
|
|
del cursor
|
|
|
|
return pyperf.perf_counter() - t0
|