Re: Character Set Question
Need more information... what exactly is Our older version, and what exactly is the newest version of MySql, without this it's hard to know what issues you may be facing... I imagine you are on 4.0.n for the old and 4.1.n for the new... but we can't really tell from the information you gave us. When you run mysqldump you get an output file with everything in it... I suggest running mysqldump --tab=/var/tmp/somedirectory which will create a series of files in the location you specify, with a .sql file for each table with the create table command, and a .txt file for each table with the data in tab delimited format. This gives you an easy way to edit the create table statements to make sure each table has the character set information you really want in it before you import the data. Then you can do the import using cat *sql | mysql database to create the tables, and run mysqlimport against the .txt files to insert the data. Using this process you can more precisely manage your tables so they have the right character set for each column... you can do it by editing your regular mysqldump output file, but it's a big file and this way is just easier... it's also quicker to do the import this way. Be sure to dump the old database using the old mysqldump, that way if there was no character set information it won't put something in there by mistake (the new mysqldump could insert something of it's choosing if there is nothing defined)... be sure to use the new mysql client and mysqlimport to insert the data into the new version, making sure to use an appropriate --default-character-set setting each time you call it. Best Regards, Bruce On Aug 12, 2005, at 4:24 AM, James Sherwood wrote: Hello, We have installed the newest version of MySql and cannot get it to play nice with French characters. Our older version worked fine. The problem may (or may not) be that when we put the dump into the new database(yes its default charset is Utf8) the default character set for the table is Utf8 but some fields are like this: 'Story' longtext character set latin1 NOT NULL We tried linking our tomcat to the old database on the other server through this tomcat and everything works fine but when we link the tomcat back to the new database, it will not play nice with french characters. (they come out as outlined squares etc) Any ideas would be greatly appreciated James -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/mysql? [EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Character Set Question
Hello, We have installed the newest version of MySql and cannot get it to play nice with French characters. Our older version worked fine. The problem may (or may not) be that when we put the dump into the new database(yes its default charset is Utf8) the default character set for the table is Utf8 but some fields are like this: 'Story' longtext character set latin1 NOT NULL We tried linking our tomcat to the old database on the other server through this tomcat and everything works fine but when we link the tomcat back to the new database, it will not play nice with french characters. (they come out as outlined squares etc) Any ideas would be greatly appreciated James -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
SET question - @ or @@?
While I was RTFM to find out how long SET variables last, I noticed that my book uses @@VarName but the sample code I'm using has @ VarName. I didn't see a reference to the single @ in the SET section of my book. So, what is the difference between @@ and @? Thank you.
Re: SET question - @ or @@?
At 10:23 -0600 3/25/05, Stembridge, Michael wrote: While I was RTFM to find out how long SET variables last, I noticed that my book uses @@VarName but the sample code I'm using has @ VarName. I didn't see a reference to the single @ in the SET section of my book. So, what is the difference between @@ and @? @ is used for user variables (variables that you define yourself) @@ is used for system variables, such as storage_engine or sql_mode. http://dev.mysql.com/doc/mysql/en/set-option.html http://dev.mysql.com/doc/mysql/en/variables.html -- Paul DuBois, MySQL Documentation Team Madison, Wisconsin, USA MySQL AB, www.mysql.com -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: SET question - @ or @@?
- Original Message - From: Stembridge, Michael [EMAIL PROTECTED] To: mysql@lists.mysql.com Sent: Friday, March 25, 2005 5:23 PM Subject: SET question - @ or @@? While I was RTFM to find out how long SET variables last, I noticed that my book uses @@VarName but the sample code I'm using has @ VarName. I didn't see a reference to the single @ in the SET section of my book. So, what is the difference between @@ and @? Read: http://dev.mysql.com/doc/mysql/en/set-option.html about different types of variables and their syntax and http://dev.mysql.com/doc/mysql/en/variables.html about user variables in particular... Regards, Jigal. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: SET question
This is a reply to the SET column UPDATE question (I deleted to e-mail, oups!). The question was that you have a column of type SET and value ("a,b,c") and you want to make this ("a,b,c,d") In the __MySQL MANUAL__ it says that the SET type is actually stored numerically and in particular "with the low-order bit of the stored value corresponding to the first set member" and a couple of lines further down "If a number is stored into a SET column, the bits that are set in the binary representation of the number determine the set members in the column value" i.e. if your set has values "a,b,c,d" then: a = 0001 b = 0010 c = 0100 d = 1000 So if you do an update of the form: UPDATE table SET set_var=3 WHERE my_cond; it would actually make set_var=("a,b") for the tuple that my_cond holds since the ten_Base 3 is the binary 11. So in your case that you want to add "d" to a tuple that is "a,b,c" you do UPDATE table SET set_val=15 WHERE my_cond; since 15 is in binary (the leftmost '1' is the flag that tells mysql to add the "d" in your set) does it make any sense? regards, thalis ---+ You're definitely on their list. The correct question to ask is what list it is. ---+ - 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
Re: SET question
"Thalis A. Kalfigopoulos" writes: So in your case that you want to add "d" to a tuple that is "a,b,c" you do UPDATE table SET set_val=15 WHERE my_cond; since 15 is in binary (the leftmost '1' is the flag that tells mysql to add the "d" in your set) does it make any sense? Yes, but it doesn't solve my problem because in actuality I don't know what the current value of the set is, I just want to add something to it. I was trying to illustrate my problem so that people didn't think I wanted to alter the table. --Cindy - 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