This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
1) I don't know why you're getting the error. I've casually counted your question marks and it seems there are 16 of them, so it is indeed quite strange. However, I'm successfully using the following SQL query with bind variables:
As you can see, I'm binding the values in the USING clause, but nowhere else (I'd say this is the "natural" way of doing it, but I don't see a reason why binding the values elsewhere should not work).
If this approach does not hep or you want to untangle your original problem anyway, please post the stack trace so we can see on which line the error occurs. Make sure the line numbers match the code you've posted.