$sth->prepare("SELECT name, url FROM table WHERE name LIKE ?"); $sth->execute($name . '%');