Re: varchar problem



Tony wrote:
Terry wrote:
[snip]
The filename (row[0]) is varchar and has no extra spaces.
Some of the entries (row[3]) have leading spaces - most do not.
Additionaly, I did not put any spaces in - why should I have to strip
them?


How is the data being entered? If it's through a form, a user could easily enter a leading or trailing space.

I said that I input the data in another post - which got snipped. I now have that problem sorted. All of the varchar fields are returning text strings without spaces at either end of the field.

Also, how are you writing the query?

$query="SELECT * FROM pictures WHERE width=200 ORDER BY RAND() LIMIT 6";

Now that I corrected my input method, that gives me clean strings as desired.

Thanks to all for your help, and patience.

--
TK
http://www.wejuggle2.com/
Still Having a Ball







..

----== Posted via Newsfeeds.Com - Unlimited-Uncensored-Secure Usenet News==----
http://www.newsfeeds.com The #1 Newsgroup Service in the World! 120,000+ Newsgroups
----= East and West-Coast Server Farms - Total Privacy via Encryption =----
.