aboutsummaryrefslogtreecommitdiff
path: root/engine/lib/relationships.php
diff options
context:
space:
mode:
authormarcus <marcus@36083f99-b078-4883-b0ff-0f9b5a30f544>2008-11-03 13:09:42 +0000
committermarcus <marcus@36083f99-b078-4883-b0ff-0f9b5a30f544>2008-11-03 13:09:42 +0000
commit004a0c8a75e8fb71b8ba0c47f000c381c03a2967 (patch)
treeff34fa6b50a89713b20ac46c0fa672428c533a97 /engine/lib/relationships.php
parent05ffc437ef95e84e0438c5b0230b261179b47cca (diff)
downloadelgg-004a0c8a75e8fb71b8ba0c47f000c381c03a2967.tar.gz
elgg-004a0c8a75e8fb71b8ba0c47f000c381c03a2967.tar.bz2
Minor tweaks 'cos case does matter...
git-svn-id: https://code.elgg.org/elgg/trunk@2379 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'engine/lib/relationships.php')
-rw-r--r--engine/lib/relationships.php6
1 files changed, 3 insertions, 3 deletions
diff --git a/engine/lib/relationships.php b/engine/lib/relationships.php
index 8f2d52bbc..f43a46c54 100644
--- a/engine/lib/relationships.php
+++ b/engine/lib/relationships.php
@@ -380,7 +380,7 @@
$relationship = sanitise_string($relationship);
$guid_two = (int)$guid_two;
- if ($row = get_data_row("select guid_one from {$CONFIG->dbprefix}entity_relationships where guid_one=$guid_one and relationship='$relationship' and guid_two=$guid_two limit 1")) {
+ if ($row = get_data_row("SELECT guid_one FROM {$CONFIG->dbprefix}entity_relationships WHERE guid_one=$guid_one AND relationship='$relationship' AND guid_two=$guid_two limit 1")) {
return true;
}
return false;
@@ -506,9 +506,9 @@
$joinon = "e.guid = r.guid_two";
if ($count) {
- $query = "select count(distinct e.guid) as total ";
+ $query = "SELECT count(distinct e.guid) as total ";
} else {
- $query = "select distinct e.* ";
+ $query = "SELECT distinct e.* ";
}
$query .= " from {$CONFIG->dbprefix}entity_relationships r JOIN {$CONFIG->dbprefix}entities e on $joinon where ";
foreach ($where as $w)