Re: [Arsperl-users] Querying by dates?
Brought to you by:
jeffmurphy
|
From: Richard H. <rl...@ls...> - 2005-10-13 18:30:44
|
Mitch,
The short answer is: Remedy only understands one of your date
formats! I usually use dates like "20 September 2005" but you can just
embed the $TIMESTAMP$ "macro" if you want.
BTW, try using Perl's qq{} operator which allows you to create
double quoted strings without having to bother with escaping any
intervening double quotes.
Good Luck!
Richard.
Lintner, Mitchell wrote:
>
> I am having trouble getting a ARSPERL script to query with dates. Can
> you suggest what I am doing wrong?
>
> $query = "('Approver CUID' = \"$approver_cuid\" AND 'Start Time' <=
> \"$time\" AND 'End Time' >= \"$time\")";
> %alternates=doquery($ctrl,$schema,$query);
>
> If I give $time a value of "10/13/05 10:42:03", the script does not
> find anything. If I set $time equal to 1129220941
> It finds the necessary records.
>
> I want to call this script from a Run Process and pass it the
> $TIMESTAMP$ value.
>
|