Solved Update field and Validation criteria (1 Viewer)

Pat Hartman

Super Moderator
Staff member
Local time
Today, 05:57
Joined
Feb 19, 2002
Messages
42,981
Autonumbers are simple sequential or randomly generated numbers intended to be used as unique identifiers. It is confusing to use "ID" as the suffix to anything other than an autonumber. YOU can of course name your fields anything you want. However standards help you and others to identify and understand relationships. If the PK of a table is an autonumber that's fine. If you have an additional unique identifier that is a custom-generated string, that's fine. HOWEVER, the custom string is NOT stored in multiple places. It exists ONLY in the one table where it defines a record and it must also have a unique index to ensure there are no duplicates. In the second table, the FK points to the autonumber NOT to the custom-sequence number.

And NO, an autonumber cannot be used as you want. If you want a custom prefix, you must generate the code yourself. Here's a sample database that shows an example. Remember, these custom identifiers are just that - CUSTOM. So, don't expect the example to be exactly what you need. It shows the concept of concatenating a generated sequence number with other fields to make a unique code.
 

Attachments

  • CustomSequenceNumber20210303.zip
    93.7 KB · Views: 112

lacampeona

Registered User.
Local time
Today, 10:57
Joined
Dec 28, 2015
Messages
392
Hi,
thank you very much for explanation and sample database.
I will check all my fields and make correct relationship and logic PK and FK keys.

I also must say that on this forum I find a lot of good sample databases ,good advices and examples of codes. All experts that are answering questions, resolve problems deserve special thanks. This is realy nice. You are sharing your knowledge with others. And you are doing all that for free.

If I want to watch movies on Netflix I have to pay and here If I need help I dont have to pay nothing. That is very important. Becouse sometimes you have people who have money and they can buy databases but they dont know how is working and they are not interested and sometimes you have normal people who wants to learn and dont have so much money. In another web pages I find examples and you have to pay 10, 20, 30 or more $ just for one database to just see what the database is doing, and here you can find, see the code and study how to implement that later in your database. This is realy very nice and good idea for begginers and others to learn.

When I was young one day I click by mistake MS Access. Ms access opens and I didn know what to do? In word I knew that I have to write letters or something..In access I just check the menus,...and then close the program. I was like surprised what is that, what you have to do in that program who is using that and why?

If someone would tell me that me in the future will know to write codes and making butttons or that I will be capable to make a MS program I would just say ahhh that is impossible. Becouse I dont have so much knowledge to write all the codes by myself. And here with all your help everythink is possible.

Without all that help that you guys offer here to us bad/medium begginers and others ( we send question and in minutes we already have answers!) our databases could not progress.

Thank you very much for all your time, patience and examples.
 

Pat Hartman

Super Moderator
Staff member
Local time
Today, 05:57
Joined
Feb 19, 2002
Messages
42,981
You're welcome. I came to Access as an experienced COBOL developer. I was already comfortable with relational database since they've been in the mainframe world since the 70's which gave me a huge step up. But I did have to teach myself a whole different way of thinking in order to successfully create and control objects (forms, reports, queries) in Access. VBA was actually less of a challenge since it is the same kind of language as COBOL and have many elements in common.

I help because Access has been very good to me over the years and provided well for my family. I want to see more people learning to use this very powerful and "easy" to use development platform so that MS will keep it alive and well. Getting into Access development is trivial compared to other development environments. The majority of people who use Access are self taught using books and YouTube and forums like this one. Try that with C++.
 

lacampeona

Registered User.
Local time
Today, 10:57
Joined
Dec 28, 2015
Messages
392
Hi
I never hear about COBOL. So then yesterday I make a google search. Very interesting programe language.

I am also searching a lot on internet and watch also video, codes to learn MS Access.

It is so nice to hear your begginings. Yes I undesrarand that you had to learn a lot by yourself and with all your effort you make a great road in access to perform what is not possible to be possible and now we begginers and others are learning a lot with all the experience from you and others -the great MS Access experts.
Thanks again to all of you
 

Users who are viewing this thread

Top Bottom