Results 1 to 5 of 5

Thread: Compare design time variable to run time variable

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Feb 2003
    Posts
    219

    Question Compare design time variable to run time variable

    How do I use a Data Adapter configuration wizard to generate a query that will compare the variable in the query to my run time variable?

    This is what I have but it doesn't work. The wizard kept giving me errors:

    SELECT
    Personal.*,
    Education.*,
    Response.*
    FROM
    Education,
    Personal,
    Response
    WHERE
    Personal.SSN = @intSSN
    Response.SSN = @intSSN
    Please help if anyone knows.

    Thanks!

    Chong

  2. #2
    Fanatic Member VBCrazyCoder's Avatar
    Join Date
    Apr 2003
    Posts
    681
    I usually put the query in a stored procedure, and then pass in my runtime values as parameters.

  3. #3
    Your Ad Here! Edneeis's Avatar
    Join Date
    Feb 2000
    Location
    Moreno Valley, CA (SoCal)
    Posts
    7,339
    Not all datasources support parameters, or some support them differently. What datasource are you using? Access? SQL?

  4. #4
    PowerPoster hellswraith's Avatar
    Join Date
    Jul 2002
    Location
    Washington St.
    Posts
    2,464
    It looks like your query is wrong too. Should it be a join statement?

  5. #5

    Thread Starter
    Addicted Member
    Join Date
    Feb 2003
    Posts
    219

    Exclamation Compare design time variable to run time variable

    Thanks for helping me out. I am using MS Access mdb. The codes was just a sample I copied from the configuration wizard. It doesn't matter if I have the join or not. I was trying to do it in different ways but obviously it doesn't work.

    How do I use store procedure?

    Thanks!

    Chong

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width