Proper Access Naming

H

huangda 晋江兴达机械

Rick Brandt said:
I think someone should point out that what most Access/VB people call a
"Naming Convention" is not necessarily what people in other environments
call a naming convention. What is very common in other programming
environments is a naming convention like...

ClassName
methodName
propertyName
variableName
CONSTANT_NAME

This is then combined with the standard of using no characters besides A-
Z, 0-9, and the underscore.

A naming convention that involves the use of prefixes to "type" an object
is not used much outside of Access/VB and outside of those circles it is
almost universally derided.

That prefixes "make it easier for the next guy" is unsupportable and
frankly laughable. For a developer to see a variable named something
like "emailAddress" and react with "What is it? Is it an Integer?. A
String? This is confusing!" would only mean that he is incompetent.

There are a great many people who *prefer* prefix-naming and are *more
comfortable* when they see it compared to when they don't. To them I say
go ahead and use it. Where I draw the line is when people suggest to
others that your code will look unprofessional if you don't toe the same
line. That is rubbish.
 
S

Stacey Crowhurst

Yes, I need to rename both my field names and all my tables, forms, queries
and reports. I decided to use the Reddick convention and also Graham's idea
about a table prefix on my field names. I hope that the find and replace
utility I downloaded isn't too confusing! I am not a programmer by any means
and the chances that the next person in my department to maintain this
database is a programmer are slim to none. However, I would like concise,
clear and sensible names anyway. So I appreciate all of the feedback.
Thanks again!
 
L

Larry Linson

Graham,

The Reddick Convention covers standards for naming objects, as well as the
prefix and suffix definitions we normally associate with the convention --
including the priority and order of words concatenated to make the names.

If I recall correctly, Greg Reddick does not recommend using prefix or
suffix in the names of Fields in Tables; I could be wrong -- perhaps it was
Stan Leszynski who didn't like prefixes or suffixes in Field names. But I do
remember they disagreed that prefixes/suffixes should be used "everywhere".

Regards,

Larry
 
L

Larry Linson

Rick Brandt said:
What is very common in other programming
environments is a naming convention like...

ClassName
methodName
propertyName
variableName
CONSTANT_NAME

This is then combined with the standard of using no characters besides A-
Z, 0-9, and the underscore.

What you describe here, Rick, is applicable to "object-oriented"
environments. We have had naming conventions of various sorts, in the
computer business, long before OOP was even a gleam in its originators'
brains* -- some were arbitrary, for which you would need the project's Data
Dictionary; others more logical.

* I suspect I used naming conventions before some of
the originators of OOP were even gleams in their
parents' libidos. said:
A naming convention that involves the use of prefixes
to "type" an object is not used much outside of Access/VB
and outside of those circles it is almost universally derided.

IIRC, that is called "Hungarian" because it was proliferated by Charles
Simonyi (sp?) who was in charge of programming at, of all places, Microsoft.
Microsoft, of course, produced VB and the derivative VBA, but did very
little programming in either -- so I am quite certain that "Hungarian" was
used, and widely, outside Access and VB circles.

And, "laughable" and "rubbish", like "beauty" and "value", are in the "eye
of the beholder".

Larry Linson
Microsoft Office Access MVP
 
D

David W. Fenton

Reverse Hungarian.

Oops. No, it's just Hungarian -- the "reverse" part is implicit, and
the whole reason it's called Hungarian, because Hungarian names are
in the opposite order, i.e., I'd be Fenton David in Hungarian.

I guess I knew all of that at one time, but somewhere along the
line, it got tossed out of my brain to store some piece of no doubt
useless information.
 
Joined
Mar 18, 2009
Messages
5
Reaction score
0
A good table of naming conventions is here:

http://www.mvps.org/access/general/gen0012.htm

And, if you want to give a go at renaming your existing data, a tool like Rick Fishers Find and Replace may offer some assistance:

http://www.rickworld.com/products.html

Backup your data incrementally each time you use a global find/replace tool, and after each change test your data to be sure something didn't get foo-barred.

Tux
 
G

Graham Mandeno

Hi Roy

You clearly haven't met Larry. He is indeed a Patrician amongst Patricians
:)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top