hot to pickup only sundays [message #459185] |
Thu, 03 June 2010 14:08 ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
owais_baba
Messages: 289 Registered: March 2008 Location: MUSCAT
|
Senior Member |
|
|
hi all
can any one help me to pickup only sundays from the month and
display on screen
example
date day
05-jun-2010 sunday
12-jun-2010 sunday
like!!!!!!!!!!!!!!!!!!!
thanks in advance
|
|
|
Re: hot to pickup only sundays [message #459188 is a reply to message #459185] |
Thu, 03 June 2010 14:25 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
![](/forum/images/custom_avatars/72104.gif) |
Littlefoot
Messages: 21823 Registered: June 2005 Location: Croatia, Europe
|
Senior Member Account Moderator |
|
|
This is a query that selects Sundays in the current month:SQL> l
1 select datum, dan
2 from (select to_char(trunc(sysdate, 'month') + level - 1, 'dd.mm.yyyy') datum,
3 to_char(trunc(sysdate, 'month') + level - 1, 'day') dan
4 from dual
5 connect by level <= (select to_number(to_char(last_day(sysdate), 'dd')) from dual)
6 )
7* where trim(dan) = 'sunday'
SQL> /
DATUM DAN
---------- ------------------------------------
06.06.2010 sunday
13.06.2010 sunday
20.06.2010 sunday
27.06.2010 sunday
SQL>
There might be other ways - if you are interested in them, search for a "row generator" over dates.
Once you are satisfied with the query, the further actions depend on what you need. The above query can be used as a source for a view (CREATE VIEW SUNDAYS AS SELECT ...) and then you'd base the data block on that view and simply EXECUTE_QUERY. Or, you might base block on the FROM clause. Or ... who knows? Perhaps the view-based solution promises the simplest Forms steps.
|
|
|
Re: hot to pickup only sundays [message #459189 is a reply to message #459188] |
Thu, 03 June 2010 14:38 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) ![Go to next message Go to next message](/forum/theme/orafaq/images/down.png) |
owais_baba
Messages: 289 Registered: March 2008 Location: MUSCAT
|
Senior Member |
|
|
thank you very much that's enough for me
thanks again
one more thing have ever scan image by using directly from scanner in windows xp enviroment if yes pls help me i have developed already form but under winxp enviroment not working
despite installed global 360
thanks in advance
|
|
|
Re: hot to pickup only sundays [message #459194 is a reply to message #459189] |
Thu, 03 June 2010 15:26 ![Go to previous message Go to previous message](/forum/theme/orafaq/images/up.png) |
joy_division
Messages: 4963 Registered: February 2005 Location: East Coast USA
|
Senior Member |
|
|
owais_baba wrote on Thu, 03 June 2010 15:38
one more thing have ever scan image by using directly from scanner in windows xp enviroment if yes pls help me i have developed already form but under winxp enviroment not working
despite installed global 360
What does this have to do with Oracle? In any event it is a separate subject.
|
|
|