Welcome Guest, Not a member yet? Register   Sign In
I'd assume this is a JOIN question...
#2

[eluser]Dam1an[/eluser]
You didnlt state if you're using AR or plain SQL, so I'll assume the former
Code:
$this->db->join('event_types', 'events.event_type_id = event_types.event_type_id');
$query = $this->db->get('events');

You can obvioulsy add any other parts to the query, just as selects and aliases, where clauses etc

Hopefully that code makes sense, if not, have a read up on joins, and if still not, then post back and I'll try my best to explain it Smile


Messages In This Thread
I'd assume this is a JOIN question... - by El Forum - 09-14-2009, 11:52 AM
I'd assume this is a JOIN question... - by El Forum - 09-14-2009, 12:02 PM
I'd assume this is a JOIN question... - by El Forum - 09-14-2009, 12:04 PM
I'd assume this is a JOIN question... - by El Forum - 09-14-2009, 12:56 PM
I'd assume this is a JOIN question... - by El Forum - 09-14-2009, 01:05 PM
I'd assume this is a JOIN question... - by El Forum - 09-14-2009, 04:56 PM
I'd assume this is a JOIN question... - by El Forum - 09-14-2009, 05:20 PM



Theme © iAndrew 2016 - Forum software by © MyBB