> Additional information: Incorrect syntax near 'OrdersSelectByPK' but when I select this procedure in the VS Server Explorer - I can execute this stored procedure without problem.
> How can I find the problem?
Look in your business object's properties for DefaultCommandType - I'd guess this is set to CommandType.Text (or not specified) and changing it to CommandType.StoredProcedure would fix your problem. The jump start mentions this on Step 3, "Add code to the constructor that sets the DefaultCommandType property to CommandType.StoredProcedure..."
You get the exact same error if you run something like this in Query Analyzer:
declare @dummy int;
OrderSelect
The dummy line is just to stop QA from being clever.
I've got caught by this sort of thing myself, and seen several posts on UT around this topic recently, eg Thread #
1235787