Radicore Forum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » RADICORE development » Application Development » Running batch jobs
Running batch jobs [message #5045] Fri, 09 October 2015 21:50 Go to previous message
edortizq is currently offline  edortizq
Messages: 82
Registered: August 2008
Location: Ecuador
Member

Dear Tony, I'm trying to run my first batch job, so I created a task using the BATCH pattern, then I try some testing code truncating some tables but nothing happens, when I try to debug my script it never stops on the breakpoints wich are on the generated script.
I'm trying to run this batch task by pressing a navigation button from a multi5 task.
However it's definitely running something because it shows a batch_log_filepicker task after pressing the button and I can open the html output file.

The testing code is:

<?php
//********************************************************** *******************
// run a script in the background
//********************************************************** *******************

$stdout = '../logs/detallemuestras.html';
$csvout = '../logs/detallemuestras.csv';
$pdfout = '../logs/detallemuestras.pdf';

ini_set('include_path', '.');
require 'std.batch.inc';

batchInit(__FILE__);


$conn1millaQry = mysqli_connect('localhost', 'remoto', 'inp1milla', 'unamillaqry');
if (!$conn1millaQry) {
die('No se puede conectar a DB UNAMILLAQRY: ' . mysql_error());
}
echo 'Conexion Exitosa a UNAMILLAQRY'.'<br>';

mysqli_query($conn1millaQry,'TRUNCATE TABLE artespesca');
mysqli_query($conn1millaQry,'TRUNCATE TABLE componentes');
mysqli_query($conn1millaQry,'TRUNCATE TABLE detallemuestras');

mysqli_close($conn1millaQry);

batchEnd();

?>

The html output file (detallemuestras.html) only have this:

user_id : MGR
role_id : GLOBAL

What I'm doing wrong?
Thanks for advance!!

Best regards,
Edgar
 
Read Message
Read Message
Read Message
Previous Topic: ERROR: 22P02: invalid input syntax for integer
Next Topic: JAVASCRIPT CODE FOR INPUT FIELD
Goto Forum:
  


Current Time: Sun Nov 03 07:22:53 EST 2024

Total time taken to generate the page: 0.01450 seconds