Re: COBOL/DB2 Date edit question





--
"I used to write COBOL...now I can do anything."
"LX-i" <lxi0007@xxxxxxxxxxxx> wrote in message
news:9NydnexmCdlzDSLbnZ2dnUVZ_rGrnZ2d@xxxxxxxxxxxxxx
Graham Hobbs wrote:

My problem is to find the easiest/clearest way to edit these three
data types before update occurs. I suspect three ways are available:

1) my 'neat?' EXEC SQL.'s.
2) inline code like 'if month < 00 or >12 then error, etc'.
3) exec cics link 'editdate' with suitable commarea (and othe pgms for
TIME and TIMESTAMP) and test a return code. (your library routine)

I can vouch for option 2 being very, very efficient. We had a copybook
that did date manipulation and validation. It was 3,000+ lines, and I was
just sure that it could be made much, much more efficient.

Well, when we had some analysis done on our source code, the results came
out with the paragraphs sorted from longest run time to shortest run time.
For every program, the date/time routine's paragraphs filled the bottom of
each list!

I had been working on a "convert" paragraph to convert time zones, using
the database. After we got those results, I abandoned that. :)

I think that's a pity, Daniel. If the date validation had been revised, and
stored as a db stored procedure you may have found very different results
from your analysis. All of the date validation would have "disappeared" for
a start... :-))

Never mind. You found a good solution; that's what really matters :-)

Pete.
--
"I used to write COBOL...now I can do anything."


.



Relevant Pages

  • RE: validation strategy?
    ... Are you sure you clicked on the right tab for the source code? ... "Phillip Williams" wrote: ... missing fields and error text in a validation summary. ... Now I'm thinking it would be cool if I could perform the tests server side, ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: How important is validation?
    ... >to pass even syntax validation? ... Cluelessness. ... validation was also very much the exception rather than ... "I have reviewed your site and the source code. ...
    (comp.infosystems.www.authoring.html)
  • RE: Validating stored proc return columns SSIS
    ... table in a stored procedure to an SSIS OLEDB source; it fails the validation ... truncating it and loading it in the stored procedure. ... uses a temp table, -even if the resultset is not selected from a temp table-, ... This seems to me to be a bug; I can't see any reason that validation should ...
    (microsoft.public.sqlserver.dts)
  • Re: general security ?
    ... understand how to filter this form with option buttons, ... through the source code or through the url but I don't really ... negative price, in which case the cost to your e-commerce store ... so filtering and escaping data is client side validation what is ...
    (comp.lang.php)
  • Re: Value in output parameter not accessable
    ... I'll confine myself to cleaning up the stored procedure for this ... If you pass the validation successfully, ... >Public Shared Function PostItem(ByVal Subject As String, ... the output parameter ) is never set to the identity ...
    (microsoft.public.dotnet.framework.adonet)

Quantcast