Displaying Dates (Banded Report Writer)
At 07 JAN 2012 04:07:30PM Donald Bakke wrote:
I must be doing something wrong because I have a date field on my report but it always displays the current date rather than the date value in the database record. I've tried playing with the formatting as well as having no formatting, it makes no difference. Any ideas?
At 07 JAN 2012 08:36PM Jonathan Bird wrote:
I thought I was getting the same behaviour too, until I realised the date field was actually a datetime field, and by default, the BRW put today's date in front of the time. Only making the field longer revealed this, and then I adjusted the format. Maybe you hve something similar.
At 07 JAN 2012 08:49PM Donald Bakke wrote:
The database field itself is definitely a date field.
At 07 JAN 2012 10:01PM Donald Bakke wrote:
Okay, I change the Database Field to another date column in the table and it works. I change it back and it doesn't work. I then create a symbolic column pointing to the original date column:
@ANS = {DATE}…and the symbolic column works in the report. This doesn't make any sense to me.
At 08 JAN 2012 12:26PM bshumsky wrote:
Okay, I change the Database Field to another date column in the table and it works. I change it back and it doesn't work. I then create a symbolic column pointing to the original date column:
@ANS = {DATE}…and the symbolic column works in the report. This doesn't make any sense to me.
Hi, Don. If you look at the date field that _does_ work, and the one that _doesn't_ work, what are the differences between them? Different conversion codes? Different data types? Different odd punctuation in the field names (ie, the working one is MYDATE and the bad one is SOME_OTHER.DATE)? There must be _something_ about the "bad" one that's confusing the BRW - let's see if we can tease out what that something is…
- Bryan Shumsky
At 08 JAN 2012 03:26PM Donald Bakke wrote:
Hi, Don. If you look at the date field that _does_ work, and the one that _doesn't_ work, what are the differences between them? Different conversion codes? Different data types? Different odd punctuation in the field names (ie, the working one is MYDATE and the bad one is SOME_OTHER.DATE)? There must be _something_ about the "bad" one that's confusing the BRW - let's see if we can tease out what that something is…
Hi Bryan,
It turns out that the problem is the name of the field itself. If you look at the symbolic logic I included in a previous post you'll note that the name of the F-type field was DATE. I didn't think that this would conflict with the BRW's built-in function of the same name. I tried surrounding my database field name with square braces hoping that might force a dataset evaluation but no joy. At least we understand the nature of the problem and how to work around it.
Thanks,