Query which is the source of a form

Sniper-BoOyA-

Registered User.
Local time
Today, 12:55
Joined
Jun 15, 2010
Messages
204
Good Afternoon,

Ive made a form based on the following query

Code:
SELECT queryverdgrdklei.*, queryproctwtrgeh.dgrdichthdaanwh2o, ([drgdichthdmnstrinsitu]/queryproctwtrgeh.dgrdichthdaanwh2o)*100 AS verdgrdklei
FROM queryverdgrdklei LEFT JOIN queryproctwtrgeh ON queryverdgrdklei.tbllabgegevens.monsternr = queryproctwtrgeh.monsternr;

Which simply produces a list of samples, plus the related numbers / results from tests. And at the end those numbers are used to calculate the density.

On the same form i have a button that will take the user to a selection form, where the user can select the sample they want for testing. Every selected sample gets a ProctorID.

Sometimes its necesarry to "link" more samples to 1 ProctorID.

That is when it becomes complicated ,and i cant get it to work

I made a new table with ProctorID and Samplenr.

ProctorID will look in table Proctor for the ProcotIDs that have been made.
Samplenr will look in table Labdata for the samples that have been added to the database.

Made a form for it so the user can get select the data needed, and when the user clicks on "ok" it runs an Add-Query which will add the ProctorID and SampleNR from table Proctor to the new table i made.

add query looks like this :

Code:
INSERT INTO tblmnstrproct ( ProctorID, Monsternr, Opvnr )
SELECT queryproctor.proctorID, queryproctor.tblverdgrdklei.monsternr, queryproctor.opvnr
FROM queryproctor;


Then its a matter of adding the table i made to the query displayed above. Which will look like this :

Code:
SELECT queryverdgrdklei.*, queryproctwtrgeh.dgrdichthdaanwh2o, ([drgdichthdmnstrinsitu]/queryproctwtrgeh.dgrdichthdaanwh2o)*100 AS verdgrdklei
FROM (queryverdgrdklei LEFT JOIN tblmnstrproct ON queryverdgrdklei.tbllabgegevens.monsternr = tblmnstrproct.Monsternr) LEFT JOIN queryproctwtrgeh ON tblmnstrproct.ProctorID = queryproctwtrgeh.proctorID;

The result is exactly what i want. But now that i added that table, i CANT add/edit or do anything on that form anymore.

Any ideas what causes the fact that it locks the form? Or do you think i should do it totally different?
 

Users who are viewing this thread

Back
Top Bottom