Home
Username:
Password:
FileMaker Pro 9: Beginner Tutorials

Validation / Always vs. Data Entry




Visitors to VTC.com will be able to view all introductory videos for each training course.
Free Trial Members will gain access to first three chapters for each training course.
Full Access Members have full access to VTC.com’s entire library of video tutorials.


Learn More

Subtitles of the Movie

The last validation option is to validate only during data entry, which is the default, or to always validate. Now always validate is a little vague, so we're going to show you by example what that means. Let's go into Define or Manage Database and look at these options, and we'll look at it on the state field. Go into state, go into Options, and here's what we're talking about. Only during data entry is what the default is, what does always mean? Well this refers to essentially to an import, and so what we're going to do is we're going to import two different ways. We're going to import with this option, and then with always. So let's stick on this option right now, click OK, and we actually have a sample file in the work files that you can use called valid.tab. So we're going to go to the File menu and choose Import Records, choose file, and you can see valid.tab now. If it's dimmed, that means that you have the wrong file type chosen here. This is actually a tab separated text file, so choose tab separated text and that should make it available. Click on it, and then now we can open it, and the fields should be lined up, but if they're not you might have to rearrange them; and actually in this case you can see they aren't lined up. So let's go ahead and choose, well, let's see, we're actually not going to be able to use matching names because there is no field name. So we'll have to go for first name, check that. Last name, check that. Address is in the right spot now. City should be down here, check that. Uncheck DOB. State's right there, postal code and phone number. Now everything's matched up good. Looks like what we want, double check it. We want Add New Records, make sure you check this always, Add New Records, OK? Don't worry about this, you may have a different choice if you have Windows, and don't import first record if it contains field names, we don't have to worry about that because we don't have field names, so everything looks OK. It's always a good idea to make sure - look at every option here because, you know, I had it on Update and now we want Add, so make sure you have these options set correctly; and then we'll click Import. We don't have to worry about auto-enter because we're actually going to delete these records, they're just tests. So we'll import them, we get our little summary, 2 records were added, 0 were skipped due to errors. Total fields skipped due to errors were 0, and so this looks like it worked pretty good, and if we look at the records, we'll see it's just like the data that we imported from the tab separated files. So that's pretty good. Now let's try it with the other option, but before we do that let's delete all these records. Now we can delete these found records because after an import you have a found set of just what you imported, so we can delete all, quickly get rid of them, and we can actually get rid of this record too while we're at it, you see record 44 here, we'll delete that as well; and let's go to Define or Manage Database. Go down to the state field, go into Options, and we'll choose Always this time. Remember we had that Validation by Calculation, that validates to make sure it's 2 characters only. So we'll click OK, OK again, go through the same procedure, we'll locate valid.tab. It should be already selected on Tab Separated Text here, click Open, should be all lined up already, should be the same options as before. Click Import, don't have to worry about this, so we'll just import; and here's the difference, we got "A record was skipped due to errors." Now it's an interesting occurrence here, we actually had the record completely skipped, you can in fact see there's only 1 record found here. So very interesting, it completely skipped that record, so you may or may not want that to have happened but at this point what you have to do now is go back to that example Tab Separated file and correct it there; and the issue was it had WVA in it. That was 3 characters and you can't have that. So let's go ahead and delete the found records here and let's go back to Manage Database. We'll go back to our state field. Go into Options, and let's take off the Validation by Calculation and go back to a maximum number of characters. Let's see what difference that makes, and we'll try to import again, and locate valid.tab, click Open. It's all matched up, Add New Records, Import, don't have to worry about that Import, and we get a different message here. This time it skipped the field, so the record's there, you can see it. This is interesting how the two different validations differ. So if we look at the second record where the problem is, WVA didn't get entered in there because it had a problem. So in this situation you can choose to put WV in here, or go back and choose the Tab Separated file and correct it and then import again. You have more choices here. So it's interesting to note, again, here's how things work differently. A calculated validation skips the record, in this case with a validation that's just a checkbox such as the length. It appears that it goes ahead and skips that field, so you really got to know the ins and outs of FileMaker to make sure things work correctly for you. So what we're going to do is get rid of these 2 records, and they're gone now, and we'll show all records. See how 0 records are found? We'll show all records, and let's make sure that we go back to the old validation. Even though it skipped the record when we imported, I really like the calculated validation better, I'm going to set that back up. So we'll go back into Manage Database, go to State, uncheck this, check that, and notice that the formula's still in there, FileMaker very nicely kept it in there. So all I have to do is click OK, and now we're validating by calculation again. So again, I know I'm preaching, but make sure you know all the little idiosyncrasies of how FileMaker works, and that's really going to help you in the long run.

Tutorial Information

Course: FileMaker Pro 9: Beginner
Author: John Mark Osborne
SKU: 33783
ISBN: 1-933736-95-X
Release Date: 2007-07-26
Duration: 12.5 hrs / 145 lessons
Work Files: Yes
Captions: Available on CD and Online University
Compatibility: Vista/XP/2000, OS X, Linux
QuickTime 7, Flash 8

VTC Sign up & Benefits

  • Unlimited Access
  • 98,729 Video Tutorials (23,265 free)
  • Video Available as Flash or QuickTime
  • Over 1026 Courses
  • $30 for One Month Access
  • Multi-User Discounts Available