Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Queries / May 2005

Tip: Looking for answers? Try searching our database.

How to edit data generated by a query

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Merlin - 06 May 2005 20:11 GMT
Can someone tell me what i need to do to allow my data generated by a query
to be edited in a form.  Right now I have my data looking the way it is
suppose to look but I am unable to edit it in a form view.  

Any leads would be appreciated.
Steve Schapel - 06 May 2005 23:17 GMT
Merlin,

Possibly your query in not undateable.  There are a number of factors
that determine whether a query is updateable or not.  You can open the
query's datasheet, and see if it can be edited there, and this will tell
you whether this is the problem.  If you could post back with the SQL
view of the query, someone may be able to advise more specifically.

Another thing to check is the AllowEdits property of the form.

Signature

Steve Schapel, Microsoft Access MVP

> Can someone tell me what i need to do to allow my data generated by a query
> to be edited in a form.  Right now I have my data looking the way it is
> suppose to look but I am unable to edit it in a form view.  
>
> Any leads would be appreciated.
Merlin - 09 May 2005 14:54 GMT
Steve,

The query results cannot be edited at this point.  The following is the SQL
view of the query.  This query was written in ACESS 97 and I am attempting to
update it to 2003.  I have a form that I use to enter data associated with
each project.  The fields that I edit from the form are PROJMGR, CSACOMMENTS,
CSAIFC and CSADES. This is later turned into a report for distribution.
Thanks for your help!

SELECT DISTINCTROW CSA.CSAPROJCD, CSA.PROJNO, CSA.CSAENG, CSA.CSADES,
CSA.CSACOMMENTS, CSA.CSABUD, CSA.CSAETC, ARCHITECTURE.ARCHBUD,
ARCHITECTURE.ARCHETC, PROJECT.PROJTITLE, PROJECT.PROJMGR,
PROJCLIENT.CLIENTNAME, PROJCLIENT.PROJCLIENTMGR, CSA.CSAIFC, HVAC.HVACBUD,
HVAC.HVACETC
FROM (((PROJECT INNER JOIN CSA ON PROJECT.PROJNO = CSA.PROJNO) INNER JOIN
PROJCLIENT ON PROJECT.PROJNO = PROJCLIENT.PROJNO) INNER JOIN ARCHITECTURE ON
PROJECT.PROJNO = ARCHITECTURE.PROJNO) INNER JOIN HVAC ON PROJECT.PROJNO =
HVAC.PROJNO
WHERE (((CSA.CSAPROJCD)<>"X" Or (CSA.CSAPROJCD) Is Null) AND
((CSA.CSAETC)>0)) OR (((CSA.CSAPROJCD)<>"X" Or (CSA.CSAPROJCD) Is Null) AND
((ARCHITECTURE.ARCHETC)>0)) OR (((CSA.CSAPROJCD)<>"X") AND ((CSA.CSAIFC) Is
Not Null)) OR (((CSA.CSAPROJCD)<>"X") AND ((CSA.CSAENG) Is Not Null)) OR
(((CSA.CSAPROJCD)<>"X" Or (CSA.CSAPROJCD) Is Null) AND ((HVAC.HVACETC)>0))
ORDER BY CSA.CSAPROJCD, CSA.PROJNO;

> Merlin,
>
[quoted text clipped - 11 lines]
> >
> > Any leads would be appreciated.
Steve Schapel - 13 May 2005 21:13 GMT
Merlin,

You have a query here with 3 one-to-many relationships, and you are also
enforcing Unique Records (i.e. DISTINCTROW).  Such a query will not
normally be updateable.  It may be possible to make it work by setting
the Recordset Type property of the query to Inconsistent Updates, but I
would very strongly recommend against this, unless you are absolutely
sure of what you're doing.  A preferable approach would be to use a form
based on your Project table, with subforms based on each of your CSA,
ARCHTECHTURE, and PROJCLIENT tables.  This is normally the best way to
use forms to enter/edit one-to-many data.

Signature

Steve Schapel, Microsoft Access MVP

> Steve,
>
[quoted text clipped - 20 lines]
> (((CSA.CSAPROJCD)<>"X" Or (CSA.CSAPROJCD) Is Null) AND ((HVAC.HVACETC)>0))
> ORDER BY CSA.CSAPROJCD, CSA.PROJNO;
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.