Focal Point
[CLOSED] Updating Table without primary key

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/2927039016

October 11, 2011, 03:26 AM
Swap
[CLOSED] Updating Table without primary key
Hi,

Is there any way we can perform insert/update/delete operations on a database table using maintain?

I tried it using maintain for a table without primary key but i get following error

"(FOC03730) :Non-NEXT access on non-keyed segment: is/are not supported in
Maintain. "

This message has been edited. Last edited by: Kerry,


Webfocus 7.7.03
Windows XP
Excel, PDF, HTML, APDF, AHTML, Maintain
October 11, 2011, 09:01 AM
Maintain Wizard
Maintain does require a key to perform the NEXT, MATCH, Update, Include, Delete and Revise commands. We rely on them so we know where in the database to put / retrieve the record.

The only way to get around this, would be to use a flat file. If you do that then you CAN do a TYPE ON DDNAME to write data to a database / file. You could also use a Master File to retrieve the information from that flat file, but even then, the Master File must have a KEYS statement.

Mark Derwin
October 11, 2011, 04:39 PM
Waz
I would have thought that you could do this in MODIFY.


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.07OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!

October 12, 2011, 11:54 AM
Alan B
Modify will support an INCLUDE for non-keyed tables, but not UPDATE or DELETE.

Logically, how does MODIFY know which instance needs to be UPDATEd or DELETEd without knowing which record to be on. The key defines that.


Alan.
WF 7.705/8.007
October 12, 2011, 05:03 PM
Waz
BY NEXTing throught the records.


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.07OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!

October 13, 2011, 07:18 AM
Swap
I checked with IBI.
They also say that it is not possible now and there is no plan to introduce such feature in the future also Smiler


Webfocus 7.7.03
Windows XP
Excel, PDF, HTML, APDF, AHTML, Maintain