#1
  1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Mar 2003
    Posts
    23
    Rep Power
    0

    Can't get SELECT FROM INTO to work


    Neither works for me in VB6. Does VB accept compund statements?

    conn.Execute ("Create Table NewTable SELECT * FROM GameInfo")
    [syntax error in Create Table]

    conn.Execute "SELECT * FROM GameInfo INTO NewTable"
    [syntax error in from clause]
  2. #2
  3. /(bb|[^b]{2})/

    Join Date
    Nov 2001
    Location
    Somewhere in the great unknown
    Posts
    5,163
    Rep Power
    792
    It has to be valid sql syntax.
    The database you are using determines what is valid and what is not.

    Not knowing what kind of database you are working with all I can do is suggest another style of statement instead of what you have done.

    i.e.
    create table NewTable as (select * from GameInfo)
  4. #3
  5. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Mar 2003
    Posts
    23
    Rep Power
    0
    Sorry all, I am using VB6sp5 MS access/jet 4.0, windows XP home
  6. #4
  7. /(bb|[^b]{2})/

    Join Date
    Nov 2001
    Location
    Somewhere in the great unknown
    Posts
    5,163
    Rep Power
    792
    as long as you can perform the query in your access client, then you can do the same thing with vb.

IMN logo majestic logo threadwatch logo seochat tools logo