ColdFusion Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming Languages - MoreColdFusion Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
Get inside! Sample the range of functionality easily built with JMSL Library for Time Series Data Analysis, Heat Maps, Portfolio Optimization, Monte Carlo Simulation, Stock Price Charting and more. Download Now!
  #1  
Old August 26th, 2003, 02:19 PM
blockcipher blockcipher is offline
Contributing User
Dev Shed Novice (500 - 999 posts)
 
Join Date: Mar 2003
Posts: 701 blockcipher User rank is Sergeant Major (2000 - 5000 Reputation Level)blockcipher User rank is Sergeant Major (2000 - 5000 Reputation Level)blockcipher User rank is Sergeant Major (2000 - 5000 Reputation Level)blockcipher User rank is Sergeant Major (2000 - 5000 Reputation Level)blockcipher User rank is Sergeant Major (2000 - 5000 Reputation Level)blockcipher User rank is Sergeant Major (2000 - 5000 Reputation Level) 
Time spent in forums: 3 Days 7 h 40 m 21 sec
Reputation Power: 55
CF and latin1 character sets

Does anybody know how to make ColdFusion use the latin1 character set? We're trying to get Flash and MySQL talking to each other using ColdFusion and it keeps messing up the non-english characters. From what I've read, it uses UTF8 by default, however that's not supported by MySQL right now. I think it will be in 4.1, however everything I've seen suggests that it's broken. Using a cfcontent type may not work since we're planning on using cfc's.
__________________
blockcipher
---------------
Gratuitously stolen...
mysql> SELECT * FROM user WHERE clue > 0;
0 Results Returned.

PHP5/MySQL/UTF-8
My Tech Blog

Reply With Quote
  #2  
Old August 27th, 2003, 11:59 AM
kiteless kiteless is offline
Moderator
Dev Shed Expert (3500 - 3999 posts)
 
Join Date: Jun 2002
Location: Raleigh, NC
Posts: 3,626 kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level) 
Time spent in forums: 1 Week 4 Days 10 h 6 m 34 sec
Reputation Power: 53
You can do different character sets in ColdFusion MX by placing:

<cfprocessingdirective pageencoding="UTF-8">

at the top of whatever page you want to handle UTF encoding.

Reply With Quote
  #3  
Old August 27th, 2003, 01:05 PM
blockcipher blockcipher is offline
Contributing User
Dev Shed Novice (500 - 999 posts)
 
Join Date: Mar 2003
Posts: 701 blockcipher User rank is Sergeant Major (2000 - 5000 Reputation Level)blockcipher User rank is Sergeant Major (2000 - 5000 Reputation Level)blockcipher User rank is Sergeant Major (2000 - 5000 Reputation Level)blockcipher User rank is Sergeant Major (2000 - 5000 Reputation Level)blockcipher User rank is Sergeant Major (2000 - 5000 Reputation Level)blockcipher User rank is Sergeant Major (2000 - 5000 Reputation Level) 
Time spent in forums: 3 Days 7 h 40 m 21 sec
Reputation Power: 55
Well, that didn't help. I tried it in every file that I could be it a cfc or a regular cfm and nothing helped. When I look at a cfm file, Firebird still thinks it's UTF-8. Is there any way to put UTF-8 data in MySQL and have ColdFusion read it back as UTF-8? I tried a few things like using a blob instead of text, but that only caused problems.

Reply With Quote
  #4  
Old August 27th, 2003, 05:32 PM
kiteless kiteless is offline
Moderator
Dev Shed Expert (3500 - 3999 posts)
 
Join Date: Jun 2002
Location: Raleigh, NC
Posts: 3,626 kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level)kiteless User rank is Sergeant Major (2000 - 5000 Reputation Level) 
Time spent in forums: 1 Week 4 Days 10 h 6 m 34 sec
Reputation Power: 53
My bad, I didn't see that CF is only pulling the data from MySQL and forwarding it to Flash. Yes, this is definitely a MySQL issue, not a ColdFusion one. I believe you are right that the current version of MySQL does not support UTF encoding. There's nothing that CF can do about it, it can only use what's in the database. For sure if you are using ColdFusion MX it supports UTF encoded characters, so until you can get the data in and out of MySQL in the right format there's nothing that can be done other than switching databases of course. Maybe Postgre?

Reply With Quote
  #5  
Old August 28th, 2003, 11:30 AM
blockcipher blockcipher is offline
Contributing User
Dev Shed Novice (500 - 999 posts)
 
Join Date: Mar 2003
Posts: 701 blockcipher User rank is Sergeant Major (2000 - 5000 Reputation Level)blockcipher User rank is Sergeant Major (2000 - 5000 Reputation Level)blockcipher User rank is Sergeant Major (2000 - 5000 Reputation Level)blockcipher User rank is Sergeant Major (2000 - 5000 Reputation Level)blockcipher User rank is Sergeant Major (2000 - 5000 Reputation Level)blockcipher User rank is Sergeant Major (2000 - 5000 Reputation Level) 
Time spent in forums: 3 Days 7 h 40 m 21 sec
Reputation Power: 55
Damn...that was not the answer I was hoping for. As for alternatives, we're locked in to MySQL by our customer's support contractor. I do thank you for your time.

Reply With Quote
  #6  
Old September 8th, 2003, 10:08 PM
wadechandler wadechandler is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Sep 2003
Location: Winston Salem, NC
Posts: 2 wadechandler User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
It will work, but you can't use ODBC use JDBC instead.

You can make the page you want to work work. You just have to use JDBC instead of ODBC. Setup a folder and place the JConnector java jar files into the directory. Next update your Java classpath from the Cold fusion interface to include the 3 jars. 2 from lib and the 1 mysql jar. Next, restart your cold fusion server. Now, go to setup a connection. You will put in your usual options then you will have to put this in the connectionstring section.....
for example:
replace below values with your respective values.....
Database=test
Server=192.168.1.10
username=someuser
password=somepassword

Under Advanced Settings
ConnectionString=
jdbc:mysql://192.168.1.10/test?user=someuser&password=somepassword&useUnicode=true&characterEncoding=latin1


That should do the trick.

It's pretty simple just read carefully. Java supports unicode natively, so of course the java drivers can support it. The problem was the C API's in the ODBC driver. The next ODBC driver should have Uni support so they say, but who knows. Good luck, this setup is working fine for me.

Wade

Reply With Quote
  #7  
Old September 8th, 2003, 10:11 PM
wadechandler wadechandler is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Sep 2003
Location: Winston Salem, NC
Posts: 2 wadechandler User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
MySQL and Unicode.

Yes MYSQL itself supports unicode. You can manipulate the date using MyCC and can put in an character you want and get them back out as they were entered. MyCC uses mysql api's though. The odbc driver is a little less useful however. Just thought you might like to be informed that MySQL itself supports unicode fine.

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming Languages - MoreColdFusion Development > CF and latin1 character sets


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 2 hosted by Hostway