From: Rildo P. <rpr...@ac...> - 1999-12-06 16:32:43
|
Hi Jim, On Mon, 6 Dec 1999, Noeth, Jim wrote: > I am currently working on the run time routines that perform move related > functions. I have run into a few situations that I would like input on. > > It appears that the decimals field of the fld_desc structure is being used > as a boolean value to indicate whether or not there are digits to the right > of the decimal point. If this field contained the number of digits to the > right of the decimal point instead and an indicator was added to the > structure as to whether or not this was a signed field, the runtime routines > could be made much more efficient, as they would not have to decode the > picture clause, except for editted fields. Your'e right, the field "decimals" refer to the number of decimals to the right (if positive), or the number of zeros to add at the right if negative, in this case as an absolute value, when the clause have "P" at the right. So it is the scaling of the field. You don't need to scan the picture to get this. > The 'all' field of the fld_desc structure (which is documented in the info > section as occurs) is used to signify that the data associated with the > field, when moved to another field will be repeated until the length of the > receiving field is satisfied. Which definition is correct, or do we need > both? The "all" means whe shall "wrap around" when reaching the last position of a literal, because it should be repeated. For instance to move "ABC" with "all = 1" to a field with size 10, will give "ABCABCABCA". The size of the first field (that must be a literal, of course) is 3. > How do we want to handle run time errors, such as moving non numeric data > into a numeric field? Well, I'm no cobol guru. There are many of them in this list, so I'll let one of them answer your question :) regards, _____ _ __ __ __ __ ___ __ Rildo Pragana /\ '__`\/\`'__\/'__`\ /'_ `\ /'__`\ /' _ `\ /'__`\ P.O. Box 721 \ \ \L\ \ \ \//\ \L\.\_/\ \L\ \/\ \L\.\_/\ \/\ \/\ \L\.\_ Camaragibe \ \ ,__/\ \_\\ \__/.\_\ \____ \ \__/.\_\ \_\ \_\ \__/.\_\ PE Brazil \ \ \/ \/_/ \/__/\/_/\/___L\ \/__/\/_/\/_/\/_/\/__/\/_/ 54792-990 \ \_\ rpr...@ac... /\____/ FPGA/uControllers * Linux * tcl/tk \/_/ +55-81-459-1776 \_/__/ http://members.xoom.com/rpragana/ |