Solved

How to use backslash in SQL?

Posted on 2004-09-23
1
748 Views
Last Modified: 2010-05-18
Hi,

I have this query I am TRYING to write.

I get an error in sql query analyzer

SELECT * FROM tblName
where someColumn = 40
and os = windows\2000

that woudl be an example..

I get this as an error msg

Line 3: Incorrect syntax near '\'.

Must be some way to escape this??

-ws
0
Comment
Question by:Westside2004
1 Comment
 
LVL 6

Accepted Solution

by:
OlegP earned 125 total points
ID: 12140593
SELECT * FROM tblName
where someColumn = 40
and os = 'windows\2000'
0

Featured Post

NAS Cloud Backup Strategies

This article explains backup scenarios when using network storage. We review the so-called “3-2-1 strategy” and summarize the methods you can use to send NAS data to the cloud

Question has a verified solution.

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

Suggested Solutions

Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
I have a large data set and a SSIS package. How can I load this file in multi threading?
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.
Via a live example, show how to backup a database, simulate a failure backup the tail of the database transaction log and perform the restore.

776 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