Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

Display last related record on portal row


This topic is 6668 days old. Please don't post here. Open a new topic instead.

Recommended Posts

Posted

I searched the forum and couldn’t seem to find this, but I am sure that this has been requested by others.

I have a portal and want to show the last related record in the portal. I have People > Jobs (one person to many jobs ) and Jobs> Contracts (one job to many contracts). I have a job portal on a People layout and I would like to display the last contract written off that job. <>

I was writing a script and this is what I have so far… but it’s not updating the job_display field

GTTR

Go to Record/Request/Page ([Last])

Set field [Job::c_display_last_contract;Contract::cn_apptperiod]

Go to Layout [“People” (People)]

Go to field [Job::jobtab]

I could see this as a common request… but couldn’t find any topics to address this. If you could help or point me to another topic, I would greatly appreciate it.

Thanks in advance.

Posted (edited)

Assuming you have a JobDate or creation Date on each record why can't you sort the portal on date in descending order?

In layout mode double click on the portal and Check sort portal records. Then click on Specify sort and set up your sort order by Job Date descending.

You could also add a sort command to your script and do the same.

Of course the same would hold true if you use a JobID or any date/number type field.

HTH

Edited by Guest
Posted

I do have a job creation date & primay keys... but I am looking for the last Contract written (another table) to be posted in the job portal.

So I have jobs in a portal (sorted by their dept and then creation date) Contracts are written off jobs and I would like to display on the job portal, the last related record in the contract table.

Does that make sense?

Posted

Do you mean you only want the last contract to show?

If yes, then why the portal? Portals are usually to display multiple records, but then, never say never.

If that's the case you could still sort in descending order and just have a one line portal.

Otherwise, I think you would need to set up a filter in your TO, but, I'm not the greatest with that. Try a search on filtering portals and you may find the answer.

Posted

I have multiple jobs in a portal.... and for each job there can be contract(s) written.... For job ABC, there could be a fall contract, a summer contract and next summer contract. On the Job ABC portal row- I want the Summer 2007 contract to display to show the last contract written against that job.

I have made a very very simple database.... to show what the goal is.

Any assistance will be greatly appreciated.

I can see this as a common request (no??)... for instance, invoice and multi payment solution. I might not be explaining myself correctly. <?>

Thanks in advance

lastcontractdisplayed.zip

This topic is 6668 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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.