Results 1 to 3 of 3
  1. #1
    drunkenneo is offline Competent Performer
    Windows XP Access 2007
    Join Date
    Jun 2013
    Posts
    199

    Query to be editable without distinct

    I have a query:



    Code:
    SELECT purchaseOrder.poId,  purchaseOrder.poYear, purchaseOrder.poDate, purchaseOrder.userId,  purchaseOrder.currencyId, purchaseOrder.poSendDate, partnerDetails.name
    FROM  purchaseOrder INNER JOIN (orderDetails INNER JOIN partnerDetails ON  orderDetails.partnerDetailsId = partnerDetails.partnerDetailsId) ON  Cstr(Format(purchaseOrder.poId,"00000")) =  Nz(MID(orderDetails.poNo,6,5),"0");
    Simple join query gives dup entries also, i need in single entry.
    When using Distinct query for the form control source, the record is uneditable, can i get the records without dups.

  2. #2
    JoeM is offline VIP
    Windows XP Access 2007
    Join Date
    Jun 2012
    Posts
    3,904
    Simple join query gives dup entries also, i need in single entry.
    Then either your join is not correct (not complete) or you have a one-to-many relationship (or many-to-many) relationship.
    If you can correct your join so you have no duplicates, then it might be editable. But using DISTINCT or an Aggregate Query will always make a query uneditable, as it combines records into a single row, so it would have no idea which record to edit (if you try to edit it).

    Without seeing what you data looks like in each of your tables and understanding the relationship between the two tables, I don't know if we can help you fix your join.

  3. #3
    NTC is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    Nov 2009
    Posts
    2,392
    or another answer is; no one cannot make a distinct query editable. So you have to figure out a work-around. one could be to set up forms/subforms so you can edit the data rather than a join via query. another approach is to write to a temp table, edit the temp table - then write the results back to the regular table. it is situational to your data structure and what you are needing to accomplish.

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

Similar Threads

  1. Editable Form with select query
    By drunkenneo in forum Access
    Replies: 2
    Last Post: 01-07-2014, 05:18 AM
  2. Make sub query un-editable
    By esh112288 in forum Forms
    Replies: 2
    Last Post: 11-11-2012, 06:35 PM
  3. Distinct query?
    By Kivan in forum Queries
    Replies: 3
    Last Post: 08-29-2012, 10:16 PM
  4. distinct query
    By slimjen in forum Queries
    Replies: 3
    Last Post: 02-04-2012, 04:44 PM
  5. Replies: 4
    Last Post: 04-09-2010, 02:16 AM

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