Support » Localhost Installs » Does table prefix have to end in an underscore?

  • Resolved magicalwonders

    (@magicalwonders)


    Hello folks,

    I’ve been developing sites locally using WAMP and wanted to create a duplicate of a site I’m currently working on so I can test various plugins without cluttering up the database on the main site.

    I had a few problems getting a duplicate to work but finally solved the issue. In the course of trying different things however, I saw a few references that said the table prefix for WordPress tables should end in an underscore. My current site doesn’t. Although a mix of letters and numbers it only includes an underscore in the middle. Something like kd_6284 The site works without any issues, so I’m not sure why some people say WP table prefixes should end with an underscore?

    The only reason I can see is that it makes the tables a little easier to read. Is there any other reason though?

    Hope someone can advise.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Moderator Steven Stern (sterndata)

    (@sterndata)

    Forum Moderator & Support Team Volunteer

    No, you can run the prefix into the table name. Having once done that, I now regret it as it makes table names very hard to read.

    Thanks Steve. I thought it might be just about readability.

    Ending with numbers is not too bad as far as that goes. Having said that, I’ll probably go back to using an underscore next time as well! đŸ™‚

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Does table prefix have to end in an underscore?’ is closed to new replies.