mysql collation

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Bob Bedford

    mysql collation

    I've no access to mysql NG, so I ask here:

    I've two identical tables (wich are created by usins the same script, but
    must be separated).

    When I execute a query wich return fields and do a UNION between them, I
    get:
    Illegal mix of collations for operation 'UNION'

    I had an old mysql version on the server, and since my ISP upgraded, I have
    problems with collations. The base is now in latin1_swedish_ ci, and my datas
    may manage french text.

    Why the union doesn't work ? what do I need to do. The entire site is
    working, but not this query. I get crazy.

    What should I do, collation for both table are latin1_swedish_ ci, and also
    text fields.


  • Jerry Stuckle

    #2
    Re: mysql collation

    Bob Bedford wrote:[color=blue]
    > I've no access to mysql NG, so I ask here:
    >
    > I've two identical tables (wich are created by usins the same script,
    > but must be separated).
    >
    > When I execute a query wich return fields and do a UNION between them, I
    > get:
    > Illegal mix of collations for operation 'UNION'
    >
    > I had an old mysql version on the server, and since my ISP upgraded, I
    > have problems with collations. The base is now in latin1_swedish_ ci, and
    > my datas may manage french text.
    >
    > Why the union doesn't work ? what do I need to do. The entire site is
    > working, but not this query. I get crazy.
    >
    > What should I do, collation for both table are latin1_swedish_ ci, and
    > also text fields.
    >[/color]

    Bob,

    Just a wild guess - but check the collation on your connection. I had
    several collation related problems because my tables were
    latin1_swedish_ ci and the connection was defaulting to utf8.

    I have my own server, so I was able to change the default collation for
    all connections. Since it looks like you can't do that, you can use the
    SET NAMES to change it.

    --
    =============== ===
    Remove the "x" from my email address
    Jerry Stuckle
    JDS Computer Training Corp.
    jstucklex@attgl obal.net
    =============== ===

    Comment

    Working...