Impact of database field name length on performance?

What effect does the length of a field name have on database performance? Is it negligible? Should I go with long descriptive names?

+6
database name-length
source share
6 answers

I did not measure time, but I imagine negligible. Field names will be sent back and forth over the network, both in your SQL statements to the database, and in the metadata returned from the database, but I think that the incremental difference that a few bytes in these packages makes is below the threshold of concern.

Sorry for the poor people who need to read your code and make the names descriptive. Let the computer get a little extra work.

+12
source share

The database server translates the field names into an internal representation. Thus, the only time a name length affects performance is when the server parses your SQL queries. The effective impact of this is negligible for typical applications.

+4
source share

To be smart is to create field names long enough for you to know what they represent, but short enough so you don't have to scroll half an hour on the right to see what a column is.

+3
source share

You can get academic information and discuss the time when the query parser should read the query, but really ... long names have no effect, which you should worry about at all.

+1
source share

Internally, the query processor uses numbers for field names after analyzing the tokens in the query. There are no noticeable performance gains in the short names of database objects.

+1
source share

If you use embedded sql or ORM, this may affect additional information sent back and forth on the network; but we speak very little.

+1
source share

All Articles