OSB enhancements to date
This commit is contained in:
@@ -338,6 +338,9 @@ function sqlSelect($TableList,$FieldList,$sql=array()) {
|
||||
$fields = $FieldList;
|
||||
|
||||
# Condition(s)
|
||||
# @todo to remove sqlConditions() doesnt need $db
|
||||
if (! isset($db))
|
||||
$db = &DB();
|
||||
$where = sqlConditions($db,$sql['where'],$TableList);
|
||||
|
||||
$line = '';
|
||||
@@ -351,7 +354,7 @@ function sqlSelect($TableList,$FieldList,$sql=array()) {
|
||||
|
||||
# Limit
|
||||
if (isset($sql['limit']) && $sql['limit'])
|
||||
$line .= 'LIMIT '.$sql['limit'];
|
||||
$line .= ' LIMIT '.$sql['limit'];
|
||||
|
||||
$SQL = sprintf('SELECT %s FROM %s %s %s',$fields,$table,$where,$line);
|
||||
|
||||
|
Reference in New Issue
Block a user