Re: [sqlite] double_quote(text_field)

2012-02-23 Thread Bill McCormick

Yes, that should work.

Thanks!!
Dave Watkinson wrote, On 2/22/2012 5:33 PM:

Did you mean something like

SELECT ''||text_field||'' FROM table;

so that your column's data is quoted?


~~~
Dave Watkinson



On Wed, Feb 22, 2012 at 6:26 PM, Igor Tandetnikitandet...@mvps.org  wrote:


On 2/22/2012 6:03 PM, Bill McCormick wrote:


What is the easiest way to return a text field with double () quotes?

SELECT quote(text_field) FROM table; is close, but I'd rather have a
SELECT double_quote(text_field) FROM table;


I'm not sure I understand the nature of the problem. What's wrong with
simply

SELECT text_field FROM myTtable;

? There's nothing special about text fields that happen to contain a
double quote character.
--
Igor Tandetnik


__**_
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-**bin/mailman/listinfo/sqlite-**usershttp://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] double_quote(text_field)

2012-02-23 Thread Benoit Mortgat
The same, escaping double quotes inside the double quotes:

SELECT '' || replace(replace(text_field,'\','\\'),'','\') || ''

On Thu, Feb 23, 2012 at 15:16, Bill McCormick wpmccorm...@gmail.com wrote:
 Yes, that should work.

 Thanks!!
 Dave Watkinson wrote, On 2/22/2012 5:33 PM:

 Did you mean something like

 SELECT ''||text_field||'' FROM table;

 so that your column's data is quoted?

-- 
Benoit Mortgat
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


[sqlite] double_quote(text_field)

2012-02-22 Thread Bill McCormick

What is the easiest way to return a text field with double () quotes?

SELECT quote(text_field) FROM table; is close, but I'd rather have a 
SELECT double_quote(text_field) FROM table;


Thanks!!
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] double_quote(text_field)

2012-02-22 Thread Simon Slavin

On 22 Feb 2012, at 11:03pm, Bill McCormick wpmccorm...@gmail.com wrote:

 What is the easiest way to return a text field with double () quotes?
 
 SELECT quote(text_field) FROM table; is close, but I'd rather have a SELECT 
 double_quote(text_field) FROM table;

Does

SELECT quote(quote(text_field)) FROM table;

work ?

Simon.
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] double_quote(text_field)

2012-02-22 Thread Igor Tandetnik

On 2/22/2012 6:03 PM, Bill McCormick wrote:

What is the easiest way to return a text field with double () quotes?

SELECT quote(text_field) FROM table; is close, but I'd rather have a
SELECT double_quote(text_field) FROM table;


I'm not sure I understand the nature of the problem. What's wrong with 
simply


SELECT text_field FROM myTtable;

? There's nothing special about text fields that happen to contain a 
double quote character.

--
Igor Tandetnik

___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] double_quote(text_field)

2012-02-22 Thread Dave Watkinson
Did you mean something like

SELECT ''||text_field||'' FROM table;

so that your column's data is quoted?


~~~
Dave Watkinson



On Wed, Feb 22, 2012 at 6:26 PM, Igor Tandetnik itandet...@mvps.org wrote:

 On 2/22/2012 6:03 PM, Bill McCormick wrote:

 What is the easiest way to return a text field with double () quotes?

 SELECT quote(text_field) FROM table; is close, but I'd rather have a
 SELECT double_quote(text_field) FROM table;


 I'm not sure I understand the nature of the problem. What's wrong with
 simply

 SELECT text_field FROM myTtable;

 ? There's nothing special about text fields that happen to contain a
 double quote character.
 --
 Igor Tandetnik


 __**_
 sqlite-users mailing list
 sqlite-users@sqlite.org
 http://sqlite.org:8080/cgi-**bin/mailman/listinfo/sqlite-**usershttp://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users