Welcome Guest, Not a member yet? Register   Sign In
[SOLVED] Active Record - Table Alias
#5

[eluser]fszostak[/eluser]
I know about case-sensitive problems, but table names and field names are okay.

I solved the problem, the alias must be in UPPERCASE.

Take a look:

Code:
$this->db->select("T1.id, T1.title, T2.name");
$this->db->from("table1 T1");
$this->db->join("table2 T2", "T1.user_id = T2.id");
$this->db->where("T1.parent_id", $parent_id);
$query = $this->db->get();
return $query->result();


Thanks!


Messages In This Thread
[SOLVED] Active Record - Table Alias - by El Forum - 07-20-2010, 10:06 AM
[SOLVED] Active Record - Table Alias - by El Forum - 07-20-2010, 11:49 AM
[SOLVED] Active Record - Table Alias - by El Forum - 07-20-2010, 12:15 PM
[SOLVED] Active Record - Table Alias - by El Forum - 07-20-2010, 12:25 PM
[SOLVED] Active Record - Table Alias - by El Forum - 07-20-2010, 12:37 PM



Theme © iAndrew 2016 - Forum software by © MyBB