Results 1 to 3 of 3

Thread: get a primary record from a linked table (resolved

Threaded View

  1. #1

    Thread Starter
    Still learning kebo's Avatar
    Join Date
    Apr 2004
    Location
    Gardnerville,nv
    Posts
    3,762

    Resolved get a primary record from a linked table (resolved

    I have a DB with the following 2 tables....

    EventsTable
    EventID -auto number primary key
    more fields...


    ScheduledEventsTable
    ID - foreign key pointing to a record in the Events table
    ScheduledDate - date the event should fire
    more fields....

    I am using the following command string to get all scheduled event between 2 dates and it works...

    Code:
    Dim cmdString As String = String.Format("SELECT * FROM ScheduledEvents WHERE EventDate BETWEEN #{0}# AND #{1}#", startdate, enddate)
    but what I really want is the record from the Events Table that corresponds with the forign key in the ScheduledEvents table.
    Can someone help me do this?
    I apologies if my terminology isn't right. Although I've be programming since there was dirt, I'm rather new to DB stuff.
    thanks
    kevin
    Last edited by kebo; Nov 16th, 2009 at 04:51 PM.
    Process control doesn't give you good quality, it gives you consistent quality.
    Good quality comes from consistently doing the right things.

    Vague general questions have vague general answers.
    A $100 donation is required for me to help you if you PM me asking for help. Instructions for donating to one of our local charities will be provided.

    ______________________________
    Last edited by kebo : Now. Reason: superfluous typo's

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width