Re: 'Roll Back' new record on form

Tech-Archive recommends: Speed Up your PC by fixing your registry



hi Pedro,

pedro wrote:
I have created a form for transactions with an autonumber field to generate a transactions ID. I have received a request from users of the form to be able to roll back a new record (in the case of data entry error) so that the transaction ID does not commit to the database. They do not want to delete the record as this would generate 'gaps' in the transactions ID sequence eg 1, 2, 3, 5 and so on.
This is not possible with an AutoIncrement field due to its nature as it only guarantees a value greater than the last one.

You need to evalutate your ID before saving the recordset:

Nz(DMax("TransactionID", "yourTable"), 0) + 1


mfG
--> stefan <--
.



Relevant Pages

  • Re: Juju
    ... there are two types of transactions: FireWire transactions which consists of a ... are a higer level sequence layered on top of FireWire transactions. ... One SBP-2 transaction is one SCSI task's request and completion ... (if everything goes well and if we don't have dynamically appended ORB ...
    (Linux-Kernel)
  • Database Transactions
    ... ActiveRecord's standard procedure for transactions is to send a block, ... and throw an exception to roll it back ( ... transactions, commit them, or roll them back from within ...
    (comp.lang.ruby)
  • Re: Database Transactions
    ... and throw an exception to roll it back ( ... >> transactions, commit them, or roll them back from within ...
    (comp.lang.ruby)
  • Re: How do I use XmlReader on an XmlDocument passed as a parameter
    ... transactions, each with two co-borrowers and associated residences. ... when I really want two for each request. ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: USB transfer not working after 6 incomplete IN transactions
    ... But when I submit a write request from my application, ... If the OUT transactions are completed successfully, ... Now I saw the error code in the URB, ... But when I submit the URB to reset the pipe, I get the USBD error code ...
    (microsoft.public.development.device.drivers)