Grid and sqlite3

Hi!
I’m new :smiley:
I have a problem about the update of the database: in particular when I editing a value in a row that value is saved correctly, but when I reload the web page the cell of remaining values ​​of the row are empty , there remains only the changed value.

I’ve active the debug.log

====================================
Log started, 26/06/2013 10:06:28
====================================

DataProcessor object initialized
15_gr_id => 15
15_c3 => 0144
15_!nativeeditor_status => updated
ids => 15

Row data [15]
id => 15
minValue => 0144
!nativeeditor_status => updated

Incorrect field name used: parentID

data
id => 15
minValue => 0144
!nativeeditor_status => updated

Incorrect field name used: parentID

data
id => 15
minValue => 0144
!nativeeditor_status => updated

Incorrect field name used: entryName

data
id => 15
minValue => 0144
!nativeeditor_status => updated

Incorrect field name used: entryName

data
id => 15
minValue => 0144
!nativeeditor_status => updated

Incorrect field name used: value

data
id => 15
minValue => 0144
!nativeeditor_status => updated

Incorrect field name used: value

data
id => 15
minValue => 0144
!nativeeditor_status => updated

UPDATE entries SET parentID='',entryName='',value='',minValue='0144' WHERE id='15'

Edit operation finished
0 => action:updated; sid:15; tid:15;

Done in 0.13895010948181s

“Incorrect field name” but the field are ok because the page read the data…

This the code of connector

<?php
	
	require("PHP/grid_connector.php");
	require("PHP/db_sqlite3.php");
	require("PHP/data_connector.php");

	$db = new SQLite3('menuTest.db');

	$grid = new GridConnector($db,"SQLite3");
	$grid->enable_log("debug.log",true);
	$grid->render_table('entries','id', 'parentID , entryName , value , minValue');

?>

and this the code of grid

<html>
<head>

<title>DHTMLX - SQLITE3 EDITABLE GRID</title>
<link rel="STYLESHEET" type="text/css" href="codebase/dhtmlxgrid.css">
<link rel="stylesheet" type="text/css" href="codebase/skins/dhtmlxgrid_dhx_skyblue.css">
<script  src="codebase/dhtmlxcommon.js"></script>
<script  src="codebase/dhtmlxgrid.js"></script>        
<script  src="codebase/dhtmlxgridcell.js"></script>
<script  src="codebase/ext/dhtmlxgrid_filter.js"></script>

<script  src="codebase/dhtmlxdataprocessor.js"></script>
<script  src="codebase/dhtmlxdataprocessor_debug.js"></script>

<script  src="PHP/connector.js"></script>
</head>
<body>

<div id="gridbox" style="width:800px;height:300px;background-color:white;"></div>
 
<script type="text/javascript">

	mygrid = new dhtmlXGridObject("gridbox");
	mygrid.setImagePath("codebase/imgs/");
	mygrid.setHeader("id, parentID, entryName, value");
	
	mygrid.setColAlign("left,left,left");
	mygrid.setColSorting("int,char,char,int");
	
	mygrid.setColTypes("ed,ed,ed,ed");
	mygrid.setSkin("dhx_skyblue");
	//mygrid.setColSorting("connector,connector,connector,connector");
	mygrid.init();
	//mygrid.loadXML('connectorMySql.php');
	mygrid.loadXML('connectorSqlite3.php');
	
	//var dp = new dataProcessor('connectorMySql.php');
	var dp = new dataProcessor('connectorSqlite3.php');
	dp.enablePartialDataSend(true);
	dp.setDataColumns([true,true,true,true]);
	dp.init(mygrid);

	DataProcessor = new dataProcessor("index.php");
	DataProcessor._console.style.top = "420px";
	
</script>

</body>
</html>

thanks

Hi
I´m new too but i gues that the problem is with column ids

[code]$grid->render_table(‘entries’,‘id’, ‘parentID , entryName , value , minValue’);

and

mygrid.setHeader(“id, parentID, entryName, value”);
[/code]
I think that you are using columns parentID , entryName , value , minValue in connector but in grid you use id, parentID, entryName, value

Not sure if this is the reason for your troble but I suggest you to use setColumnIds

mygrid.setColumnIds("parentID , entryName , value");

thanks :wink:
I have modified the code
connector:

$grid->render_table('entries','id', 'id, parentID , entryName , value , minValue');

index.php

mygrid.setHeader("id, parentID, entryName, value, minValue");
mygrid.setColumnIds("id, parentID , entryName , value, minValue");

but the problem is not solved…

Solved:

var dp = new dataProcessor('connectorSqlite3.php');
//dp.enablePartialDataSend(true);
//dp.setDataColumns([true,true,true,true,true]);
dp.init(mygrid);

Remove

dp.enablePartialDataSend(true);

This mode is not compatible with server side connectors.