Welcome to SPN

Register and Join the most happening forum of Sikh community & intellectuals from around the world.

Sign Up Now!

Combining data from two tables in one entry on a form.

Discussion in 'Information Technology' started by rg, Jul 28, 2006.

  1. rg

    rg
    Expand Collapse
    Guest

    I have a form where I am combining data from two different tables in a text
    box on the form. If I use only the data from one table, this works. EX:
    =[Strand] & [CS] & [Grade] & [Number]
    The form is not based on the Strand table, but I don't want [Strand], I want
    the Id field from the record in the Strand table that is linked to the form's
    table through [Strand]. I don't know how to include the data from the linked
    table. Whatever I try gets either the #Error, or the #Name? error. How do I
    get the ID data from the Strand table?
    -rg
     
  2. Loading...


  3. Steve Schapel

    Steve Schapel
    Expand Collapse
    Guest

    Rg,

    I think the general answer here would be to include the Strand table
    into the query that the form is based on, joined to the existing record
    source table on the Strand field (if I understand you correctly), in
    which case you will have the required field from the Strand table
    available for inclusion in your calculated control on the form.

    --
    Steve Schapel, Microsoft Access MVP

    rg wrote:
    > I have a form where I am combining data from two different tables in a text
    > box on the form. If I use only the data from one table, this works. EX:
    > =[Strand] & [CS] & [Grade] & [Number]
    > The form is not based on the Strand table, but I don't want [Strand], I want
    > the Id field from the record in the Strand table that is linked to the form's
    > table through [Strand]. I don't know how to include the data from the linked
    > table. Whatever I try gets either the #Error, or the #Name? error. How do I
    > get the ID data from the Strand table?
    > -rg
     
  4. rg

    rg
    Expand Collapse
    Guest

    Yes, that would be the answer. I was trying to base the form on the table
    rather than a query. oops. Thanks for you reply.
    -rg

    "Steve Schapel" wrote:

    > Rg,
    >
    > I think the general answer here would be to include the Strand table
    > into the query that the form is based on, joined to the existing record
    > source table on the Strand field (if I understand you correctly), in
    > which case you will have the required field from the Strand table
    > available for inclusion in your calculated control on the form.
    >
    > --
    > Steve Schapel, Microsoft Access MVP
     

Share This Page