Drop Table

Support Forum for database administrators and web based access to important newsgroups related to databases
Register on Database Support Forum Edit your profileCalendarFind other Database Support forum membersFrequently Asked QuestionsSearch this forum -> 
For Database admins: Free Database-related Magazines Now Free shipping to Texas


Post New Thread










Thread
Author

how to include an apostrophy inside a string
I am doing a row update in a table and the text contains a ' character, just
wondering how to do this?

for example
UPDATE table
SET field2 = 'text to enter to table's but does not work'
WHERE field1 = 133
the second apostrophy I want to not end the text section with.
Thanks.

--
Paul G
Software engineer.

Report this thread to moderator Post Follow-up to this message
Old Post
Paul
08-31-05 04:23 PM


RE: how to include an apostrophy inside a string
YOu have to double quote that:

UPDATE table
SET field2 = 'text to enter to table''s but does not work'
WHERE field1 = 133


--
HTH, Jens Suessmeyer.

---
http://www.sqlserver2005.de
---


"Paul" wrote:

> I am doing a row update in a table and the text contains a ' character, ju
st
> wondering how to do this?
>
> for example
> UPDATE table
> SET field2 = 'text to enter to table's but does not work'
> WHERE field1 = 133
> the second apostrophy I want to not end the text section with.
> Thanks.
>
> --
> Paul G
> Software engineer.

Report this thread to moderator Post Follow-up to this message
Old Post
Jens Süßmeyer
08-31-05 04:23 PM


RE: how to include an apostrophy inside a string
ok thanks. One other question, when I use select from query analizer to
retreive a long text field and then copy and paste it to a word doc it looks
like it only returns the first portion of the large text string.  Also is
there anyway to view a large text field from query analyzer when you open th
e
table?  thanks again.
--
Paul G
Software engineer.


"Jens Süßmeyer" wrote:

> YOu have to double quote that:
>
> UPDATE table
> SET field2 = 'text to enter to table''s but does not work'
> WHERE field1 = 133
>
>
> --
> HTH, Jens Suessmeyer.
>
> ---
> http://www.sqlserver2005.de
> ---
>
>
> "Paul" wrote:
> 

Report this thread to moderator Post Follow-up to this message
Old Post
Paul
08-31-05 04:23 PM


RE: how to include an apostrophy inside a string
QA is limited to a maximum  outpur of 8000 characters, if you don´t have ev
en
that you should look in Tools--> Options --> Results --> Maximum charcters
per column

to increase it to 8000
--
HTH, Jens Suessmeyer.

---
http://www.sqlserver2005.de
---


"Paul" wrote:

> ok thanks. One other question, when I use select from query analizer to
> retreive a long text field and then copy and paste it to a word doc it loo
ks
> like it only returns the first portion of the large text string.  Also is
> there anyway to view a large text field from query analyzer when you open 
the
> table?  thanks again.
> --
> Paul G
> Software engineer.
>
>
> "Jens Süßmeyer" wrote:
> 

Report this thread to moderator Post Follow-up to this message
Old Post
Jens Süßmeyer
08-31-05 04:23 PM


RE: how to include an apostrophy inside a string
ok thanks that should do it as it is way less than 8000 characters.
--
Paul G
Software engineer.


"Jens Süßmeyer" wrote:

> QA is limited to a maximum  outpur of 8000 characters, if you don´t have 
even
> that you should look in Tools--> Options --> Results --> Maximum charcters
> per column
>
> to increase it to 8000
> --
> HTH, Jens Suessmeyer.
>
> ---
> http://www.sqlserver2005.de
> ---
>
>
> "Paul" wrote:
> 

Report this thread to moderator Post Follow-up to this message
Old Post
Paul
08-31-05 04:23 PM


RE: how to include an apostrophy inside a string
Just wondering if you know how to direct the results to a file?
--
Paul G
Software engineer.


"Jens Süßmeyer" wrote:

> QA is limited to a maximum  outpur of 8000 characters, if you don´t have 
even
> that you should look in Tools--> Options --> Results --> Maximum charcters
> per column
>
> to increase it to 8000
> --
> HTH, Jens Suessmeyer.
>
> ---
> http://www.sqlserver2005.de
> ---
>
>
> "Paul" wrote:
> 

Report this thread to moderator Post Follow-up to this message
Old Post
Paul
08-31-05 04:23 PM


RE: how to include an apostrophy inside a string
Press CTRL-Shift+F in WA then Execute the query or select the menu Query -->
Results in File

or you use OSQL on the commandline with the -o <outputfile >switch
--
HTH, Jens Suessmeyer.

---
http://www.sqlserver2005.de
---


"Paul" wrote:

> Just wondering if you know how to direct the results to a file?
> --
> Paul G
> Software engineer.
>
>
> "Jens Süßmeyer" wrote:
> 

Report this thread to moderator Post Follow-up to this message
Old Post
Jens Süßmeyer
08-31-05 04:23 PM


RE: how to include an apostrophy inside a string
ok thanks this seems very useful.
--
Paul G
Software engineer.


"Jens Süßmeyer" wrote:

>
> Press CTRL-Shift+F in WA then Execute the query or select the menu Query -
->
> Results in File
>
> or you use OSQL on the commandline with the -o <outputfile >switch
> --
> HTH, Jens Suessmeyer.
>
> ---
> http://www.sqlserver2005.de
> ---
>
>
> "Paul" wrote:
> 

Report this thread to moderator Post Follow-up to this message
Old Post
Paul
08-31-05 06:23 PM


Sponsored Links





Last Thread Next Thread
Post New Thread

MS SQL Server archive

Show a Printable Version Email This Page to Someone! Receive updates to this thread
Microsoft SQL Server
Access database support
PostgreSQL Replication
SQL Server ODBC
FoxPro Support
PostgreSQL pgAdmin
SQL Server Clustering
MySQL ODBC
Web Applications with dBASE
SQL Server CE
MySQL++
Sybase Database Support
MS SQL Full Text Search
PostgreSQL Administration
SQL Anywhere support
DB2 UDB Database
Paradox Database Support
Filemaker Database
Berkley DB
SQL 2000/2000i database
ASE Database
Forum Jump:
All times are GMT. The time now is 12:49 PM.

 
Mobile devices forum | Database support forum archive




Copyrights DropTable.com Database Support Forum 2004 - 2006