Home > Contents > Index >
Template Tags TOC | Alpha TOC | Tag Family TOC | Purpose TOC | Annotated TOC | Index
ics:searchdatetonative
Converts the Java SQL-formatted date to the date format native to the search engine.
Syntax
<ics:searchdatetonative date="Java date" outputvariable="variable name" [searchengine="name"]/>Parameters
date (required)
- Java SQL date to convert.
outputvariable (required)
- Name of the variable to store the converted date string.
searchengine (optional)
- Name of the search engine to use. If
searchengine
is not specified, Content Server uses the value ofcs.searchengine
from the Content Server properties file.
Description
The
ics:searchdatetonative
tag converts the Java SQL-formatted date to the date format native to the search engine. Use in theWHAT
parameter of aics:search
tag. Dates in queries must be in a format that the search engine can parse.The input to this tag (the
date
parameter) must be a valid Java SQL date. Content Server does not detect certain errors in the date format.The Verity search engine handles most date formats, including the Java SQL format. If you are using Verity, you do not need to call
ics:searchdatetonative
.errno
The possible values of
errno
include:
Value Description -801 Cannot load search engine.Example
The following example converts the date in Java SQL format to the AltaVista date format and sets the results in the variable
AVDate
.<ics:searchdatetonative date="1998-05-22" outputvariable="AVDate" searchengine="AV"/> <ics:if condition=<%ics.GetErrno() != 0%>í> <ics:then> Report error </ics:then> <ics:else> <ics:search index="c:/articleidx" list="articledatelist" what='articledate:<%=ics.GetVar("AVDate")%>'/> </ics:else> </ics:if>
Home > Contents > Index > ![]()
FatWire JSP Tag Reference
Copyright 2005,2006,2007 by FatWire Software
All rights reserved.