3 Replies Latest reply on Aug 24, 2010 11:06 AM by FentonJones

    Naming Protocols

    Mitch

      Title

      Naming Protocols

      Post

      I would like to throw this one out to the forum...

      Is there a standard for the naming of Tables, Fields, Scripts & Relationships.  Especially with the use of upper and lower case letters, spaces & underscores, wording, the lot...

      I am particularly interested to find out, mainly because when a database solution grows in volume and functionality, I am sure that a standard naming protocol would make it easier when another developer is called to problem solve...

       Mitch

        • 1. Re: Naming Protocols
          FentonJones

          This is a white paper which several developers worked on, which FileMaker distributes.

          White Paper:  FileMaker Development Conventions

          Some styles, like upper and lower case, can be chosen by the developer. But consistency (within that solution anyway) is important.

          I have my own convention, which follows most rules, but "bends" them a little in some cases. That is likely true for all independent developers. 

          My basic rules are:

          1. Alphabetical. The name must sort into the position where I'd expect to find it. For fields sometimes I use "noun_adjective" instead of English's "adjective_noun" (many other languages use noun-adjective).
              a. On the relationship graph, this means its place in the structure, incl. the full table occurrence path (can be abbreviated, as long as still alphabetical), ie., beneath its "parent").

          2. Brevity. The name must be short enough that I don't waste time reading extraneous info.

          • 2. Re: Naming Protocols
            davidanders

            For related text fields I use the noun adjective format - NameFirst, NameLast, NameMiddle

            AddAddress1, AddAddress2, AddPOBox, AddCity, AddState, etc etc

            • 3. Re: Naming Protocols
              FentonJones

              I might break that up with underscores. I find that in some cases they are heck lot more readable than camel-case. True, they can be a bit misleading in table occurrence names. But I seldom use field names in TOs, except when really needed. I use a "~" to separate them in that case; and I might just camel-case one there, if needed. As I said earlier, I sometimes "bend" the rules. I've learned over the years what is best for me; we all do.

              add_Address1
              add_PO_Box
              add_City
              add_State