I want to use a SQL statement in Excel VBA that contains a parameter that restricts what is data is returned from a SQL server view. I have ALL data from the view populating in Excel okay. I want to use this view for more than one extract. My SQL statement is contained within quotes ("). Is there a way to referance parameters (WHERE statement), that a user enters either in a user form (preferance) or a cell in the worksheet?
Thanks.
Start Free Trial