Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Stored proc triggers read only error
Message
From
23/07/2008 13:12:37
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
Stored proc triggers read only error
Environment versions
Visual FoxPro:
VFP 8 SP1
OS:
Windows XP SP1
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01333481
Message ID:
01333481
Views:
51
I have a SP that is supposed to update the current table. I get "Cannot update the cursor DEALERS, since it is read-only." The table is not read only. Does anyone know why I would get this read only error message from running the stored procedures?

Here are the SPs:
FUNCTION spDealersInsertTrigger()
? ISREADONLY()
REPLACE ChangeDate WITH DATE(), Change WITH "NEW"
RETURN
ENDFUNC

FUNCTION spDealersUpdateTrigger()
? ISREADONLY()
REPLACE ChangeDate WITH DATE()
RETURN
ENDFUNC

Here is the GENDBC code:
DisplayStatus([Creating database...])
CLOSE DATA ALL
CREATE DATABASE 'MYDBC.DBC'
DisplayStatus([Creating table DEALERS...])
MakeTable_DEALERS()
DisplayStatus([Finished.])

FUNCTION MakeTable_DEALERS
***** Table setup for DEALERS *****
CREATE TABLE 'DEALERS.DBF' NAME 'DEALERS' ( ;
COMPANY C(45) NOT NULL, ;
ADDR1 C(45) NOT NULL, ;
ADDR2 C(45) NOT NULL, ;
CITY C(21) NOT NULL, ;
ST C(2) NOT NULL, ;
ZIP C(10) NOT NULL, ;
CHANGE C(62) NOT NULL, ;
CHANGECODE C(1) NOT NULL, ;
CHANGEDATE D NOT NULL)

***** Change properties for DEALERS *****
CREATE TRIGGER ON 'DEALERS' FOR INSERT AS spdealersinserttrigger()
CREATE TRIGGER ON 'DEALERS' FOR UPDATE AS spdealersupdatetrigger()
ENDFUNC

FUNCTION DisplayStatus(lcMessage)
WAIT WINDOW NOWAIT lcMessage
ENDFUNC
David
Next
Reply
Map
View

Click here to load this message in the networking platform