Virtusa interview question

Fibonacci series in java and SQL query