23.11.2021, 12:57
Good afternoon. Please tell me who knows. After installing the MySQL packages, LM5 has its own MySQL server or only allows working with third party MySQL databases.
MySQL server
|
23.11.2021, 12:57
Good afternoon. Please tell me who knows. After installing the MySQL packages, LM5 has its own MySQL server or only allows working with third party MySQL databases.
23.11.2021, 13:01
It's only for MySQL client not server.
23.11.2021, 13:08
03.12.2021, 08:01
Hello. Please tell me. How can I get the result of a query as a chill, so that a condition can be made to check the result. The query displays the result in tabular form
Code: 123 count = dbcon:execute('SELECT COUNT(period) FROM total_energy WHERE period = "day"')
row = count:fetch({}, 'a')
log(row)Code: 123 * table:
["COUNT(period)"]
* string: 9
03.12.2021, 08:06
Try this:
Code: 123456 cur = dbcon:execute('SELECT COUNT(period) AS cnt FROM total_energy WHERE period = "day"')
row = cur:fetch({}, 'a')
cur:close()
count = tonumber(row.cnt)
log(count)
03.12.2021, 08:11
|
« Next Oldest | Next Newest »
|