PC Review


Reply
Thread Tools Rate Thread

Getting a subform to display the correct data

 
 
danny.eve@gmail.com
Guest
Posts: n/a
 
      29th Jun 2007
I'd really appreciate help with a subform problem I'm having. I know
it's a basic problem but I've looked at the Northwind and other sample
databases and haven't come close to finding a solution.

My database is for displaying words in a foreign language and links
between the words as follows:


SameMeaning - being words with the same meaning. An example for the
word "speed" would be "rapidity".
SameSound - being words with the same pronunciation but different
meaning. An example for the word "sun" would be "son".
OppositeMeaning - being words with the opposite meaning. An example
for the word "cold" would be "hot".
Usage - being a word that combines with the word to create a phrase.
An example for the word "lie" would be "to tell a".
Distinguish - being words that are important to distinguish from
another due to common mistakes. An example for the word "your" would
be "you're".
TransIntrans - being transative and intransative versions of the same
verb. An example for the word "to tell" would be "to be told".
Misc - being a word which is somehow linked but whose relationship
does not fit into any of the above catagories. An example for the word
"politician" would be "politics".


The table structure is (following help from the tabledesign
newsgroup):

tblWords:

WordID (Primary Key)
OriginalLanguageWord
PhoneticReading
English


tblRelateTypes:

RelateTypeID (Primary Key)
RelateDescription


tblWordRelates:

WordRelatesID (Primary Key)
OriginalWordID (tblWords WordID is foreign key)
RelateWordID (tblWords WordID is foreign key)
RelateTypeID (tblRelateTypes RelateTypeID is foreign key)


I want to have a subform on frmWords which displays the appropriate
WordRelates for each tblWords record.

The problem I have is that however I try to make the subform (using
the wizard or through a query) I can't find a way for the subform to
properly display the related word via it's OriginalLanguageWord field.
I can easily display the WordIDs of both the original and RelateWord,
but when I try to display the OriginalLanguageWord or PhonicReading
fields, only that of the OriginalWord is displayed. This is I believe
because tblWordRelates is linked by foreign key to tblWords twice. In
any query or wizard box if I select the "OriginalLanguageWord" field
it displays the OriginalLanguageWord of the record in tblWords.

An example:

tblWords:
WordID: 18
OriginalLanguageWord: houfu
PhoneticReading: houfu
English: wealth, abundance

WordID: 85
OriginalLanguageWord: yutaka
PhoneticReading: yutaka
English: abundance


tblRelateTypes:
RelateTypeID: 1
RelateDescription: Same meaning


tblWordRelates:
WordRelatesID: 1
OriginalWordID: 18
RelateWordID: 85
RelateTypeID: 1



When I create a subform for frmWords then navigate to record 18, the
subform displays the WordRelatesID (1) and RelateDescription (Same
meaning) perfectly, but the OriginalLanguageWord and PhoneticReading
fields are those of record 18 again, NOT of record 85, the related
record. With all the methods (queries, wizards, relationships window,
etc.) I can find no way to assign the OriginalLanguageWord and
PhoneticReading fields to display the related word, rather than the
original. Anyone have any tips? Your help will be much appreciated.

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
unbound subform on unbound form: getting data into subform EVPLS Microsoft Access Form Coding 1 19th Jan 2008 07:09 PM
Subform button not getting correct record Chris Microsoft Access Form Coding 4 8th Jan 2008 11:53 PM
Urgent !!! - Values from Subform - #Error if no records in Subform and Only grabs first subform record Greg Microsoft Access Forms 0 17th Feb 2005 02:12 PM
Trouble getting correct info on Subform =?Utf-8?B?RnlzaA==?= Microsoft Access Form Coding 1 15th Nov 2004 05:00 PM
Getting the Correct Column to Display in a Lookup =?Utf-8?B?RHJldyBSYWlud2F0ZXI=?= Microsoft Access 1 23rd Apr 2004 12:39 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 03:41 PM.