# Help with table selection from a join table. TPS and NetTalk

**URL:** <https://clarionhub.com/t/help-with-table-selection-from-a-join-table-tps-and-nettalk/9474>\
**Category:** questions\
**Tags:** nettalk, browse, tps\
**Created:** [November 2, 2026, 5:11pm UTC](https://clarionhub.com/t/help-with-table-selection-from-a-join-table-tps-and-nettalk/9474 "2026-11-02T17:11:38Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![rjolda](https://clarionhub.com/letter_avatar_proxy/v4/letter/r/898d66/32.png) [@rjolda](https://clarionhub.com/u/rjolda)\
**Post date:** [November 2, 2026, 5:11pm UTC](https://clarionhub.com/t/help-with-table-selection-from-a-join-table-tps-and-nettalk/9474/1 "2026-11-02T17:11:38Z")

</div>

Hi, I have A Join table between owners and autos - essentially, several "owners" can be linked to a single Auto with the JOIN Table. This gives them access to the AUTO's documents. However, I want them also to be able to change the Auto's Documents. It seems like the View Table has to be based on C\_Auto in order to be able to CHANGE the auto data. (I have it set up on displaying the data on the JOIN table and accessing the Auto data but I can't get it to edit the Auto Record. ) Here are the tables.

```clarion
C_Auto FILE,DRIVER('TOPSPEED'),OWNER(' *****'),NAME(autoname),PRE(CAT),CREATE !A_AUTOS.TPS
OWNER_KEY KEY(CAT:Owner_GUID),DUP,NOCASE !TO FIND BY OWNER GUID
AUTO_GUID_KEY KEY(CAT:Guid),DUP,NOCASE !BY AUTO GUID
VIN_KEY KEY(CAT:VINnumber),NAME('CAUT_VIN_KEY'),NOCASE !VIN NUMBER
GUID_KEY KEY(CAT:Guid),PRIMARY,NAME('CAUT_GUIDKEY'),NOCASE
FK_ACCT KEY(CAT:Owner_GUID),DUP,NAME('CAUT_FK_ACCT'),NOCASE
fK_DEALER KEY(CAT:DEALR_GUID),DUP,NAME('CAUT_fK_DEALER'),NOCASE
record RECORD
Guid STRING('glo:st.MakeGuid()')
Owner_GUID STRING(16)
GROUP_GUID STRING(16) !If we want to group several cars under one OWNER, This is the link to the GROUP - get from A_GRPS and JOIN
DEALR_GUID STRING(16) !Dealership IHId
auto_name CSTRING(50) !auto description
auto_MFGR CSTRING(40) !manufacturer
 .....
 
                  END
                END
JN_AUTO FILE,DRIVER('TOPSPEED'),OWNER(' ****'),ENCRYPT,NAME(AUTOJOINNAME),PRE(HAJ),CREATE !Joins Autos with GUID of OWNER or GUID of DRIVER to accumulate list of drivers - so drivers can request service These people get Login rights
GUID_KEY KEY(HAJ:Guid),PRIMARY,NOCASE
FK_AUTO KEY(HAJ:AUTO_guid),DUP,NOCASE !guid link to auto
record RECORD
Guid STRING('glo:st.MakeGuid()')
AUTO_guid STRING(16) !GUID OF AUTOMOBILE
Owner_GUID STRING(16) !owner can be a driver
GROUP_GUID STRING(16) !If we want to group several cars under one OWNER, This is the link to the GROUP - get from A_GRPS and JOIN
DRIVER_GUID STRING(16) !This actually comes from A_OWNER as all folks have responsible account. Drivers of one car can be OWNERS OF ANOTHER CAR....
 
.....
                  END
                END

```

JN\_AUTO is Related Many:1 with HAJ:AUTO-guid ---\>\> Cat:GUID So,one auto can have MULTIPLE DRIVERS (by Owner\_GUID) linked to it.

What I want to do is use the JOIN Table to pick the AUTOs to display. ( Something like show AUTOS where selected autos are chosen based on the OWNER\_GUID who is logged on.) I want to be able to CHANGE the C\_AUTO record.

This is TPS database in Net Talk APP.  
It appears that I need the VIEW to be from C\_AUTO in order to be able to call the correct Update\_C\_Auto FORM.  
So, what I am trying to do is set my view from C\_Auto where only JN\_AUTO records filtered by Owner\_GUID is the same as the OWNER\_LOGGED\_ON\_GUID.

I have not been able to set this up using the standard prompts.... is this something that I have to by manually setting the WHERE and file relationship? Seems like it would be easy in SQL but not so easy in TPS.  
Looking for insight and help.  
Thanks.  
Ron

---

<div class="post-metadata">

**Author:** ![PurpleEdge2214](https://clarionhub.com/user_avatar/clarionhub.com/purpleedge2214/32/5109_2.png) [@PurpleEdge2214](https://clarionhub.com/u/PurpleEdge2214)\
**Post date:** [November 3, 2026, 2:54am UTC](https://clarionhub.com/t/help-with-table-selection-from-a-join-table-tps-and-nettalk/9474/2 "2026-11-03T02:54:31Z")

</div>

Hi Ron,

You haven't said what your desired user interface is?

Are you wanting to start with a browse of Users, or are Users already filtered to the logged in user?

If you want to start with Autos do you need to select a User before showing related Autos?

JN\_Auto is most likely a many:many join table and you can create an appropriate JOIN/Browse from either side of the related tables.

Do you think you have something configured incorrectly?

BTW: I threw your question to Claude.ai and it came up with some suggestions that might be worth looking at, but at this stage I think we need a clearer explanaition of what you really want and where the problem is? Maybe some screen shots of where you have currently landed?

---

<div class="post-metadata">

**Author:** ![rjolda](https://clarionhub.com/letter_avatar_proxy/v4/letter/r/898d66/32.png) [@rjolda](https://clarionhub.com/u/rjolda)\
**Post date:** [November 3, 2026, 11:08am UTC](https://clarionhub.com/t/help-with-table-selection-from-a-join-table-tps-and-nettalk/9474/3 "2026-11-03T11:08:08Z")

</div>

Hi Geoff,

The User is already selected by virtue of being the logged in person - thus they are defined by the value:  
HAJ:DRIVER\_GUID = p\_web.GSV('Logged\_GUID')

I am trying to set up a VIEW on C\_Auto filtered by the result from JN\_AUTO where HAJ:DRIVER\_GUID = p\_web.GSV('Logged\_GUID')

I need the view to be based on C\_Auto so that I can call the Update\_C\_Auto form for editing.

Ron

---

<div class="post-metadata">

**Author:** ![rjolda](https://clarionhub.com/letter_avatar_proxy/v4/letter/r/898d66/32.png) [@rjolda](https://clarionhub.com/u/rjolda)\
**Post date:** [November 3, 2026, 1:04pm UTC](https://clarionhub.com/t/help-with-table-selection-from-a-join-table-tps-and-nettalk/9474/4 "2026-11-03T13:04:57Z")

</div>

Here is my View - Which returns no records - but it should return 2 records:

```clarion
ThisView &View
View:C_Auto View(C_Auto)
                      Project(CAT:Guid)
                      Project(CAT:Owner_GUID)
! Start of "View Section"
! [Priority 5000]

! End of "View Section"
                      Join(HAJ:FK_AUTO,CAT:Guid),INNER
                      Project(HAJ:DRIVER_GUID)
                      Join(AON1:GUID_KEY,HAJ:DRIVER_GUID)
                      END
                      END
                    END ! of ThisView
! Start of "After Main View Declaration"
! [Priority 5000]

```

I set the value of HAJ:DRIVER\_GUID which should match the AON1:GUID by key - and this should select the JN\_AUTO JOIN RECORDS which then should display the associated C\_Auto Recors. But not working - showing no records.  
Ron

---

<div class="post-metadata">

**Author:** ![Mark\_Sarson](https://clarionhub.com/user_avatar/clarionhub.com/mark_sarson/32/6132_2.png) [@Mark\_Sarson](https://clarionhub.com/u/Mark_Sarson)\
**Post date:** [November 3, 2026, 2:54pm UTC](https://clarionhub.com/t/help-with-table-selection-from-a-join-table-tps-and-nettalk/9474/5 "2026-11-03T14:54:07Z")

</div>

Hi Ron,

The VIEW looks basically right: C\_Auto as the primary file, then an INNER join to JN\_AUTO through FK\_AUTO. The issue is how it's being limited.

Setting a value in HAJ:DRIVER\_GUID doesn't filter a VIEW. The record buffer has no effect on which records the VIEW returns. Only the VIEW's FILTER does that, and for a NetTalk browse that's the Filter prompt on the browse. A VIEW filter can use fields from the joined files as long as they're in the VIEW, and you already have PROJECT(HAJ:DRIVER\_GUID), so that part is covered.

So on the browse's Filter tab, put something like:

```clarion
'HAJ:DRIVER_GUID = ''' & p_web.GSV('Logged_GUID') & ''''

```

I believe the NetTalk filter is a string expression, so the GUID value has to be wrapped in quotes as shown. It's been a while since I built a NetTalk web server app, though, so please check the exact filter syntax in the NetTalk docs or examples.

You also don't need the nested JOIN to AON1. A join pulls in related records but doesn't restrict anything, so it can go unless you want to display something from the owner file. The VIEW then reduces to:

```clarion
View:C_Auto VIEW(C_Auto)
               PROJECT(CAT:Guid)
               PROJECT(CAT:Owner_GUID)
               JOIN(HAJ:FK_AUTO,CAT:Guid),INNER
                 PROJECT(HAJ:DRIVER_GUID)
               END
             END

```

If it still returns nothing, a few things to check:

1. Does the browse have a Range Limit on its key (for example OWNER\_KEY limited to the logged-in owner)? That would cut out cars where the user is only a driver.
2. Which field are the logged-in GUIDs actually in on those two JN\_AUTO records? Your first post mentioned Owner\_GUID, but the filter uses DRIVER\_GUID.
3. Is Logged\_GUID actually set in the session at that point? A quick p\_web.Trace(p\_web.GSV('Logged\_GUID')) will tell you.

Each auto comes back as a normal C\_Auto row, so the Update\_C\_Auto form should work for Change as usual.

If none of that sorts it, post your Filter and Range settings from the browse and we'll take another look.

Mark

---

<div class="post-metadata">

**Author:** ![rjolda](https://clarionhub.com/letter_avatar_proxy/v4/letter/r/898d66/32.png) [@rjolda](https://clarionhub.com/u/rjolda)\
**Post date:** [November 3, 2026, 5:40pm UTC](https://clarionhub.com/t/help-with-table-selection-from-a-join-table-tps-and-nettalk/9474/6 "2026-11-03T17:40:13Z")

</div>

Hi Mark,  
SOLVED  
Thanks for your explanation. It really helped me hone in on the problem.  
I removed A\_Owner table, I added a Key on C\_Auto ( Guid\_KEY) - this is the link to the JN\_AUTO table. I took out the ranges I had set up in the NT Browse and did a simple filter on Driver Guid -

```clarion
'HAJ:DRIVER_GUID = ''' & p_web.GSV('Logged_GUID') & ''''

```

So my View looks like this:

```clarion
ThisView &View
View:C_Auto View(C_Auto)
                      Project(CAT:Guid)
                      Project(CAT:Owner_GUID)
                        Join(HAJ:FK_AUTO,CAT:Guid),INNER
                      Project(HAJ:DRIVER_GUID)
                      END
                    END ! of ThisView

```

After a little fiddling as above, got it working!  
MANY THANKS for your detailed explation.  
Ron
