June 6, 200817 yr I have searched to find a solution to what is probably a very simple question. I have a client layout with a portal that displays all the invoices for that client. I want to limit the portal display to a specific year. Tried creating a global field gFilter which I related to the Year field. Then set the value of the gFilter in a script to use as a find but that did not work. There are a number of portal queries in the Forum but I have not been able to get any of them to fit my circumstance or possibly I have not understood them. Any help greatly appreciated. Thanks Mitch
June 7, 200817 yr If gFilter is indeed a global field and your portal relationship is keyed from this global field to your INDEXED year field on the child TO, then it should work. Not sure what you are talking about "script to use as a find" though... No scripted find would be necessary, just a setting of the global field to the year that you want.
June 7, 200817 yr Author Mr Vodka thanks for the reply. I have as my main table one called Operators it is linked to a table called Batches by the operator ID. In my batch table I have a transaction date and a field called TYear which simply extracts the year. Then a global field gFilter in the Operators table. In my relationships two occurrences of Operators one linked OP ID to OP ID the other TYear to gFilter. From a layout of a list of operators I click a button which calls a scrip which asks for the year. I need to pass that year to the gFilter so as the layout with the portal is restricted to the invoices for that year only. I hope I have explained this properly. The Tyear field is indexed. Thanks Mitch
June 7, 200817 yr Your relationship should be keyed as such pkOperatorID = fkOperatorID gFilter = TYear Try entering a year in manually to see if its your script.
June 7, 200817 yr Author Thank you I created the relationships with one table not two I think thats what I understood your advice to be and it worked. Thank you very much. Mitch
Create an account or sign in to comment