|
From: Benjamin C. <bc...@us...> - 2001-11-02 13:38:19
|
Update of /cvsroot/phpbt/phpbt
In directory usw-pr-cvs1:/tmp/cvs-serv10989
Modified Files:
include.php
Log Message:
Fixed problems with saving queries
Index: include.php
===================================================================
RCS file: /cvsroot/phpbt/phpbt/include.php,v
retrieving revision 1.71
retrieving revision 1.72
diff -u -r1.71 -r1.72
--- include.php 2001/11/02 04:21:41 1.71
+++ include.php 2001/11/02 13:38:16 1.72
@@ -74,7 +74,11 @@
global $auth;
if ($seq_name == TBL_SAVED_QUERY) {
- return $q->grab_field("select max(saved_query_id)+1 where user_id = ".$auth->auth['uid']);
+ if ($id = $this->grab_field("select max(saved_query_id)+1 from ".TBL_SAVED_QUERY." where user_id = ".$auth->auth['uid'])) {
+ return $id;
+ } else {
+ return 1;
+ }
} else {
return DB_Sql::nextid($seq_name);
}
|