Home > Backend Development > PHP Tutorial > 帮忙改下一条查询语句,该怎么处理

帮忙改下一条查询语句,该怎么处理

WBOY
Release: 2016-06-13 13:34:38
Original
768 people have browsed it

帮忙改下一条查询语句
SHOW TABLES

显示的当前数据表名称,
但是这个结果集的列名称是"Tables_in_myoffice",myoffice是我的数据库名,我想把它设定为一个常量字符串,比如
"tbnames",应该怎么写到这个查询语句里去?
show tables as "tbnames";
好像不对呀

------解决方案--------------------
SHOW 不支持用 AS 。
不一定非要这样做,你完全可以按数字索引来取值 mysql_fetch_row() mysql_result();

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template