----- Original Message -----
From: "Smile-Poet"
> I am using MySQL. Can you advse me further?
In mySQL, CONCAT( ) doesn't put anything between the strings. If you want
", " between them then use WS_CONCAT( ) (which also tolerates some of the
values being NULL:
It's all in the mySQL help file... mysql.chm... all your answers are in the
following, cut-and-pasted out of the section on 'String Functions'.
However... and this is a serious point... I knew nothing whatsoever about
CONCAT before I spent one minute looking it up just now. I have made a good
living for the last twenty years or so out of being able to find things in
help files that are invisible to 99% of the population (known to geeks as
"mundanes"), and almost everything I know I found out looking it up when a
confused user asked me about it. So don't feel bad if you did look and
didn't find it!
CONCAT(str1,str2,...)
Returns the string that results from concatenating the arguments. Returns
NULL if any argument is NULL. May have more than 2 arguments. A numeric
argument is converted to the equivalent string form:
mysql> SELECT CONCAT('My', 'S', 'QL');
-> 'MySQL'
mysql> SELECT CONCAT('My', NULL, 'QL');
-> NULL
mysql> SELECT CONCAT(14.3);
-> '14.3'
CONCAT_WS(separator, str1, str2,...)
CONCAT_WS() stands for CONCAT With Separator and is a special form of
CONCAT(). The first argument is the separator for the rest of the arguments.
The separator can be a string as well as the rest of the arguments. If the
separator is NULL, the result will be NULL. The function will skip any NULLs
and empty strings, after the separator argument. The separator will be added
between the strings to be concatenated:
mysql> SELECT CONCAT_WS(",","First name","Second name","Last Name");
-> 'First name,Second name,Last Name'
mysql> SELECT CONCAT_WS(",","First name",NULL,"Last Name");
-> 'First name,Last Name'
____ � The WDVL Discussion List from WDVL.COM � ____
To Join wdvltalk, Send An Email To: mailto:[EMAIL PROTECTED]
Send Your Posts To: [EMAIL PROTECTED]
To set a personal password send an email to [EMAIL PROTECTED] with the words: "set
WDVLTALK pw=yourpassword" in the body of the email.
To change subscription settings to the wdvltalk digest version:
http://wdvl.internet.com/WDVL/Forum/#sub
________________ http://www.wdvl.com _______________________
You are currently subscribed to wdvltalk as: [EMAIL PROTECTED]
To unsubscribe send a blank email to [EMAIL PROTECTED]
To unsubscribe via postal mail, please contact us at:
Jupitermedia Corp.
Attn: Discussion List Management
475 Park Avenue South
New York, NY 10016
Please include the email address which you have been contacted with.