On Tue, 7 Jul 1998, Hans Pfleger wrote:
>My 2nd problem is that I'm not able to use wildcard's in the time_date field:
>
>I tried a statement like this:
>
>SELECT ACTLOG.DATE_TIME, ACTLOG.MESSAGE, ACTLOG.NODENAME,
>ACTLOG.SCHEDNAME, ACTLOG.DOMAINNAME FROM ACTLOG WHERE
>(ACTLOG.NODENAME='DONALD') and (ACTLOG.DATE_TIME like
>'1998-07-07%')
>
>because all I need is information about the node DONALD from only one day.....
>
>Any ideas?
I believe you can accomplish what you want by truncating the date
field (in this case actlog.date_time) to include only the date
information. E.g.,
SELECT substr(CHAR(actlog.date_time),1,10), actlog.message, \
actlog.nodename, actlog.schedname, actlog.dommainname \
FROM actlog \
WHERE actlog.nodename = 'DONALD' \
AND substr(CHAR(actlog.date_time),1,10) = '1998-07-07'
-- Tom
Thomas A. La Porte
DreamWorks Animation
tlaporte AT dreamworks DOT com
|