Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: oracle returns null pointer and ordering date ?
<javanewbie_at_my-deja.com> wrote in message news:7vqvg4$vkt$1_at_nnrp1.deja.com...
> String str1 = "SELECT TO_CHAR(creation_date, 'YYYY-MON'), count(*)
> FROM " +
> " foreign_worker_master where creation_date is not null and " +
> " doctor_code is not null " +
> " and (creation_date > TO_DATE('"+lbFromDateStart.getText()
> +"','DD/MM/YYYY') and " +
> " creation_date < TO_DATE('"+lbFromDateStop.getText()
> +"','DD/MM/YYYY') ) " +
> " group by TO_CHAR(creation_date, 'YYYY-MON') order by
> creation_date ";
[snip]
select to_char(trunc(creation_date, 'mm'), 'YYYY-MON'), ...
...
group by trunc(creation_date, 'mm')
Received on Thu Nov 04 1999 - 19:53:14 CST
![]() |
![]() |