Translating with DrWatson… this can take a few seconds the first time.
This is a genuine, complex translation. DrWatson protects commands, error codes, and log output while naturally translating the surrounding text. It’s translated once and saved.
In a thread on checking integer values, Everett Mills posted a 4GL snippet (LET char_time = in_time USING with four ampersands) and Obnoxio The Clown noted it fails for values above 9999. Ian Michael Gumby suggested formatting an hhmm string and converting it to an integer. The original poster said he combined both ideas.
Auto-generated by Claude from the posts below — may be imperfect; read the full thread.
> -----Original Message-----
> From: Obnoxio The Clown [mailto:obnoxio@serendipita.com]
> Sent: Tuesday, September 16, 2008 2:02 PM
> To: Everett Mills
> Cc: informix-list
> Subject: Re: Integer checks
>
> Everett Mills wrote:
Snip
> >
> > LET char_time = in_time USING "&&&&"
> >
>
> Will crash if time is greater than 9999 ;o)
>
> --
> Cheers,
> Obnoxio the Clown
>
> http://obotheclown.blogspot.com
>
I noticed that right after I hit send.
--EEM
>
>
>
On Sep 16, 2:08 pm, "Everett Mills" <eemi...@nationalbeef.com> wrote:
> > -----Original Message-----
> > From: Obnoxio The Clown [mailto:obno...@serendipita.com]
> > Sent: Tuesday, September 16, 2008 2:02 PM
> > To: Everett Mills
> > Cc: informix-list
> > Subject: Re: Integer checks
>
> > Everett Mills wrote:
>
> Snip
>
>
>
> > > LET char_time = in_time USING "&&&&"
>
> > Will crash if time is greater than 9999 ;o)
>
> > --
> > Cheers,
> > Obnoxio the Clown
>
> >http://obotheclown.blogspot.com
>
> I noticed that right after I hit send.
>
> --EEM
>
>
I think the problem is reversed. I think he wants to store the value
as an integer and use 4GL as a way to get an appropriate value in.
So if your form has a date time (hour to minute) field, and then you
take the value, format it in to an "hhmm" string and then convert to
an integer,
you should be ok. (Assuming that the conversion handles the leading
zero.)
Now wasn't this question asked and answered earlier?
Ian Michael Gumby wrote:
> I think the problem is reversed. I think he wants to store the value
> as an integer and use 4GL as a way to get an appropriate value in.
>
Reading is fundamental.
--
Cheers,
Obnoxio the Clown
http://obotheclown.blogspot.com
Thanks all, i combined both ideas in the end, much appreciated.
>
>> -----Original Message-----
>> From: Obnoxio The Clown [mailto:obnoxio@serendipita.com]
>> Sent: Tuesday, September 16, 2008 2:02 PM
>> To: Everett Mills
>> Cc: informix-list
>> Subject: Re: Integer checks
>>
>> Everett Mills wrote:
>
> Snip
>
>>> LET char_time = in_time USING "&&&&"
>>>
>> Will crash if time is greater than 9999 ;o)
>>
>> --
>> Cheers,
>> Obnoxio the Clown
>>
>> http://obotheclown.blogspot.com
>>
>
> I noticed that right after I hit send.
>
> --EEM
>>
>>
>
Your privacy choices
We use strictly necessary cookies to make this site work. With your
consent we’d also use optional cookies for analytics and marketing. You can accept all,
reject all, or choose. Read our Cookie Policy.