This topic is locked
[SOLVED]

Updating bulk data from list page

11/8/2024 4:33:45 AM
PHPRunner General questions
A
alfonso authorDevClub member

From an external application I add records to a table. In the list of that table I need, for example, to update the "fullname" field. I want to execute, with a button, for example, this sentence:
UPDATE contactos_empresas_nueva
SET nombre_completo = UPPER(CONCAT(nombre, ' ', apellidos))
WHERE nombre_completo = '';

How can I do it? Thanks

Sergey Kornilov admin 11/9/2024

You need to explain what exactly causes the problem as this is a very basic question and not clear what you have tried already and what didn't work.

  1. Add a button.
  2. In A Server part of the button execute your SQL query. You can use one of the Database API functions to execute a query i.e. Exec():
    https://xlinesoft.com/phprunner/docs/db_exec.htm