Login ProductsSalesSupportDownloadsAbout |
Home » Technical Support » ElevateDB Technical Support » Product Manuals » ElevateDB Version 2 Manual for RAD Studio 11 (Delphi Win32) » Getting Started » Exception Handling and Errors |
begin with MyEDBTable do begin DatabaseName:='Tutorial'; TableName:='customer'; Exclusive:=True; ReadOnly:=False; try Open; except on E: Exception do begin if (E is EDatabaseError) and (E is EEDBError) then begin if (EEDBError(E).ErrorCode=EDB_ERROR_LOCK) then ShowMessage('Cannot open table '+TableName+ ', another user has the table open already') else ShowMessage('Unknown or unexpected '+ 'database engine error # '+ IntToStr(EEDBError(E).ErrorCode)); end else ShowMessage('Unknown or unexpected '+ 'error has occurred'); end; end; end; end;
Event | Description |
OnEditError | This event is triggered when an error occurs during a call to the TEDBTable, TEDBQuery , or TEDBStoredProc Edit method . The usual cause of an error is a row lock failure if the current session is using the pessimistic row locking protocol (the default). Please see the Inserting, Updating, and Deleting Rows topic for more information on using this event, and the Locking and Concurrency topic for more information on the ElevateDB row locking protocols. |
OnDeleteError | This event is triggered when an error occurs during a call to the TEDBTable, TEDBQuery , or TEDBStoredProc Delete method. The usual cause of an error is a row lock failure (a row lock is always obtained before a delete regardless of the locking protocol in use for the current session). Please see the Inserting, Updating, and Deleting Rows topic for more information on using this event, and the Locking and Concurrency topic for more information on the ElevateDB row locking protocols. |
OnPostError | This event is triggered when an error occurs during a call to the TEDBTable, TEDBQuery , or TEDBStoredProc Post method. The usual cause of an error is a constraint violation, however it can also be triggered by a row lock failure if the locking protocol for the current session is set to optimistic. Please see the Inserting, Updating, and Deleting Rows topic for more information on using this event, and the Locking and Concurrency topic for more information on the ElevateDB row locking protocols. |
This web page was last updated on Thursday, November 16, 2023 at 10:39 AM | Privacy PolicySite Map © 2024 Elevate Software, Inc. All Rights Reserved Questions or comments ? E-mail us at info@elevatesoft.com |