Newbies FMNext Posted November 4, 2005 Newbies Posted November 4, 2005 To validate the duplicated record , I used SELF relational and serial# to do like this if serial# <> SELF.serial# then DupFlag is TRUE otherwise DupFlag. It works fine in version 5.5 or 6.0, but it seems NOT work properly in version. DupFlag is always TRUE even there is no duplicated record. I just switch to Version 8, still new to it since the architect of 8 is totally diff from its earlier versions. Any help or idea woulf be appreciated very much Thanks guys.
LaRetta Posted November 4, 2005 Posted November 4, 2005 So you are testing for match on same field it is joined on? Is it joined on serial = SELF::serial and then your calculation is testing as? "If serial# <> SELF.serial# then DupFlag is TRUE otherwise DupFlag." ... then you said: "DupFlag is always TRUE even there is no duplicated record." This is a contradiction from your first sentence. NO serials would relate if joined on = except for dup but ALL serials (except for dup) would relate according to your calculation ... mixing apples and oranges, me thinks. It would have been better to paste your specific calculation here (and specify your join) ... it took you just as long to type it free-form and your exact syntax may have helped us. If() has changed starting in vs. 7. Is this serial an auto-enter incrementing serial? Because FM will NEVER duplicate this serial when you duplicate a record anyway!! Unless you mean you create an auto-enter by calculated uniqueID and you just CALL it serial? The logic is escaping me. Is serial number or text? Try this: Join serial to SELF::serial on = then appropriate test (via another calc) would be: If serial is number and calculation result is text: If ( SELF::serial ; "Dup") If serial is text and calculation result is text: If (not IsEmpty ( SELF::serial) ; "Dup" ) If serial is number and result is number (boolean) not not SELF::serial ... last will produce 1 (or true) if duplicate. LaRetta :wink2:
Newbies FMNext Posted November 11, 2005 Author Newbies Posted November 11, 2005 Sorry for not making it clear myself. Here is what I try to do. I want to build a small DB to allow swimmer to register their swim meet. One of the validation is that they CANNOT have duplicated event number with the SAME Meet ID. File: SwimMeetEntry.FP5 Serial#: number, increase by 1, cannot modify Meet ID: number Event Number: number , valid only DupFlag = 0 DupFlag: Case ( IsEmpty(Event); 0; Serial# = SELF Relation name::Serial#;0;1) Self relational by MeetID = Meet ID and EventNumber =Event Number This set up is work fine under FMP 6, but it's not work for 7 or 8, actually it's not work properly. I am using FMP 8 Advance on Window XP. I could not find where I can attach the file for you to look at it. If you don't mind please give you email then I can send to you. My email address [email protected] Thank you very much for your time
Recommended Posts
This topic is 7110 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now