naming convention for tables, queries and forms

hey guys,

could yall share what are some of the naming conventions yall use for tables, queries and forms?

it's very common to see the prefix tbl, qry, frm.

however i think that is quite obvious already and it takes away the prefix from being something more descriptive.

i would only use tbl, qry and frm in the case when my object name is the same but the object type is different e.g. tblSomeName, qrySomeName, frmSomeName

what are some of the naming conventions yall use guys? as the database grows bigger, this could be an absolute killer!!

also for build up queries i use:


any sharing of naming conventions will be most helpful!! thanks guys!! = ))
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

DatabaseMX (Joe Anderson - Microsoft Access MVP)Database Architect / Systems AnalystCommented:
Here is a good reference on the De-Facto Access naming conventions pioneered by Stan Leszynski and Greg Reddick back in the early 90's, which became known as the L/R Naming Conventions (aka LNC Naming Conventions) - and is still pretty much the de-facto standard today.

And not directly mentioned, but avoid using any of these special characters in object and field names:

Avoid using the following characters: ,.~!@#$%^&*()+-=|\:;'<>?/"`[]{}  including Spaces!

Frank McCourryV.P. Holland Computers, Inc.Commented:
Personally, I do something similar, but I format it as;

This way I keep associated tables forms and queries together.  I never use spaces.  I cannot tell you how many times I've seen space fudge things up!

It's really up to you and how you want it to be organized.  It looks like your off to a good start.
Jeffrey CoachmanMIS LiasonCommented:
Yes, as you know the main thing is that whatever convention you use, you must be consistent.
(If you must break with convention, make it an exception, not a rule...)

Lately I have seen a lot of schemas where the prefix is at the end (ex.: Customers_tbl, Orders_sfrm, ...etc)

This helps with sorting the similar objects

But like MX, I still stick with the LNC, (for the most part)

There is also more great info here:


Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Big Business Goals? Which KPIs Will Help You

The most successful MSPs rely on metrics – known as key performance indicators (KPIs) – for making informed decisions that help their businesses thrive, rather than just survive. This eBook provides an overview of the most important KPIs used by top MSPs.

Jeffrey CoachmanMIS LiasonCommented:
for example,...I try to use "btn" for command buttons...
Back when I was studying VB6, I learned that the was a "Command" object that used "cmd" as a prefix.
(...besides when you select it from the controls box, say "Button")

I also use chrt instead of cht (for charts)

So again, consistency is the key...

Scott McDaniel (Microsoft Access MVP - EE MVE )Infotrakker SoftwareCommented:
I use my own version of LNC, but have taken a few liberties.

For example, I use "s" for a String variable:


I use "i" for Integer, "d" for Double, and so on. It can get somewhat messy at times, like with Decimal (in which case I use "dc"). I use "f" for Form, and "sf" for Subform, "r" for report, and so on. While "frm" is a bit more descriptive, "f" gets the job done.

The main thing, as others have said, is I'm consistent, and from project to project I can tell at a glance what type of variable I'm dealing with. That's the purpose of any naming convention, so as long as it serves the purpose, the job is done!

I think the concept of overly descriptive prefixes or suffixes defeats the purpose, and actually makes things harder. After all, is this:


better than:


The first is overly descriptive, and doesn't really tell you what it does - is it a subform for working with InvoiceDetails, or with InvoiceLineItems, or are they the same? Is is a Subform for a form named "InvoiceDetails"? Or something else.

Note this came from a project I'm working on now, and it's a fairly short example of overkill. There are other variables/objects with longer names than this ...
DatabaseMX (Joe Anderson - Microsoft Access MVP)Database Architect / Systems AnalystCommented:
"I use my own version of LNC, but have taken a few liberties."

Similar to LSM also ... basically one letter prefixes for Variables.

Overall ... Less Is More.
I keep all of my object names as *short* as possible - since user is never going to see them.

For Forms/Subforms ... I want related objects to sort together for SURE. So -for example

frmInvoice                 'Main Invoice
frmInvoiceSubDt     'Invoice Details  (this is a subform on frmInvoice)
developingprogrammerAuthor Commented:
thanks guys for all your help = )

Jeff and Frank, i think that using the object type abbreviation as a suffix is actually a very warp (because it's new) idea - but actually the best thing.

i did some thinking and i think the most succinct way to express it is that -

- object type as a prefix tightly couples the sort order: it can only be sorted by object type
- object type as a suffix loosely couples the sort order: it can be sorted by object type and category

reason is Access already allows us to sort by object type. so adding the object type doesn't help. however, Access doesn't allow us to use the same names for tables and queries. and that's where the object type suffix come in to differentiate the two.

whao guys, really good discussion here. i really wish i could start over in my project and incorporate all these. naming all my PKs just as PK and my table, queries and forms with an object type suffix. oh well, hopefully i even survive through this project sigh.

but thanks once again so much guys, really good stuff! = )
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Access

From novice to tech pro — start learning today.