php,while中使用mysql查询语句问题

php的mysql查询语句可不可以这样用呢?

$query = "SELECT name FROM bank WHERE area LIKE 'aaa'";

$result = mysql_query($query) or die(mysql_error());

while($row = mysql_fetch_array($result)) {

    $http = $row['http'];

    $task_query = "SELECT * FROM task WHERE link LIKE'%$http%'";

    $task_result = mysql_query($task_query) or die(mysql_error());

    while($task = mysql_fetch_array($task_result));

            echo $task['high'].'<br />';

    }


慕哥9229398
浏览 938回答 1
1回答
打开App,查看更多内容
随时随地看视频慕课网APP

相关分类

MySQL