+ Reply to Thread
Results 1 to 2 of 2

Thread: ERROR: "Query Input must contain atleast one table or query"

  1. #1
    Registered User
    Join Date
    12-15-2010
    Location
    Greenville, South Carolina
    MS-Off Ver
    Excel 2007
    Posts
    55

    ERROR: "Query Input must contain atleast one table or query"

    Hello,
    I am very new to the SQL word and am trying to find out what is wrong with this code. The subquery works on its own but when i put it within this insert query it does not seem to work. Any suggestions?

    INSERT INTO t_Audit ( EditDate, [User], SourceTable, FirstName, LastName, ID, DOB )
    VALUES (now(), 'Test2', 'Test3',
    ( 
    Select t_Dustin.FirstName 
    From t_Dustin 
    Where (( t_Dustin.FirstName like "Dustin"))
    ),
    'Test5', '1156', '11/8/1986')
    Thanks

  2. #2
    Forum Guru davegugg's Avatar
    Join Date
    12-18-2008
    Location
    WI, US
    MS-Off Ver
    2007
    Posts
    1,879

    Re: ERROR: "Query Input must contain atleast one table or query"

    What is the error?
    I think you may have to surround date values with pound signs (#yourdate#).
    Is your code running too slowly?
    Does your workbook or database have a bunch of duplicate pieces of data?
    Have a look at this article to learn the best ways to set up your projects.
    It will save both time and effort in the long run!


    Dave

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.2.0