LEFT(content, 100)

#1
[eluser]Unknown[/eluser]
Hey Guys,

I'm stuck with a problem with getting data from an table.

I want to display the first 100 charters from a colom. In a normal query I would use:
Code:
LEFT(content, 100)
I cannot find how to do it like $this->db->left().

Can anyone maybe help me with this?


Thanks in advance,

Mike

#2
[eluser]WanWizard[/eluser]
Code:
$this->db->select('LEFT(content, 100) as left_content', FALSE);

#3
[eluser]Unknown[/eluser]
WanWizard,

Realy a wizard! Thank you so much!

Mike


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2021 MyBB Group.