Incorrect syntax

Posted on 2012-08-17
Medium Priority
Last Modified: 2012-08-17
I am inserting an SQL query I found online to create a user, to a program that runs on SQL databases. The passwords have been lost to this program that is why I am trying to run the query. Here is my code and error.  I am using SQL server 2008

INSERT INTO [dbo].[OrionUsers]
(Name, AuthURI, Admin, Disabled, Visible, Interactive, Removable, Editable)
VALUES (‘epoadmin’,'auth:pwd?pwd=7LTSeirrzM8EjqttaozV4cSiPGQWi8w3',1,0,1,1,1,1)

Msg 102, Level 15, State 1, Line 3
Incorrect syntax near '‘'.
Msg 105, Level 15, State 1, Line 3
Unclosed quotation mark after the character string 'auth:pwd?pwd=7LTSeirrzM8EjqttaozV4cSiPGQWi8w3',1,0,1,1,1,1)
Question by:LIBBB
LVL 13

Accepted Solution

Ryan earned 2000 total points
ID: 38306907
It looks like your single quotes have changed.  Delete them and retype them in.  All 4 of them, though I think its just the ones on the 2nd field (AuthURI)

Author Closing Comment

ID: 38306917
Worked perfect, thanks!

Featured Post

Free recovery tool for Microsoft Active Directory

Veeam Explorer for Microsoft Active Directory provides fast and reliable object-level recovery for Active Directory from a single-pass, agentless backup or storage snapshot — without the need to restore an entire virtual machine or use third-party tools.

Question has a verified solution.

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

This shares a stored procedure to retrieve permissions for a given user on the current database or across all databases on a server.
MSSQL DB-maintenance also needs implementation of multiple activities. However, unprecedented errors can hamper the database management. In that case, deploying Stellar SQL Database Toolkit ensures fast and accurate database and backup repair as wel…
Via a live example, show how to extract information from SQL Server on Database, Connection and Server properties
Viewers will learn how the fundamental information of how to create a table.
Suggested Courses

830 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