From stanley@skyking.oce.orst.edu Sat Dec 4 11:13:40 PST 1993 Article: 4869 of comp.databases.ingres Path: agate!howland.reston.ans.net!cs.utexas.edu!swrinde!sgiblab!cs.uoregon.edu!news.uoregon.edu!gaia.ucs.orst.edu!skyking.oce.orst.edu!stanley From: stanley@skyking.oce.orst.edu (John Stanley) Newsgroups: comp.databases.ingres Subject: Re: EQUEL/University Ingres/SunOS 4.1.x? Date: 24 Nov 1993 08:22:42 GMT Organization: Coastal Imaging Lab, Oregon State University Lines: 66 Distribution: comp Message-ID: <2cv5ki$o9i@gaia.ucs.orst.edu> References: <1993Nov23.211859.19972@sics.se> NNTP-Posting-Host: skyking.oce.orst.edu In article <1993Nov23.211859.19972@sics.se>, Hakan Soderstrom wrote: >In both cases the interactive monitor seems to work fine, but I can't >get any EQUEL application to run. The IIingres call results in the >following output on the terminal: > > KSORT SYSERR: pb_write: proc 12 > > SYSERR: pb_read: read error (4096) There is a problem in the passing of data from the equel library to the engine. Look in the file ctlmod/pipes.h. Something is overwriting the pointer at the very end of the structure. I added a 64 character array following the data and before the pointer and things work just fine. I never found the right solution, but this one works for me. >-- Anybody willing to share the successful road to running EQUEL in a >configuration similar to this? No. A second problem you might find is in the error reporting. The code that is supposed to locate the error files that list the pseudo-english translation of the numbers doesn't. In libq, IIp_err.c, I made the following, probably non-portable, fix: char * IIerrfilen(num, buf) int num; char *buf; { register char *cp; char ver[12]; extern char *IIconcatv(); #ifdef original_way IIconcatv(ver, VERSION, 0); /* now insert the "_X" */ cp = &ver[IIlength(ver)]; *cp++ = '_'; *cp = '\0'; IIconcatv(ver, ver, IIitos(num), 0); return (IIconcatv(buf, IIPathname, "/files/error", ver, 0)); #else /* john's way */ sprintf(buf, "%s/files/error%s_%d",IIPathname, VERSION, num); return(buf); #endif } Now, problems I have not yet resolved: The equel processor gives bogus code for some cases, or else is very non-intuitive about the One Correct Grammer. I had to create my own IIwrite calls to get it to accept a range statement using a character variable string. The insertion of floats has a problem with some of the low significance bits being modified. If you are relying on duplicate tuples being rejected, this is enough difference to allow both to remain in the table. This problem does not exist when loading a row from a binary file. Serendipitously, loading from the binary file is faster, so I write all the data where this is a problem to a binary file and make one "copy from" load all of it. Article 5335 of comp.databases.ingres: Path: agate!howland.reston.ans.net!cs.utexas.edu!swrinde!sgiblab!cs.uoregon.edu!news.uoregon.edu!gaia.ucs.orst.edu!skyking.oce.orst.edu!stanley From: stanley@skyking.oce.orst.edu (John Stanley) Newsgroups: comp.databases.ingres Subject: Re: Equel for University Ingres Date: 12 Jan 1994 21:27:07 GMT Organization: Coastal Imaging Lab, Oregon State University Lines: 58 Message-ID: <2h1pvc$9v0@gaia.ucs.orst.edu> References: <2gv5b1$jvv@archive.ny.jpmorgan.com> NNTP-Posting-Host: skyking.oce.orst.edu In article <2gv5b1$jvv@archive.ny.jpmorgan.com>, Michael DeAddio,EQDERIV wrote: >I'm not sure how much bandwidth is used on this newsgroup for the >freeware version of Ingres from Berkeley, but if anyone can help me out >with the following problem I would be most grateful! >KSORT SYSERR: pb_write: proc 758170128 >SYSERR: pb_read: read error (0) >It seems that the process number in the pb_t struct is much too large. Go into ctlmod and edit pipes.h. Notice the totally erronious comment about sparc structure alignment. The sparc version has a problem somewhere based on this error. It isn't just the definition of PB_DBSIZE, since I have tried putting the correct number there and it doesn't help. The problem is the pointer at the end of the structure is being overwritten. Add a 64 character array right before the definition of that pointer and it will magically start to work. I.e., make it look like: char pb_data[PB_DBSIZE]; /* the data area */ char stuffing[64]; /* testing -- protection for pointer */ char *pb_xptr; /* the data pointer (not written) */ >Any help or ideas would be GREATLY appreciated!!! You will also want to edit libq/IIp_err.c to replace the broken error file name generating routine. The entire section in IIerrfilen that looks like this: Iconcatv(ver, VERSION, 0); /* now insert the "_X" */ cp = &ver[IIlength(ver)]; *cp++ = '_'; *cp = '\0'; IIconcatv(ver, ver, IIitos(num), 0); return (IIconcatv(buf, IIPathname, "/files/error", ver, 0)); can be replaced with: sprintf(buf, "%s/files/error%s_%d",IIPathname, VERSION, num); return(buf); The former fails, the latter works. You might ALSO want to check to see if the f4 floating point numbers you insert into the database actually get correctly. The last few bits of mine are mangled. They are not mangled when read from a binary file. I haven't been able to track this one down yet. I work around it by either 1) realizing that this error is smaller than the uncertainty of my measurements and can be ignored, or 2) writing the binary data to a file and "copy" it into the database.