#1
  1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jun 2002
    Posts
    16
    Rep Power
    0

    Unhappy difference between and ""


    The data file (*.txt) I tried to bulkload into MySQL database
    contains some instead of "" in the strings. When I tried to show those as links on JSP, I found that they changed into question mark '?'. And when I click the links, I want to call another JSP to show the contents related to the strings. And of course in this case the search failed. MySQL does not support , right?

    Can anyone help me out? Thank you very much!
  2. #2
  3. No Profile Picture
    Clueless llama
    Devshed Regular (2000 - 2499 posts)

    Join Date
    Feb 2001
    Location
    Lincoln, NE. USA
    Posts
    2,353
    Rep Power
    117
    My first guess would be that the hex code for that character is being interpreted different by the different parsers. Browsers and Java use unicode as far as I know, but what about mysql? What character is the correct one? It is highly possible that mysql is indeed changing the character into something it thinks it should be. In the end, none of what we type is really characters at all, it is only hex values that something must then convert into characters.
  4. #3
  5. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jun 2002
    Posts
    16
    Rep Power
    0
    Thank you very much! When I checked it in MySQ and also read it under Unix system, I found that all turned into , and some of dash - turned into .

    Can we configure MySQL to accept those characters, or we need to convert all into "" before loading the data file into MySQL?

    Thanks a lot.
  6. #4
  7. No Profile Picture
    Clueless llama
    Devshed Regular (2000 - 2499 posts)

    Join Date
    Feb 2001
    Location
    Lincoln, NE. USA
    Posts
    2,353
    Rep Power
    117
    If it is indeed supposed to be a double quote, I would convert it to that I guess. I do not know what kind of data you are using, so it is hard to say how critical that would be. Regardless of what it is, make sure and encode it if you are using it in a url.

    http://java.sun.com/j2se/1.4/docs/ap...RLEncoder.html

IMN logo majestic logo threadwatch logo seochat tools logo