From 5713329ff98d7be8615fd4a3055851f5c1603514 Mon Sep 17 00:00:00 2001 From: Miles Lott Date: Thu, 29 Mar 2001 04:32:33 +0000 Subject: [PATCH] Add LINE,FILE to nextid/lastid --- phpgwapi/inc/class.common.inc.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/phpgwapi/inc/class.common.inc.php b/phpgwapi/inc/class.common.inc.php index 7118f32a61..92573f6446 100644 --- a/phpgwapi/inc/class.common.inc.php +++ b/phpgwapi/inc/class.common.inc.php @@ -1306,18 +1306,18 @@ return -1; } - $phpgw->db->query("SELECT id FROM phpgw_nextid WHERE appname='".$appname."'"); + $phpgw->db->query("SELECT id FROM phpgw_nextid WHERE appname='".$appname."'",__LINE__,__FILE__); while( $phpgw->db->next_record() ) { $id = $phpgw->db->f("id"); } if (empty($id) || !$id) { $id = 1; - $phpgw->db->query("INSERT INTO phpgw_nextid (appname,id) VALUES ('".$appname."',".$id.")"); - $phpgw->db->query("UPDATE phpgw_nextid SET id=".$id." WHERE appname='".$appname."'"); + $phpgw->db->query("INSERT INTO phpgw_nextid (appname,id) VALUES ('".$appname."',".$id.")",__LINE__,__FILE__); + $phpgw->db->query("UPDATE phpgw_nextid SET id=".$id." WHERE appname='".$appname."'",__LINE__,__FILE__); } else { $id = $id + 1; - $phpgw->db->query("UPDATE phpgw_nextid SET id=".$id." WHERE appname='".$appname."'"); + $phpgw->db->query("UPDATE phpgw_nextid SET id=".$id." WHERE appname='".$appname."'",__LINE__,__FILE__); } return intval($id); @@ -1337,7 +1337,7 @@ return -1; } - $phpgw->db->query("SELECT id FROM phpgw_nextid WHERE appname='".$appname."'"); + $phpgw->db->query("SELECT id FROM phpgw_nextid WHERE appname='".$appname."'",__LINE__,__FILE__); while( $phpgw->db->next_record() ) { $id = $phpgw->db->f("id"); }