Results 1 to 2 of 2

Thread: working with the SELECT...FROM stuff

  1. #1

    Thread Starter
    New Member
    Join Date
    Jul 2002
    Posts
    9

    working with the SELECT...FROM stuff

    Hi, I`m trying to open an MSHFlexGrid showing only the rows in an Adodc that I want it to. The code I`m using:
    Adodc1.RecordSource = "SELECT * FROM Estudiantes WHERE Profesor LIKE '%" & Str(numero) & "'%;"
    Adodc1.Refresh
    flexdata.Refresh
    It keeps telling me that there´s an error with the SELECT...FROM line and then of course another ont with the Adodc line.
    Could you help?:confused

  2. #2
    Fanatic Member vb_dba's Avatar
    Join Date
    Jun 2001
    Location
    Somewhere aloft between the real world and insanity
    Posts
    1,016
    Looks like you have a single quote out of place:
    VB Code:
    1. 'Change
    2. Adodc1.RecordSource = "SELECT * FROM Estudiantes WHERE Profesor LIKE '%" & Str(numero) & "'%;"
    3.  
    4. 'To
    5. Adodc1.RecordSource = "SELECT * FROM Estudiantes WHERE Profesor LIKE '%" & Str(numero) & "%';"
    Chris

    Master Of My Domain
    Got A Question? Look Here First

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