<cut>
> three digits, dash, four digits). I want to compare the second
> set of three digits to each other, something like
>
> WHERE Interviewee.homephone[4-6] = Interviewer.homephone[4-6]
>
> Similarly for zip codes, I want to compare the first three characters
> of a char[10] (zip plus 4], essentially
>
> WHERE Interviewee.zip[0-2] = Interviewer.zip[0-2]
>
> Are these types of comparisons possible? If so, what's the syntax? I
> couldn't find anything in the online documentation, though it's
> possibly not called "slicing" or "string range"...
Check the manual for one of the following functions...
LEFT
RIGHT
MID
SUBSTRING (several incarnations)
SUBSTRING_INDEX
/ Carsten
--
Carsten H. Pedersen
keeper and maintainer of the bitbybit.dk MySQL FAQ
http://www.bitbybit.dk/mysqlfaq
---------------------------------------------------------------------
Before posting, please check:
http://www.mysql.com/manual.php (the manual)
http://lists.mysql.com/ (the list archive)
To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php