[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpgroupware-cvs] property/setup tables_update.inc.php,1.15
From: |
sigurdne |
Subject: |
[Phpgroupware-cvs] property/setup tables_update.inc.php,1.15 |
Date: |
Thu, 22 Sep 2005 10:35:00 +0200 |
Update of property/setup
Modified Files:
Branch: MAIN
tables_update.inc.php lines: +12 -1
Log Message:
no message
====================================================
Index: property/setup/tables_update.inc.php
diff -u property/setup/tables_update.inc.php:1.14
property/setup/tables_update.inc.php:1.15
--- property/setup/tables_update.inc.php:1.14 Wed Sep 21 14:18:16 2005
+++ property/setup/tables_update.inc.php Thu Sep 22 08:35:52 2005
@@ -695,6 +695,17 @@
$id = $value['request_id'];
+
+
+ $sql = "SELECT sum(priority_key * ( degree *
probability * ( consequence +1 ))) AS score FROM fm_request_condition"
+ . " JOIN fm_request_condition_type ON
(fm_request_condition.condition_type = fm_request_condition_type.id) WHERE
request_id = $id";
+
+
$GLOBALS['phpgw_setup']->oProc->query($sql,__LINE__,__FILE__);
+
+ $GLOBALS['phpgw_setup']->oProc->next_record();
+ $score = $GLOBALS['phpgw_setup']->oProc->f('score');
+ $GLOBALS['phpgw_setup']->oProc->query("UPDATE
fm_request SET score = $score WHERE id = $id",__LINE__,__FILE__);
+
$GLOBALS['phpgw_setup']->oProc->query("UPDATE
fm_request SET score = (SELECT sum
(priority_key*(degree*probability*(consequence+1))) from fm_request_condition"
. " JOIN fm_request_condition_type ON
(fm_request_condition.condition_type = fm_request_condition_type.id) WHERE
request_id = $id) WHERE fm_request.id = $id",__LINE__,__FILE__);
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Phpgroupware-cvs] property/setup tables_update.inc.php,1.15,
sigurdne <=