Home  >  Q&A  >  body text

How to SELECT to remove all columns of a certain column in MySQL?

Because there are dozens of columns in the table, is there any simple way to SELECT to remove all columns of a certain column?

Similar to the following syntax:

SELECT * [except columnA] FROM tableA
学习ing学习ing2668 days ago1192

reply all(1)I'll reply

  • 扔个三星炸死你

    扔个三星炸死你2017-06-30 09:55:03

    I don’t know which database has this syntax.

    The key is not to know the actual meaning of this. If there are many fields, use select * to process them. If there are few fields, write the field list yourself.
    If you really want to write it like this, you can only dynamically splice the sql statement with strings based on the metadata of the table.

    reply
    0
  • Cancelreply