gpt4 book ai didi

mysql - 从同一列中选择数据

转载 作者:太空宇宙 更新时间:2023-11-03 12:17:18 25 4
gpt4 key购买 nike

我需要从具有不同值的同一列中选择数据?我该怎么办

select * FROM billingorganization WHERE user_id = $user_id && user_id = 0?

<select name="billing_name">

<?php
$query2 = "SELECT * from billingorganization WHERE user_id = $user_id";
$result2 = mysqli_query($link, $query2) or die(mysqli_error($link));
while ($row3 = mysqli_fetch_array($result2)) {
$billing_name = $row3['billing_name'];
$billing_name_id = $row3['billing_name_id'];

?>

<option value="<?php echo $billing_name; ?>" ><?php echo $billing_name ;?></option>

<?php
}
?>
</select>

最佳答案

select * FROM billingorganization WHERE user_id = $user_id OR user_id = 0

关于mysql - 从同一列中选择数据,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21551522/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com