Welcome Guest, Not a member yet? Register   Sign In
mysql select
#4

[eluser]jedd[/eluser]
[quote author="georgerobbo" date="1254885006"]
Those are not the true lengths I'm using. Just what I have written down for simplicity.
[/quote]

I do not understand how misrepresenting a schema, especially when asking for help about that schema, makes things simpler.

Your code looks pretty easy to translate into CI - if that's the question you're actually asking here (I can't work it out).

I create my own queries in preference to using CI's AR - you haven't said if your desire is to move to AR calls or not.

Very roughly - something that looks like this:
Code:
$query = $this->db->query ("SELECT *
                FROM user
                WHERE name like \"%". $this->db->escape($keyphrase). "%\"
                OR permalink like \"%". $this->db->escape($keyphrase)."%\"    ... etc
                ");
$numresults = $query->num_rows();

As I say, though, you need to fix up your tagging system - have a table for tags, and another table for connecting the tags table to this user table.


Messages In This Thread
mysql select - by El Forum - 10-06-2009, 03:58 PM
mysql select - by El Forum - 10-06-2009, 04:05 PM
mysql select - by El Forum - 10-06-2009, 04:10 PM
mysql select - by El Forum - 10-06-2009, 04:23 PM
mysql select - by El Forum - 10-07-2009, 02:22 AM
mysql select - by El Forum - 10-07-2009, 03:16 AM
mysql select - by El Forum - 10-08-2009, 11:46 AM
mysql select - by El Forum - 10-08-2009, 12:13 PM



Theme © iAndrew 2016 - Forum software by © MyBB