header records on an export file
Bob Stockler
bob at trebor.iglou.com
Tue Sep 21 17:38:42 PDT 2004
On Tue, Sep 21, 2004 at 05:15:20PM -0400, Brian K. White wrote:
| Brian K. White wrote:
| >Bob Stockler wrote:
| >
| >>I _think_ the -A switch works only with EXPORT ASCII.
| >
| >word and ascii, but not the others.
|
| except I just tried adding a header like this in @once in an existing report
Thanks for the correction.
But now I think again, and _think_ @ONCE is recognized only
in input processing.
Bob (who is willing to be told ONCE more that he's off base)
| and if I put a "show @" right after the close hdr but before the end of
| @once,
| I can see the header in the file,
| then the data export overwrites the header
|
| the -a is not being honored.
|
| 5.0.13 sco unix
|
|
|
| also extremely interesting:
|
| along the way I'd made a mistake and used the alias from the main data
| export in the @once header routine
| and the data made it into the file!
|
| explanation, my export process went like this:
| these are all "then:" lines, and the menu batch file that runs this
| sets umask 0 and zeros out the file and sets -r filename
|
| ----top----
| gosub exp
| csv(1)=1
| ...
| end
| exp: export word csv=(@pm) -a
| return
| @once:
| export word tst = (@pm)
| csv(1)="test"
| csv(2)="test"
| close tst
| show "@"
| end
| ----bottom----
|
| I would have never expected those csv(1)="test" lines to have any affect.
| I can see why they wouldn't automatically fail syntax check, but at
| run-time they should cause a filepro error since at that time there is no
| lookup, export, or array named csv.
|
| since they didn't error, and since they actually took precedence over the
| normal first two fields data, it's as if @once ran just _after_ processing
| the first record. I don't think that is actually the case though, because I
| have other things not shown here that contradict that. one is I have a
| variable with a static value that I define with ",g" and fill in @once, and
| then use it in every record, and it works in the first record, so @once
| must have been processed before that.
|
| Brian K. White -- brian at aljex.com -- http://www.aljex.com/bkw/
| +++++[>+++[>+++++>+++++++<<-]<-]>>+.>.+++++.+++++++.-.[>+<---]>++.
| filePro BBx Linux SCO Prosper/FACTS AutoCAD #callahans Satriani
|
| _______________________________________________
| Filepro-list mailing list
| Filepro-list at lists.celestial.com
| http://mailman.celestial.com/mailman/listinfo/filepro-list
--
Bob Stockler - bob at trebor.iglou.com
Author: MENU EDIT II - The BEST Creator/Editor/Manager for filePro User Menus.
Fully functional (time-limited) demos available by email request (specify OS).
More information about the Filepro-list
mailing list