RE: date-format in cocoon 1.8.2

2001-10-25 Thread Mark S. Kent

Christian,

I'm trying the same thing and tried to wrap the esql:get-time call with an
esql:if-null.  If that is the only command:
esql:if-null column=schedule_lunch_startnone/esql:if-null
it works just fine when the value is null, but I can't find the correct
syntax to use for the command if the value is NOT null.  Because otherwise
I want to get the time value...
esql:get-time column=schedule_lunch_start format=hh:mm aa/

I sent an email about the esql:if-null earlier today (14:29 PM CDT) and
never saw it come through the list.  Has anyone else been having trouble
seeing their replies?

Mark

-Original Message-
From: Schroeter Christian [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, October 24, 2001 8:35 AM
To: [EMAIL PROTECTED]
Subject: Re: date-format in cocoon 1.8.2


Now if the value in the db is null then i get an error-message.

Without the format - attribute i wouldnt get it.

What must i change, and how?

cu,
Christian

Am Dienstag, 23. Oktober 2001 19:01 schrieben Sie:
 Specify the format attribute using a Java SimpleDateFormat string.  For
 instance,
 esql:get-date column=... format=MMM dd, /

 -Christopher




 Please respond to [EMAIL PROTECTED]

 To:   [EMAIL PROTECTED]
 cc:

 Subject:  date-format in cocoon 1.8.2


 Hi,

 what must i do to change the format of the date i get with
 esql:get-date...

 i am using cocoon1.8.2

 cu,
 christian





 -
 Please check that your question has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faqs.html

 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]

-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




RE: date-format in cocoon 1.8.2

2001-10-25 Thread Faulkner, Perry

Hi Christian,

These comments apply to Cocoon 2, but the generated java code checks for a
null value and returns , otherwise it uses the SimpleDateFormat to convert
the date. You might look at your generated code to see if it is doing the
same thing. Maybe this was added for Cocoon 2. Anyway, if it isn't doing the
right thing, you can get hold of the stuff from 2 and put that into your
code, either add it to your esql.xsl or simply use xsp:logic in your xsp
file, within your esql:row-results to fetch the date, test for null and
format, as required, just like the Cocoon 2 code! Look at the esql.xsl and
there should be some esql samples that do this sort of thing.

HTH, regards

  Perry

-Original Message-
From: Schroeter Christian [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, 24 October 2001 23:35
To: [EMAIL PROTECTED]
Subject: Re: date-format in cocoon 1.8.2


Now if the value in the db is null then i get an error-message.

Without the format - attribute i wouldnt get it.

What must i change, and how?

cu,
Christian

Am Dienstag, 23. Oktober 2001 19:01 schrieben Sie:
 Specify the format attribute using a Java SimpleDateFormat string.  For
 instance,
 esql:get-date column=... format=MMM dd, /

 -Christopher




 Please respond to [EMAIL PROTECTED]

 To:   [EMAIL PROTECTED]
 cc:

 Subject:  date-format in cocoon 1.8.2


 Hi,

 what must i do to change the format of the date i get with
 esql:get-date...

 i am using cocoon1.8.2

 cu,
 christian





 -
 Please check that your question has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faqs.html

 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]

-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




RE: date-format in cocoon 1.8.2

2001-10-25 Thread Mark S. Kent

I was mistaken... the esql:get-date and esql:get-time do work (in C2) to
return a empty value if the date or time is null.  I found that my error I
was getting was because the column name I was referencing was not in my ESQL
query (DOH!).  Sorry about that.

Mark

-Original Message-
From: Faulkner, Perry [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, October 24, 2001 4:55 PM
To: '[EMAIL PROTECTED]'
Subject: RE: date-format in cocoon 1.8.2


Hi Christian,

These comments apply to Cocoon 2, but the generated java code checks for a
null value and returns , otherwise it uses the SimpleDateFormat to convert
the date. You might look at your generated code to see if it is doing the
same thing. Maybe this was added for Cocoon 2. Anyway, if it isn't doing the
right thing, you can get hold of the stuff from 2 and put that into your
code, either add it to your esql.xsl or simply use xsp:logic in your xsp
file, within your esql:row-results to fetch the date, test for null and
format, as required, just like the Cocoon 2 code! Look at the esql.xsl and
there should be some esql samples that do this sort of thing.

HTH, regards

  Perry

-Original Message-
From: Schroeter Christian [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, 24 October 2001 23:35
To: [EMAIL PROTECTED]
Subject: Re: date-format in cocoon 1.8.2


Now if the value in the db is null then i get an error-message.

Without the format - attribute i wouldnt get it.

What must i change, and how?

cu,
Christian

Am Dienstag, 23. Oktober 2001 19:01 schrieben Sie:
 Specify the format attribute using a Java SimpleDateFormat string.  For
 instance,
 esql:get-date column=... format=MMM dd, /

 -Christopher




 Please respond to [EMAIL PROTECTED]

 To:   [EMAIL PROTECTED]
 cc:

 Subject:  date-format in cocoon 1.8.2


 Hi,

 what must i do to change the format of the date i get with
 esql:get-date...

 i am using cocoon1.8.2

 cu,
 christian





 -
 Please check that your question has not already been answered in the
 FAQ before posting. http://xml.apache.org/cocoon/faqs.html

 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]

-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




date-format in cocoon 1.8.2

2001-10-23 Thread Schroeter Christian

Hi,

what must i do to change the format of the date i get with esql:get-date...

i am using cocoon1.8.2

cu,
christian

-
Please check that your question has not already been answered in the
FAQ before posting. http://xml.apache.org/cocoon/faqs.html

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]