Insert on two tables?

i have 2 MySQL tables in my database with the following columns:
Table 1:
LogCallID(Primary Key)
Source
Num
Msg

Table2:
ID(Primary Key)
LogCallID(Foreign Key)
Application
LogLevel
Text_en_US

How can i make an insert on the columns (Source/Num/Msg from table one and Apllication/Loglevel/Text_en_US from table2) for those two tables?

docs.dhtmlx.com/doku.php?id=dhtm … ex_updates

i’ve tried the following but it doesn’t work.

function my_insert($data)
        {
            $grid->sql->query("INSERT INTO SYS_LogCalls (Source, Num, Msg) VALUES ('{Source}', {Num}, '{Msg}')");
            $grid->sql->query("INSERT INTO SYS_LogCallDescription (LogCallID, Application, LogLevel, Text_en_US) VALUES (LAST_INSERT_ID(), '{Application}', {LogLevel}, '{Text_en_US}'");
            $data->success();
        }
        $grid->sql->attach("beforeInsert", "my_insert");

Any ideas how to solve it?

Try to enable server side logs for connectors, and provide log report for the problematic scenario.