Results 1 to 4 of 4
  1. #1
    cap.zadi is offline Competent Performer
    Windows XP Access 2007
    Join Date
    May 2011
    Location
    KSA
    Posts
    481

    May it is Dlookup

    Gentleman, can some one help out here: i have created a database in which have following tables:



    table1 (TagNo,EmpID, EmpName,ProductCode,ProductName, CastedQty)
    table2 (TagNo,EmpID, EmpName, ProductCode,ProductName,PassedQty,RejectQty)

    The TagNo is a numerical serial no (100) which is enter at table1 and all other information through combobox and the castedqty.

    when come to Table2, so collect the same TagNo which is entered in Table1 other wise new TagNo cant be entered here till it is not in Table1.
    so i just want here when i select TagNo in Table2 so all other information from that Table should be displayed so that i could not enter new information like ProductCode, ProductName.

    I have subform which shows the information from last table when select the TagNo but i want it to be in main form and just i select some other information on it and this form should be filled.

    waiting.

  2. #2
    alansidman's Avatar
    alansidman is offline VIP
    Windows 7 32bit Access 2007
    Join Date
    Apr 2010
    Location
    Steamboat Springs
    Posts
    2,529
    Having two tables containing the same data is against the normalization rules of relational databases. I would urge you to read the link below and then re-design your database to a normalized one. Non normalized databases create a need for lots of work arounds when you attempt to retrieve data through queries. Relook at your design.

    Be sure to download the attachment and read it closely. It is very informative.

    http://forums.aspfree.com/microsoft-...es-208217.html

  3. #3
    cap.zadi is offline Competent Performer
    Windows XP Access 2007
    Join Date
    May 2011
    Location
    KSA
    Posts
    481
    Dear

    You are right but in my work it works in this way.

    Having 5 steps of processing. like casting, control, spraying, kiln loading and sorting.

    each steps performs some work on product and there is emp working in this section.

    so what i do i come to bring a tagno which is a number from data collection form in pratically moving from section to section.

    then have many tables, like product table, section table,s color table, product table, emp table in which i block emp for each section by designation so can be appear in combobox only those related to each dept.

    The TagNo is only entered once in 1st section form and in others it is followed by combobox to make sure the smooth process and not missing data at any step.

    now the productcode and productname is just once entered at 1st step and attached to one TagNo and then it should just display at each form as TagNo is entered and just some work will be performed on this section and some data wil be enetred for the products.

    so what do you advise plz now?

  4. #4
    alansidman's Avatar
    alansidman is offline VIP
    Windows 7 32bit Access 2007
    Join Date
    Apr 2010
    Location
    Steamboat Springs
    Posts
    2,529
    Based upon what you have shown, I think that you would have something similar to the following.

    Main Table
    -------------
    ProcessID (PK)
    TagNo
    EmpID (FK)
    ProdID (FK)
    Process (FK)
    QtyProcessed
    PassedQty
    RejectQty

    Employee Table
    --------------
    EmpID (PK)
    EmployeeName

    Product Table
    -------------
    ProdID (PK)
    ProdName

    Processes Table
    ---------------
    ProcessID (PK)
    ProcessName (ie.Casting, Control, Spraying,etc)

    You may need other tables for identification of other fields in your primary/process table.
    I hope this gets you started in the right direction. This may not be exactly what you need, but is probably close enough to get you strated. I also hope you read the white paper closely to better understand the normalization principles.

    Alan

Please reply to this thread with any new information or opinions.

Similar Threads

  1. DLookup
    By smidgey in forum Forms
    Replies: 13
    Last Post: 01-19-2011, 09:27 AM
  2. DLookup Help
    By Alex Motilal in forum Queries
    Replies: 3
    Last Post: 01-17-2011, 02:01 PM
  3. dlookup help
    By gsantacruz in forum Programming
    Replies: 9
    Last Post: 10-11-2010, 11:46 AM
  4. DLookup()
    By jgelpi16 in forum Programming
    Replies: 2
    Last Post: 09-15-2010, 07:20 AM
  5. Need help with dlookup.
    By Keith in forum Database Design
    Replies: 8
    Last Post: 05-24-2010, 06:28 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums