Genx Posted February 17, 2006 Posted February 17, 2006 ... theres a few calcs in my database that are being an absolute pain... one of them that tries to count the number of related records in a related TO will not stop returning a result of ? when another that does almost the same thing gives me a number like i want... there is more than enough room for the content to display... yet still a question mark... there is no formatting on the field... still a question mark... help pretty pretty please? Cheers, genx
Wim Decorte Posted February 17, 2006 Posted February 17, 2006 If the related records are more than one TO away, make sure the complete relational path has related records. Also make sure the type of the calculation is correct (number, not text)
Genx Posted February 17, 2006 Author Posted February 17, 2006 ... it is correct type, related records are only one TO away
Wim Decorte Posted February 18, 2006 Posted February 18, 2006 If they are complex calcs, try pieces of the calc and see if there is one particular piece that doesn't resolve. The Data Viewer in 8 is good for that.
Genx Posted February 18, 2006 Author Posted February 18, 2006 .. once again its simple... but... the calculation was a count on a related field... wouldnt stop returning question mark... so i made a calc field that was local within that table to evaluate to a 1 if it would have been valid according to that relationship and a 0 otherwise... then i just put a calc in the other Table to sum according to an appropriate relationship... yeh....i hate work arounds... ~ genx
Wim Decorte Posted February 18, 2006 Posted February 18, 2006 Is this with 8.0v1? Did you try the same thing with v2?
LaRetta Posted February 19, 2006 Posted February 19, 2006 genx, Until you do what you KNOW you should do ... give us more information ... then there is no way to know what would have ever worked RIGHT!! If you provide a demo, we can answer your question. Until then, it could be any number of things. Just accepting a kludge 'work-around' doesn't allow one to learn from it ... it is probably something simple.
Søren Dyhr Posted February 19, 2006 Posted February 19, 2006 I haven't had many occurances if any "?" until I started to exploit GetNth( referencing unavailiable records, which I sloopishly simple tend to throw throug a Subsititute( to make the appproprate null values. There is made some special points in "... For Mere Mortals" That empty strings not could replace empty fields - so I do usually define it as Case(0;0) to assign a field to VOID - the issue is that if you later changes the field def. to say number or container is it behaving similar. --sd
Genx Posted February 20, 2006 Author Posted February 20, 2006 .. Firstly, LaRetta - Yeh i know, unfortunatley, i cant reproduce it... ive tried, but it just happens, secondly, Soren, i too use substitute in getNthRecord, though this function doesnt reference it... though i cant reproduce it, i will explain exactly how its set up... 2 tables, one is the main table, has a serialid(Table1::serial), a global field containing the value "yes" (Table1::gYes) in it which --> this is used for multiple relationships and a local count calculation (Table1::cCount). Table two, contains a foreign key (Table2::ForeignK), another field (Table2::Field) and a calc which evaluates to "yes" (Table2::cContentCheck) if that field has content in it. The relationship between table 2 and table 1 is: Table1::gYes = Table2::cContentCheck now, the calc in table 1 (Table1::Count) which is equal to Count(Table2::ForeignK) returns a ?.. dunno why... thanks for help, ~genx
Wim Decorte Posted February 20, 2006 Posted February 20, 2006 Is Table2::cContentCheck stored and indexed? Can you put a portal on a layout in table1 and show the records through the Table1::gYes = Table2::cContentCheck relationship?
bruceR Posted February 20, 2006 Posted February 20, 2006 You aren't going to get useful help until you post your calculation. Go into define fields, copy, come over here, paste.
Genx Posted February 20, 2006 Author Posted February 20, 2006 ... i have no clue how posting my calc would help but ok... ok, two things need to be cleared up though im not sure if they effect anything, ill mention them anyway... Table2 is actually another table occurance of Table1... secondly the calc field that returns a yes or no evaluates fine, however it refers to another table occurance... wim, yes i can show records through a portal ... as for the calcs which will likely play no effect in clearing anything up... contentcheck equivilant, evaluates correctly (cValidEmailforsum) If(Count(Property_Email::Relational_ID) > 0 ; "Yes" ; "No" ) cCount equivilant: Count(Prosp_YesRelat::cValidEmailForSum) and no wim i cant store or index because field cContentcheck equiv refers to related, and cCount equiv refers to calc that refers to related... should have mentioned that part... cheers, ~genx
Recommended Posts
This topic is 6915 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