Hi Am Using Unix Ksh ...
I have a Table called date
select * from date ;
Date
01/02/2013
06/02/2013
I need the output as
Missing Date
01/02/2013
02/02/2013
03/02/2013
04/02/2013
05/02/2013
06/02/2013
Can anyone help me pls............
Hi Am Using Unix Ksh ...
I have a Table called date
select * from date ;
Date
01/02/2013
06/02/2013
I need the output as
Missing Date
01/02/2013
02/02/2013
03/02/2013
04/02/2013
05/02/2013
06/02/2013
Can anyone help me pls............
I am no dba but what i would do is dump the table into a flat file...fill in the missing date time rows using perl...load it back into the date table...and if all of this sounds like baloney feel free to ignore it...
You can use ALL_OBJECTS
to generate missing dates:
select to_char(to_date('01/02/2013','dd/mm/yyyy') - 1 + rownum, 'dd/mm/yyyy') from ALL_OBJECTS
where to_date('01/02/2013','dd/mm/yyyy') - 1 + rownum <= to_date('06/02/2013','dd/mm/yyyy');
01/02/2013
02/02/2013
03/02/2013
04/02/2013
05/02/2013
06/02/2013