parameters missing in SQL code

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • rahel xalid

    parameters missing in SQL code

    i have this sql code i want to run it in vb6 but it is say too few parameters.expe cted 1. how can i run it?
    thanks for hlping

    Code:
    SELECT Table1.s_id, Table1.s_fullname, Table1.subject, Table1.date, Table1.time, Table1.stage
    FROM Table1
    WHERE (((Table1.s_id)=[input s_id]));
    Last edited by Dormilich; Nov 11 '10, 07:06 AM.
  • code green
    Recognized Expert Top Contributor
    • Mar 2007
    • 1726

    #2
    What!! "says too few parameters.expe cted"?
    This looks like an Access error to me. It means you have got a field name wrong (usually).

    Comment

    • Oralloy
      Recognized Expert Contributor
      • Jun 2010
      • 988

      #3
      @rahel xalid,

      It looks like your problem is with the code element [input s_id] .

      The query is asking for a parameter there, so you have to provide it as part of your query.

      You can either use a prepared query and add parameters to it, or you can just replace the element with the appropriate value using string surgery.

      Good Luck!

      Comment

      Working...