Changeset 248 for trunk/web/addons/job_monarch/libtoga.php
- Timestamp:
- 04/11/06 15:07:28 (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/web/addons/job_monarch/libtoga.php
r246 r248 142 142 function searchDbase( $id = null, $queue = null, $user = null, $name = null, $start_from_time = null, $start_to_time = null, $end_from_time = null, $end_to_time = null ) { 143 143 144 global $SEARCH_RESULT_LIMIT; 145 144 146 if( $id ) 145 147 $query = "SELECT job_id FROM jobs WHERE job_id = '$id' AND job_status = 'F'"; … … 162 164 $query_args[] = "job_stop_timestamp <= $end_to_time"; 163 165 164 $query = " SELECT job_idFROM jobs WHERE job_status = 'F' AND ";166 $query = "FROM jobs WHERE job_status = 'F' AND "; 165 167 $extra_query_args = ''; 166 168 … … 175 177 } 176 178 177 $ids = $this->queryDbase( $query ); 179 $count_result_idname = "COUNT(job_id)"; 180 $select_result_idname = "job_id"; 181 182 $count_query = "SELECT " . $count_result_idname . " " . $query; 183 184 $count_result = $this->queryDbase( $count_query ); 185 $this->resultcount = (int) $count_result[0][count]; 186 187 $select_query = "SELECT " . $select_result_idname . " " . $query . " ORDER BY job_id LIMIT " . $SEARCH_RESULT_LIMIT; 188 $ids = $this->queryDbase( $select_query ); 178 189 179 190 $ret = array();
Note: See TracChangeset
for help on using the changeset viewer.