I have used a global variable of the Account_code, which is the row_ident i have put on the sales ledger table. That makes it a lot quicker rather bringing up an individual record from the Accounts table and linking from the selected record.
It is a little weird because it then seem to show multiple entries from the salesledger table repeating them many time instead of listing each one. Its almost like it create the wrong type of join.
I think i need to speak to SUN accounts to understand why their database doesnt have primary keys on it. Funny thing is it works fine in MS Query.