[AccessD] Record deleted by user

John Colby jcolby at colbyconsulting.com
Fri Sep 12 10:50:03 CDT 2003


In my specific case the point of the table is to create a selected record
for (small) N  number of records in a main table.

In other words, I could simply place a selected flag in the main table.
When the user wants to print a record or handful of records, they set the
selected flag.  The report chooses all records with the selected flag set
and prints them, then the code clears all the selected flags.

Only problem is "multi-user" issues.  Two users are selecting records at the
same time, and when they print they get each other's records as well as
their own.

ONE solution is to build the selected table local to the FE and simply join
one-to-one with the main table in the BE.  Now when a user wants to select a
record, a new record is created in the selected table for exactly the record
in the main table they are trying to select.  Then the report joins the
records in the selected table (local to the FE) with the records in the main
table in the BE to decide what records to print.

Multi-user issues disappear since each user has her own select table.

Now, can that be done with a disconnected recordset?  I don't know because
I'm not familiar with the technology.

The method I am discussing is simply a real table in the FE, a real table in
the BE, a query that joins the two for the (bound) data entry form where the
records are selected for printing, and a query that joins the two for the
report to be printed.  It all works exactly as advertised, with the
exception of the possible problem if a record is created in the temp table
and then deleted and then an attempt is made to create the same record in
the temp table a second time.

John W. Colby
www.colbyconsulting.com

-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com]On Behalf Of Charlotte
Foust
Sent: Friday, September 12, 2003 10:57 AM
To: Access Developers discussion and problem solving
Subject: RE: [AccessD] Record deleted by user


John,

Did you ever think about using a disconnected recordset for the selected
items rather than a temp table?  You could even persist the thing to a
file if you needed to save it between sessions.

Charlotte Foust

-----Original Message-----
From: John Colby [mailto:jcolby at colbyconsulting.com]
Sent: Friday, September 12, 2003 4:12 AM
To: Access Developers discussion and problem solving
Subject: RE: [AccessD] Record deleted by user


No.  AFAIK there is no solution, it's a "feature" of access.

John W. Colby
www.colbyconsulting.com

-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com]On Behalf Of Gustav Brock
Sent: Friday, September 12, 2003 4:51 AM
To: Access Developers discussion and problem solving
Subject: Re: [AccessD] Record deleted by user


Hi John

Did you find a solution to this?

/gustav


>> I am trying to implement a "selected flag" system for a particular
>> form.
I
>> create a table local to the FE with two fields:

>> SelectedID Long
>> Selected Boolean

>> I modify the form's query to do an outer join between the pk of the
original
>> table and SelectedID.
>> I add a check box to the form bound to the Selected field.

>> Whenever the user clicks the check box a record is created in the new
table,
>> the SelectedID is set to the PK of the original table and the
>> Selected
field
>> is set true.  All fine so far.  Printing works fine - filter on
>> records
with
>> a join to this table and selected = true.

>> The odd behavior comes if I delete the records in the new Selected
>> table. If I build a query that displays the original table joined to
>> the
Selected
>> table, when I delete any records in the Selected table, the fields in

>> the query from the Selected table display the words "Deleted" and I
>> can no longer enter any data in that field because I get a JET error
>> "record deleted by user".  I have to requery the query and then I can

>> again
create
>> new records.

>> This is an issue because the FORM's recordset works until I delete a
record
>> in the selected table, then the checkbox FOR THAT RECORD ceases to
>> work
for
>> no apparent reason.  The reason of course is this problem discussed
above.

_______________________________________________
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com



_______________________________________________
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com
_______________________________________________
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com





More information about the AccessD mailing list