alfredo phoenix wrote:Can you please help me with the java code?
If by "help" you mean "provide it all to me", the answer is no.
If you mean "I know how to do a little/some/most of it but I'm stuck in a few places", then absolutely. Post what code you have, tell us what it's doing, what it's not doing, what you think it should be doing, error messages, etc.
There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors
Ok, I didn't mean to ask you all to provide me the code.. I have written the code but I feel my prepared statement is incorrect. I just need help in proof reading the code and suggest the corrections. Following is my code. Basically in the UI, the column end_date is showing the default date of 01-JAN-3000. If an employee is turning from part time to full time, his end date of part time should show up rather than the default date. In case the database doesn't has his end date, then the start date of his full time - 1 should be his end date for the part time while the end date for full time should be the default date.
The query does the following:
Retrieves all emp_ids which are having multiple end dates as 01-JAN-3000,
Using Oracle Window function to retrieve the start date for next row in partition for particular emp id and subtract 1 day from next start date to correct end date. Update ent_emp_policy using Merge to correct ENT_EMPOL_END_DATE for that particular ENTEMPOL_ID.
Look! I laid an egg! Why does it smell like that? Tiny ad, does this smell weird to you?