projects
/
fa-stable.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
07cdb63
)
Concurrent edition fix
author
Janusz Dobrowolski
<janusz@frontaccounting.eu>
Thu, 6 Mar 2008 09:35:47 +0000
(09:35 +0000)
committer
Janusz Dobrowolski
<janusz@frontaccounting.eu>
Thu, 6 Mar 2008 09:35:47 +0000
(09:35 +0000)
includes/systypes.inc
patch
|
blob
|
history
diff --git
a/includes/systypes.inc
b/includes/systypes.inc
index e9aa69871d677a51010e54944a05dba232f3f4e2..3d45981038f15f3d61bc53b50b5e26c666036d3d 100644
(file)
--- a/
includes/systypes.inc
+++ b/
includes/systypes.inc
@@
-14,7
+14,8
@@
Function get_next_trans_no ($trans_type){
$next_number = $myrow[0] + 1;
- $sql = "UPDATE ".TB_PREF."sys_types SET type_no = $next_number WHERE type_id = $trans_type";
+ $sql = "UPDATE ".TB_PREF."sys_types SET type_no = $next_number WHERE type_id = $trans_type
+ AND type_no = ". $myrow[0]; //concurrency paranoic protection
db_query($sql,"The next transaction number for $trans_type could not be updated");