locked
Matching values between tables, to output value of field in <asp:Label> RRS feed

  • Question

  • User-1186309636 posted

    Hi,

     

    I have an Access 2007 database that has two tables, Table1 and Table2.

    I am trying to obtain the value of Field2 in Table2, based on data from Field1 in Table2 matching data from Field1 in Table1.

    The default database connection for this page directs to Table1.

    Is this possible? I have managed to accomplish this with a dropdown box but am wanting to have it as an <asp:Label... so it matches the format of the rest of the page.

    Thanks :-)

    Sunday, March 27, 2011 11:16 PM

Answers

  • User1983249378 posted

    U just need inner join

    Select table1.field1 , table1.field2

    from table1 innerjoin table2 on table1.field1 = table2.field2

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Monday, March 28, 2011 5:01 AM

All replies

  • User1983249378 posted

    U just need inner join

    Select table1.field1 , table1.field2

    from table1 innerjoin table2 on table1.field1 = table2.field2

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Monday, March 28, 2011 5:01 AM
  • User-1186309636 posted

    it took a bit of googling, but worked... :-) Thank you!

    Monday, March 28, 2011 10:38 PM