Can anyone help me in this?
And what exactly do you expect to get out of this?
Someone may type you a solution, but is it going to help? Your ultimate goal is obviously not to implement this in your company's HR system, but it is a class assignment in the course on SQL you are taking. A nice fine query may help you to get the assignment approved, but will you learn something? Because that is the ultimate goal for your class: become an SQL programmer that can implmenent good solutions for your employer. You don't reach that goal by asking others to write the solutions for you.
Of course, what we could do is show the solution step by step, so that you could learn from the process. But writing such a post takes a lot longer time, and people here answer questions in their free time. You shold already have a teacher who one way or another is paid to teach you.
I will however, offer one piece of education: Although there are many products that uses SQL, there are considerable differences between the exact functionality they offer, and a solution that works on one product may not work on another. Therefore when seeking help, it's instrumental to check that you are asking for help in a forum to the product you work with. The hint in your class assignment refers to the trunc() function. There is no such function in SQL Server, which is the product this forum is devoted to.
Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se
No comments:
Post a Comment