I want to create a progressbar for queries, say i have a query 开发者_JAVA技巧that will take 40 seconds, i'd like to give some feedback to users on how long this will take and i found this code from oracle that is exactly matches what i want. Is there a same thing in sqlite?
from timemachine import oracle
guesser=oracle(guess="SQL")
guesser.set_hint(driver="pypgsql")
guesser.set_hint(gui="wx")
expected_runtime=guesser.estimate("<put your query text here>")
Perhaps the set_progress_handler()
method of the sqlite3.Connection
objects could be of use?
精彩评论