[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Fmsystem-commits] [15986] fix insert jsondata to db
From: |
sigurdne |
Subject: |
[Fmsystem-commits] [15986] fix insert jsondata to db |
Date: |
Thu, 10 Nov 2016 16:10:50 +0000 (UTC) |
Revision: 15986
http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=15986
Author: sigurdne
Date: 2016-11-10 16:10:50 +0000 (Thu, 10 Nov 2016)
Log Message:
-----------
fix insert jsondata to db
Modified Paths:
--------------
branches/dev-syncromind-2/property/inc/class.sogeneric_document.inc.php
branches/dev-syncromind-2/property/inc/import/class.import_component_files.inc.php
Modified:
branches/dev-syncromind-2/property/inc/class.sogeneric_document.inc.php
===================================================================
--- branches/dev-syncromind-2/property/inc/class.sogeneric_document.inc.php
2016-11-10 16:10:18 UTC (rev 15985)
+++ branches/dev-syncromind-2/property/inc/class.sogeneric_document.inc.php
2016-11-10 16:10:50 UTC (rev 15986)
@@ -235,11 +235,11 @@
$values_insert = array
(
'file_id' => $file_id,
- 'metadata' => json_encode($data)
+ 'metadata' => "'" . json_encode($data) . "'"
);
$result = $this->db->query("INSERT INTO
phpgw_vfs_filedata (" . implode(',', array_keys($values_insert)) . ') VALUES ('
- .
$this->db->validate_insert(array_values($values_insert)) . ')', __LINE__,
__FILE__);
+ . implode(",", array_values($values_insert)) .
')', __LINE__, __FILE__);
if ($result)
{
Modified:
branches/dev-syncromind-2/property/inc/import/class.import_component_files.inc.php
===================================================================
---
branches/dev-syncromind-2/property/inc/import/class.import_component_files.inc.php
2016-11-10 16:10:18 UTC (rev 15985)
+++
branches/dev-syncromind-2/property/inc/import/class.import_component_files.inc.php
2016-11-10 16:10:50 UTC (rev 15986)
@@ -590,11 +590,11 @@
$values_insert = array
(
'file_id' => $file_id,
- 'metadata' => json_encode($metadata)
+ 'metadata' => "'" .
json_encode($metadata) . "'"
);
$this->db->query("INSERT INTO
phpgw_vfs_filedata (" . implode(',', array_keys($values_insert)) . ') VALUES ('
- .
$this->db->validate_insert(array_values($values_insert)) . ')', __LINE__,
__FILE__);
+ . implode(",",
array_values($values_insert)) . ')', __LINE__, __FILE__);
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Fmsystem-commits] [15986] fix insert jsondata to db,
sigurdne <=