PxPlus User Forum

Main Board => Discussions => Language => Topic started by: Michael Greer on March 18, 2026, 01:07:20 PM

Title: error 11 on write with no DOM - embedded IO
Post by: Michael Greer on March 18, 2026, 01:07:20 PM
In an embedded IO routine (post_write) I am getting an error 11 on a write to a file with no DOM specified.  If  I write it in console mode and I have no issue. This is an mkeyed file like this:  keyed "test",[1:1:2]+[2:1:10]+[3:1:6],0,-300.  Is some strange IO option in play during embedded IO?  I'm not seeing any such setting in the io program itself.
Title: Re: error 11 on write with no DOM - embedded IO
Post by: James Zukowski on March 18, 2026, 01:11:39 PM
If you ESCAPE before the WRITE, you can step through it. The embedded IO routing will be steppable and you can find the offending situation that way.
Title: Re: error 11 on write with no DOM - embedded IO
Post by: Michael Greer on March 18, 2026, 02:09:11 PM
James, I did that. I am taking an error branch (seterr in effect) due to an error 11.  As I say, it is a write with no DOM or ERR on an mkeyed file.
Title: Re: error 11 on write with no DOM - embedded IO
Post by: Jerry Fletcher on March 18, 2026, 04:19:17 PM
Hi Michael,

This might be a long shot but whenever i get an odd error 11's (like they should not be happening) then it seems like my file gets corrupted.
    for example writing without a dom and getting an error 11
    or getting they key(file) then trying to read with same key and getting an error 11.
if i do a keyed load on file it usually fixes it.

Jerry
Title: Re: error 11 on write with no DOM - embedded IO
Post by: Michael Greer on March 19, 2026, 08:57:09 AM
This is a new file, so I actually just erased it and re-created it.  I can program around this by trying a remove first, but I don't think I should have to do that.
Title: Re: error 11 on write with no DOM - embedded IO
Post by: James Zukowski on March 19, 2026, 09:09:54 AM
When stepping through, have you tried disabling the seterr in the process?
Do you have any system parameters set that might have some effect on this ('WL', 'WD', 'VW', etc.)?
Title: Re: error 11 on write with no DOM - embedded IO
Post by: Mike King on March 19, 2026, 10:26:10 AM
Is it possible you have multiple key fields and that the DOM error is reporting that an error due to a non-unique alternate key?
Title: Re: error 11 on write with no DOM - embedded IO
Post by: Michael Greer on March 20, 2026, 08:58:05 AM
Ok. never mind.  I was misinterpreting what I was seeing.  Thanks all for the suggestions.
Title: Re: error 11 on write with no DOM - embedded IO
Post by: James Zukowski on March 20, 2026, 09:38:58 AM
Any insights? So we don't wander in the dark...