Please join: MySQL Community on Slack; MySQL Forums. It fails where the table or column names requires backticks, It fails if the column you want to omit is last in the list, It requires listing the table name twice (once for the select and another for the query text) which is redundant and unnecessary, It can potentially return column names in the, Shift select all the columns you want in your query (in your case all but one which is what i do). July 30, 2006 05:57AM Re: Select all Columns except… Here is an example of how this could be very useful: The result is all the columns from the users table, and two additional columns which were joined from the meta table. Because MINUS/EXCEPT compares every column between Table 1 and Table 2, so the join clause needs to contain all 4 columns SupplierID, CompanyName, ContactName, ContactTitle. But what if the column we do not require contains a large amount of BLOB data. The accepted answer has several shortcomings. Cheers! Advanced Search. If it’s always the same one column, then you can create a view that doesn’t have it in it. If you are looking to exclude the value of a field, e.g. I want to confirm how can i select all columns except one in sql server query. You could use a DB tool like MySQL Workbench in order to generate the select statement for you, so you just have to manually remove those columns for the generated statement and copy it to your SQL script. Actually there is a way, you need … Your performance will suffer otherwise. That doesn't make sense at all… Do I have to write a very long select statement with 29 column names that i want … it is subtraction of two result sets. For example, to select data to be inserted into a different table, which has its own ID. Not sure what you really mean. I completely agree with Onno. For my purposes (and I imagine many others’) I wanted the column names returned in the same order that they appear in the table itself. While I agree with Thomas’ answer (+1 ;)), I’d like to add the caveat that I’ll assume the column that you don’t want contains hardly any data. Get record counts for all tables in MySQL database. EDIT: There are 53 columns in this table (NOT MY DESIGN), Actually there is a way, you need to have permissions of course for doing this …, Replacing ,