Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

Troubleshooting
Research
Professional Opinions
Ask a Question
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE

troubleshooting Question

How can I insert "_" into a SQL Server field in a table?

Avatar of Bill
BillFlag for United States of America asked on
DatabasesMicrosoft SQL ServerMicrosoft SQL Server 2005
10 Comments1 Solution293 ViewsLast Modified:
We have a table that tracks values for Combo Boxes. One field captures the actual name of the Control (cboSVC_AGREE_TYP). The INSERT INTO statement is as follows:

INSERT INTO OBJECT_REFS ( OBJ_TYP, OBJ_NM, OBJ_DESC, OBJ_VALUE, CREATE_BY, CREATE_DT) _
                  Values('Combo Box','cboSVC_AGREE_TYP',' Types of service Agreement','On Call 24-7', 'John Doe',GETDATE())

I get the following error:

sg 102, Level 15, State 1, Line 2
Incorrect syntax near '_'.

Data entry forms reference this table for their values and the Combo Box names match the field name in the applicable tables with the exception of the prefix "cbo"

Thanks for your help


ASKER CERTIFIED SOLUTION
Avatar of Patrick Matthews
Commented:
This problem has been solved!
Unlock 1 Answer and 10 Comments.
See Answers