Solved

Missing Operator

Posted on 2004-10-08
1
216 Views
Last Modified: 2009-07-29
want to to a insert

ssql = "INSERT INTO tblhotel (hotelname) VALUES (" & Me.txthotelname & ")"

and just get a missing operator error
0
Comment
Question by:ziwez0
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 12

Accepted Solution

by:
pique_tech earned 50 total points
ID: 12257910
You have to properly delimit me!txthotelname as a string with single quotes, like so:

ssql = "INSERT INTO tblhotel (hotelname) VALUES ('" & Me.txthotelname & "')"
                                                                        ^^                                ^^
                                                                     here                             and here
0

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Query Dilema in Access 2010 3 37
Calculation in a Report 13 43
Ranking Students in Ms Access based on given Criteria 5 60
2 Global Vars, 1 List Box 4 34
I see at least one EE question a week that pertains to using temporary tables in MS Access.  But surprisingly, I was unable to find a single article devoted solely to this topic. I don’t intend to describe all of the uses of temporary tables in t…
Access developers frequently have requirements to interact with Excel (import from or output to) in their applications.  You might be able to accomplish this with the TransferSpreadsheet and OutputTo methods, but in this series of articles I will di…
Familiarize people with the process of retrieving data from SQL Server using an Access pass-thru query. Microsoft Access is a very powerful client/server development tool. One of the ways that you can retrieve data from a SQL Server is by using a pa…
In Microsoft Access, learn how to use Dlookup and other domain aggregate functions and one method of specifying a string value within a string. Specify the first argument, which is the expression to be returned: Specify the second argument, which …

751 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question