找表是否存在mysql保留字段

sql 复制代码
SELECT column_name
FROM information_schema.columns
WHERE table_name = '表名称'
  AND column_name IN
      ('action', 'add', 'aggregate', 'all', 'alter', 'after', 'and', 'as', 'asc', 'avg', 'avg_row_length',
       'auto_increment', 'between', 'bigint', 'bit', 'binary', 'blob', 'bool', 'both', 'by', 'cascade', 'case', 'char',
       'character', 'change', 'check', 'checksum', 'column', 'columns', 'comment', 'constraint', 'create', 'cross',
       'current_date', 'current_time', 'current_timestamp', 'data', 'database', 'databases', 'date', 'datetime', 'day',
       'day_hour', 'day_minute', 'day_second', 'dayofmonth', 'dayofweek', 'dayofyear', 'dec', 'decimal', 'default',
       'delayed', 'delay_key_write', 'delete', 'desc', 'describe', 'distinct', 'distinctrow', 'double', 'drop', 'end',
       'else', 'escape', 'escaped', 'enclosed', 'enum', 'explain', 'exists', 'fields', 'file', 'first', 'float',
       'float4', 'float8', 'flush', 'foreign', 'from', 'for', 'full', 'function', 'global', 'grant', 'grants', 'group',
       'having', 'heap', 'high_priority', 'hour', 'hour_minute', 'hour_second', 'hosts', 'identified', 'ignore', 'in',
       'index', 'infile', 'inner', 'insert', 'insert_id', 'int', 'integer', 'interval', 'int1', 'int2', 'int3', 'int4',
       'int8', 'into', 'if', 'is', 'isam', 'join', 'key', 'keys', 'kill', 'last_insert_id', 'leading', 'left', 'length',
       'like', 'lines', 'limit', 'load', 'local', 'lock', 'logs', 'long', 'longblob', 'longtext', 'low_priority', 'max',
       'max_rows', 'match', 'mediumblob', 'mediumtext', 'mediumint', 'middleint', 'min_rows', 'minute', 'minute_second',
       'modify', 'month', 'monthname', 'myisam', 'natural', 'numeric', 'no', 'not', 'null', 'on', 'optimize', 'option',
       'optionally', 'or', 'order', 'outer', 'outfile', 'pack_keys', 'partial', 'password', 'precision', 'primary',
       'procedure', 'process', 'processlist', 'privileges', 'read', 'real', 'references', 'reload', 'regexp', 'rename',
       'replace', 'restrict', 'returns', 'revoke', 'rlike', 'row', 'rows', 'second', 'select', 'set', 'show',
       'shutdown', 'smallint', 'soname', 'sql_big_tables', 'sql_big_selects', 'sql_low_priority_updates', 'sql_log_off',
       'sql_log_update', 'sql_select_limit', 'sql_small_result', 'sql_big_result', 'sql_warnings', 'straight_join',
       'starting', 'status', 'string', 'table', 'tables', 'temporary', 'terminated', 'text', 'then', 'time',
       'timestamp', 'tinyblob', 'tinytext', 'tinyint', 'trailing', 'to', 'type', 'use', 'using', 'unique', 'unlock',
       'unsigned', 'update', 'usage', 'values', 'varchar', 'variables', 'varying', 'varbinary', 'with', 'write', 'when',
       'where', 'year', 'year_month', 'zerofill');
相关推荐
2143965几秒前
SQL注入防御技术方案_基于正则表达式的输入清洗
jvm·数据库·python
2401_832365528 分钟前
SQL窗口函数与递归查询的区别_如何根据场景选择
jvm·数据库·python
u0109147608 分钟前
c++如何处理文件路径中由于不规范的连续斜杠导致的路径解析错误【避坑】
jvm·数据库·python
2301_7965885010 分钟前
PHP源码开发用二手硬件划算吗_性价比与稳定性权衡【操作】
jvm·数据库·python
2301_7751481511 分钟前
如何通过C#读取Oracle数据库中的图片显示到WinForm_BLOB转Byte[]与流处理
jvm·数据库·python
ERBU DISH12 分钟前
修改表字段属性,SQL总结
java·数据库·sql
treesforest22 分钟前
IP 反欺诈查询怎么落地更稳?Ipdatacloud 适用场景与实战决策闭环
网络·数据库·网络协议·tcp/ip·网络安全
weixin_5689960631 分钟前
mysql如何配置大页内存_mysql large-pages开启方法
jvm·数据库·python
HHHHH1010HHHHH32 分钟前
HTML怎么创建评论区域_HTML嵌套评论语义结构【详解】
jvm·数据库·python
Absurd58732 分钟前
C#怎么模拟键盘按键输入_C#如何实现自动化脚本【教程】
jvm·数据库·python