Python variable to database frequent update at rate 20times

Und alles was mit phpMyAdmin seine Verwandtschaft findet hat hier seinen Platz.

Python variable to database frequent update at rate 20times

Postby amd123coep » 27. July 2022 13:24

My requirement is to update some value from python variable to mysql database.This has to happen 20-30times per minute

One way is put update query in loop...is there any other efficient way.
This is to keep record of trade values
amd123coep
 
Posts: 2
Joined: 27. July 2022 12:21
XAMPP version: 8
Operating System: Windows 11

Re: Python variable to database frequent update at rate 20ti

Postby Nobbie » 27. July 2022 19:31

amd123coep wrote:One way is put update query in loop...is there any other efficient way.


No, i have no idea. What are you thinking about? What do you mean by "efficient" and what is unefficient with a loop? Actually i dont know, what you are looking for.

I know, there is "prepared statement" to avoid running the SQL Interpreter for each update, but actually i dont believe that there is any benefit with modern CPUs, running blazingly fast, even calculating 4k videos in realtime. 30 years ago prepared statements may have been a usefull thing, but not today anymore (just my two cents). I simply would run the Query in a loop. If there is any bottleneck, its the TCPIP communication between the server and the client.
Nobbie
 
Posts: 12515
Joined: 09. March 2008 13:04

Re: Python variable to database frequent update at rate 20ti

Postby amd123coep » 28. July 2022 10:42

Thank you....
Effeccient means less consumption of resources.actually am reading value from another webpage and adding into my database.like rate of currancy...
amd123coep
 
Posts: 2
Joined: 27. July 2022 12:21
XAMPP version: 8
Operating System: Windows 11


Return to phpMyAdmin

Who is online

Users browsing this forum: No registered users and 5 guests