Results 1 to 11 of 11

Thread: query -> form?

  1. #1
    Join Date
    Jun 2008
    Posts
    24

    Unanswered: query -> form?

    ok i have create a form form a query because i need to search for a particular record and then edit it. but when i try to edit the record nothing happen. it won't allow be to edit anything. what am i doing wrong do you need to set a special propotys or are querys only for outputs? if so what is the best way to go aboyut what i want

  2. #2
    Join Date
    Dec 2002
    Location
    Préverenges, Switzerland
    Posts
    3,740
    some query results MUST be uneditable.
    for example:
    SELECT lastName & ", " & firstName AS FullName FROM myTable
    the data engine has no idea what to do with edits that you might make to the FullName field.

    not only with calculated fields - you can also get the same uneditable situation with JOINs

    post the query SQL.

    izy
    currently using SS 2008R2

  3. #3
    Join Date
    Jun 2008
    Posts
    24
    SELECT Transaction.Part, Transaction.Items, Transaction.Surname, Transaction.[Order Status], [Transition Dates].[Booked In], [Transition Dates].[Booked In Sign], [Transition Dates].[Sales Quote], [Transition Dates].[Sales Quote Sign], [Transition Dates].[Sales Order], [Transition Dates].[Sales Order Sign], [Transition Dates].[In Work], [Transition Dates].[In Work Sign], [Transition Dates].Completed, [Transition Dates].[Completed Sign], [Transition Dates].[Booked Out], [Transition Dates].[Booked Out Sign], Transaction.Due
    FROM [Transaction] LEFT JOIN [Transition Dates] ON Transaction.[Transation code] = [Transition Dates].[Transaction Number]
    WHERE (((Transaction.Surname)=[Enter Surname]));

  4. #4
    Join Date
    Dec 2002
    Location
    Préverenges, Switzerland
    Posts
    3,740
    the JOIN is definitely contributing to your query being un-editable. there may be a simple fix with a slightly modified query but i can't help - (i use unbound forms so this doesn't happen to me).

    izy
    currently using SS 2008R2

  5. #5
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    It would really help if we could see your database structure.
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!


    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

  6. #6
    Join Date
    Jun 2008
    Posts
    24
    how do i show that?? do u mean from the relationship window?

  7. #7
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    Sure, that's one good way... if the whole thing can be shown and all tables are shown.

    Print-screen it, paste into a gfx editor, save it as a JPG and upload the JPG.
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!


    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

  8. #8
    Join Date
    Jun 2008
    Posts
    24
    http://img84.imageshack.us/img84/495...ionshipss2.jpg
    By linoukus at 2008-06-18

    here u go

    and yes transaction code, transation number and transaction are all the same thing and the relationship works find
    Last edited by linoukus; 06-18-08 at 12:43.

  9. #9
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    Transaction.[Transaction Code] should be the primary key field.
    Both relationships should have Enforce Referential Integrity on.

    Once that is done, try using an INNER JOIN rather than a LEFT JOIN.

    Should be good to go then... with any luck
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!


    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

  10. #10
    Join Date
    Jun 2008
    Posts
    24
    Quote Originally Posted by StarTrekker
    Transaction.[Transaction Code] should be the primary key field.
    Both relationships should have Enforce Referential Integrity on.
    this fixed my problem and now it is working find

    Once that is done, try using an INNER JOIN rather than a LEFT JOIN.

    Should be good to go then... with any luck
    doing this caused my query to put out blank results and i returned it back to LEFT JOIN

    thanks you for you help

  11. #11
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    You're welcome

    It's always wise to post up details of table design, it really does help
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!


    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

Posting Permissions

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