Using SELECT * means that the database optimizer cannot choose index-only scans.
The computational overhead of deserialization can slow down query performance.
Not all columns are stored inline, and retrieving large columns like blobs increases I/Os.
Before the query result is sent to the client, it is serialized according to the communication protocol supported by the database, which affects network latency.
Client apps must deserialize the data after they receive the raw bytes, adding to overall processing time.
Using SELECT * on the client side, even if the table has one or two fields, can introduce unpredictability.
Explicit SELECT makes it easier to grep the codebase for in-use columns and make database schema changes.
It’s generally best to only select necessary fields to reduce unnecessary overhead when querying tables.
However, for tables with few columns and simple data types, SELECT * overhead may be negligible.
Be selective about the columns retrieved in queries to improve overall query performance.