how and when to update a mysql index?
        Posted  
        
            by fayer
        on Stack Overflow
        
        See other posts from Stack Overflow
        
            or by fayer
        
        
        
        Published on 2010-03-21T05:56:40Z
        Indexed on 
            2010/03/21
            6:01 UTC
        
        
        Read the original article
        Hit count: 222
        
im using this sql query to create an index:
    $query = "CREATE INDEX id_index2
            ON countries(geoname_id, name)";
but how do i update the index when new entries are added?
should i run a php script with the update query in CRON and run it every night?
is this best practice for automated index updating?
© Stack Overflow or respective owner