tomcat-taglibs-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nazir Wasim Ahmed" <>
Subject Parameter passing
Date Wed, 20 Aug 2003 07:00:01 GMT

i have a tag which has the following signature.
<DateTag:DateUtil mode="changeformat" actualFormat="dd-mm-yyyy"
reqFormat="dd-mon-yyyy" date="20-05-2003" />
i want to break this up so that i can pass the parameter seperately like
<param="mode" value="changeformat" >

Can anyone help me out on this pls


-----Original Message-----
From: Jason Lea []
Sent: Wednesday, August 20, 2003 9:14 AM
To: Tag Libraries Users List
Subject: Re: Fw: [OT]Re: <sql:param> null weirdness BACK ON TOPIC


Perhaps you could try this:

     INSERT INTO myTable VALUES ( ? )
     <fmt:parseDate value="${param.time}" var="myTime" type="both" />
     <sql:dateParam value="${myTime}" />

You might have to give parseDate a pattern or dateStyle/timeStyle to
parse correctly.  Apparently the sql:dateParam is supposed to be used
for DATE, TIME or TIMESTAMP columns.

fmt:parseDate will check for null and empty values and remove myTime
from scope.  I hope that means myTime will be null when param.time is an
empty string.

Jason Lea

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message