SQLDBRestBridge - how to execute action queries (INSERT, UPDATE, DELETE)? lazarus / 38-Networking and Web Programming ---------------------------------------------------------------------- tatamata · 2019-04-03 08:55 When using REST (e.g. SQLDBRestBridge), how INSERT/UPDATE/DELETE queries are supposed to be executed from client web application? ---------------------------------------------------------------------- tatamata · 2019-04-04 20:32 I don't know whether my question was clear enough - the question was about performing various custom SQL queries that do not retrieve data (INSERT, UPDATE, DELETE) for controls. When reading about REST servers (e.g. SQLDBRestBridge) as well as web application client solutions (such as TMS Web Core or Elevate Web Builder) it is always about dbaware controls being somehow connected to JSON REST resources and used to view, insert, delete and update tables through GUI. But, I haven't found anything about processing action queries that do not retrieve data for GUI controls (insert, update, delete...executing stored procedures etc.). Is that even possible, if so, how to do it? ---------------------------------------------------------------------- Leledumbo · 2019-04-05 19:17 Read the wiki article once again, it's been stated clearly: QuoteThe server will then accept the usual REST GET/POST/PUT/Delete commands and automatically translate these to the appropriate database CRUD (Create/Read/Update/Delete) statements. Important lines not so far below it: QuoteTo consume the data served by this component, you need to write a client. No assumptions are made about the client, except that it knows how to execute HTTP requests, and that it understands one of the available data formats. if your server code is this: Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i  {create db this way first:CREATE TABLE `keyval` (  `thekey` varchar(100) NOT NULL,  `val` varchar(100) NOT NULL)} {$mode objfpc} uses  classes,  fphttpapp, httpdefs, httproute,  sqldb, mysql57conn,  sqldbrestbridge, sqldbrestschema; var  disp: TSQLDBRestDispatcher;begin  disp := TSQLDBRestDispatcher.Create(Application);  disp.ExposeDatabase(    'mysql 5.7','localhost','keyval','',''    ,nil,    [foFilter,foInInsert,foInUpdate]  );  disp.Active := true;   Application.Port := 9000;  Application.Initialize;  Application.Run;end. you can insert a row using curl this way: Code: Text  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i curl -v localhost:9000/keyval -d '{"thekey":"k","val":"v"}'