MCPcopy Create free account
hub / github.com/OpenRaiser/PaperFlow / show_table_data

Function show_table_data

scripts/view_db.py:36–42  ·  view source on GitHub ↗
(table_name, limit=10)

Source from the content-addressed store, hash-verified

34
35
36def show_table_data(table_name, limit=10):
37 conn = connect()
38 cursor = conn.cursor()
39 cursor.execute(f"SELECT * FROM {table_name} LIMIT {limit}")
40 rows = cursor.fetchall()
41 conn.close()
42 return rows
43
44
45def show_count(table_name):

Callers 1

mainFunction · 0.85

Calls 5

connectFunction · 0.85
cursorMethod · 0.80
executeMethod · 0.45
fetchallMethod · 0.45
closeMethod · 0.45

Tested by

no test coverage detected