mysql 5.1 chokes on 'select * from group' since group is a keyword
This commit is contained in:
parent
8a1c8c4a03
commit
24d088d43b
@ -293,7 +293,7 @@ function identity_basic_export($channel_id) {
|
|||||||
$ret['hubloc'] = $r;
|
$ret['hubloc'] = $r;
|
||||||
}
|
}
|
||||||
|
|
||||||
$r = q("select * from group where uid = %d ",
|
$r = q("select * from `group` where uid = %d ",
|
||||||
intval($channel_id)
|
intval($channel_id)
|
||||||
);
|
);
|
||||||
|
|
||||||
|
@ -279,7 +279,7 @@ function import_post(&$a) {
|
|||||||
. implode("', '", array_values($group))
|
. implode("', '", array_values($group))
|
||||||
. "')" );
|
. "')" );
|
||||||
}
|
}
|
||||||
$r = q("select * from group where uid = %d",
|
$r = q("select * from `group` where uid = %d",
|
||||||
intval($channel['channel_id'])
|
intval($channel['channel_id'])
|
||||||
);
|
);
|
||||||
if($r) {
|
if($r) {
|
||||||
|
@ -49,7 +49,7 @@ function lockview_content(&$a) {
|
|||||||
stringify_array_elms($deny_users,true);
|
stringify_array_elms($deny_users,true);
|
||||||
|
|
||||||
if(count($allowed_groups)) {
|
if(count($allowed_groups)) {
|
||||||
$r = q("SELECT name FROM group WHERE hash IN ( " . implode(', ', $allowed_groups) . " )");
|
$r = q("SELECT name FROM `group` WHERE hash IN ( " . implode(', ', $allowed_groups) . " )");
|
||||||
if($r)
|
if($r)
|
||||||
foreach($r as $rr)
|
foreach($r as $rr)
|
||||||
$l[] = '<b>' . $rr['name'] . '</b>';
|
$l[] = '<b>' . $rr['name'] . '</b>';
|
||||||
@ -61,7 +61,7 @@ function lockview_content(&$a) {
|
|||||||
$l[] = $rr['xchan_name'];
|
$l[] = $rr['xchan_name'];
|
||||||
}
|
}
|
||||||
if(count($deny_groups)) {
|
if(count($deny_groups)) {
|
||||||
$r = q("SELECT name FROM group WHERE hash IN ( " . implode(', ', $deny_groups) . " )");
|
$r = q("SELECT name FROM `group` WHERE hash IN ( " . implode(', ', $deny_groups) . " )");
|
||||||
if($r)
|
if($r)
|
||||||
foreach($r as $rr)
|
foreach($r as $rr)
|
||||||
$l[] = '<b><strike>' . $rr['name'] . '</strike></b>';
|
$l[] = '<b><strike>' . $rr['name'] . '</strike></b>';
|
||||||
|
Reference in New Issue
Block a user