title: Exec stored procedure with OpenQuery & parameter
body: <p>Stored procedure as below. It is using a linked server to Oracle.</p>
  
  <pre><code>ALTER PROCEDURE [dbo].[SVOPS_ZsmartPaymentView]
      (@param01 VARCHAR(255))
  AS
  BEGIN
      SELECT * 
      FROM OPENQUERY(ZSMART_PROD, 'SELECT BANK_SN FROM CC.V_PAYMENT WHERE BANK_SN=''@param01''')
  END
  </code></pre>
  
  <p>If I call the stored procedure with parameters as shown below, the result is empty:</p>
  
  <pre><code>EXEC [dbo].[SVOPS_ZsmartPaymentView] @param01 = 'T131612073600'
  </code></pre>
  
  <p>But if I run the statement directly like below, there is result.</p>
  
  <pre><code>SELECT * 
  FROM openquery(ZSMART_PROD, 'SELECT * FROM CC.V_PAYMENT WHERE BANK_SN=''T131612073600''')
  </code></pre>
  
  <p>Any idea why it returned empty result if executed using the stored procedure?</p>