Login ProductsSalesSupportDownloadsAbout |
Home » Technical Support » ElevateDB Technical Support » Support Forums » ElevateDB General » View Thread |
Messages 1 to 5 of 5 total |
Problem with trigger |
Wed, Apr 28 2010 4:58 AM | Permanent Link |
Francisco Fernandez NewTRON Informatica | Hi Tim.
Delphi 2007 and EDB 2.03 B11 I have a table with an After Insert trigger that updates several tables of database. Before 2.03 versions it works fine but in 2.03 working in net fileshared with several clients I'm getting this error: Elevate error #1000 An Error ocurred with the cursor TempCursor at line 57 and column 19 (The cursor has no active row) This is the part of trigger that generate error: START TRANSACTION ON TABLES Articulos; BEGIN PREPARE stmt FROM 'SELECT * FROM Articulos WHERE CODIGO COLLATE ESP=?'; OPEN TempCursor USING NEWROW.ARTICULO; FETCH FROM TempCursor (DESCRIPCIO) INTO Descripcio; FETCH FROM TempCursor (CONTROLAU) INTO ControlaU; IF ROWCOUNT(TempCursor)<>0 THEN FETCH FROM TempCursor (TUVENTA) INTO TempCantidad; UPDATE TempCursor SET TUVENTA=TempCantidad+(NEWROW.CANTIDAD); IF TempCantidad IS NULL THEN UPDATE TempCursor SET TUVENTA=NEWROW.CANTIDAD; ELSE UPDATE TempCursor SET TUVENTA=TempCantidad+(NEWROW.CANTIDAD); <----- Line 57 END IF; ..... continue as you can see if no active row don't execute this line, then I don't know what is happening. This error only occurs once in a while and with several clients writing at the same time in database and I could not play it in my office but I have several customers with this problem. Thank you |
Wed, Apr 28 2010 4:12 PM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. timyoung@elevatesoft.com | Francisco,
<< This error only occurs once in a while and with several clients writing at the same time in database and I could not play it in my office but I have several customers with this problem. >> What are the configurations for these customers in terms of the peer-to-peer networks that they're using ? Are there any triggers defined on the table that you're updating ? -- Tim Young Elevate Software www.elevatesoft.com |
Thu, Apr 29 2010 3:09 AM | Permanent Link |
Francisco Fernandez NewTRON Informatica | Tim.
>>What are the configurations for these customers in terms of the peer-to-peer >>networks that they're using ? Is not a network problem because they are working normally until software update and no was network changes. On the other hand I'm having this problem with several customers from my software update. >>Are there any triggers defined on the table that you're updating ? Sure, this errors occurs when insert record in a table with the "After insert" trigger that I said to you before. Francisco J. Fernandez NewTRON Informática |
Thu, Apr 29 2010 5:13 AM | Permanent Link |
Francisco Fernandez NewTRON Informatica | I found it!
I think it is an error that occurs from B11 version. By chance, changing a trigger, it raise the same error I said to you and it raise always. I tried it in earlier versions and I can see that the same database with the same triggers works fine in B10. I send you by mail a copy of database to evaluate it. Thank you. Francisco J. Fernandez NewTRON Informatica |
Thu, Apr 29 2010 10:51 AM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. timyoung@elevatesoft.com | Francisco,
<< Sure, this errors occurs when insert record in a table with the "After insert" trigger that I said to you before. >> No, what I meant was - are there any triggers defined on the table that you're updating *in the After Insert trigger* ? IOW, are there any triggers defined on the Articulos table ? -- Tim Young Elevate Software www.elevatesoft.com |
This web page was last updated on Tuesday, April 30, 2024 at 03:55 PM | Privacy PolicySite Map © 2024 Elevate Software, Inc. All Rights Reserved Questions or comments ? E-mail us at info@elevatesoft.com |