Go Back   Access World Forums > Apps and Windows > Web Design and Development > PHP & MySQL

 
Reply
 
Thread Tools Rate Thread Display Modes
Old 05-21-2015, 09:04 AM   #1
MBMSOFT
Newly Registered User
 
Join Date: Jan 2010
Location: ohrid, macedonia
Posts: 79
Thanks: 3
Thanked 1 Time in 1 Post
MBMSOFT is on a distinguished road
I need to retrieve Cyrillic data from MSSQL database with PHP but I get back "???????

I need to retrieve Cyrillic data from MSSQL database with PHP but I get back "???????"

Code:
<?php

   $dbconn = new PDO('odbc:Driver=FreeTDS; Server=xxx.xxx.xxx.xx; Port=1433; Database=xxxxxx; UID=xxxx; PWD=xxxxx; )');

   if ($dbconn->connect_error) {die("Connection failed: " .    $dbconn->connect_error);}

    //$dbconn->debug = true;
    
$sql="select data1 from myTABLE where data2 ='text' ";

    $query = $dbconn->query($sql);
    $query->execute();
    $rs = $query->fetchColumn();

echo $rs;
?>
Result is "?????" instead of cyrillic text
Any idea how to get non-unicode characters from mssql database
Thanks...

MBMSOFT is offline   Reply With Quote
Old 09-03-2017, 04:37 AM   #2
youyiyang
Newly Registered User
 
Join Date: Apr 2009
Location: China
Posts: 51
Thanks: 8
Thanked 6 Times in 6 Posts
youyiyang is on a distinguished road
Re: I need to retrieve Cyrillic data from MSSQL database with PHP but I get back "???

the problem is in your client side.
use this in your client side html page:
<meta charset=utf-8>
references:
https://technet.microsoft.com/en-us/...=sql.105).aspx

https://stackoverflow.com/questions/...oding-cyrillic
youyiyang is offline   Reply With Quote
Old 09-03-2017, 04:56 AM   #3
arnelgp
Newly Registered User
 
arnelgp's Avatar
 
Join Date: May 2009
Location: somewhere out there
Posts: 3,736
Thanks: 46
Thanked 1,267 Times in 1,199 Posts
arnelgp has a spectacular aura about arnelgp has a spectacular aura about
Re: I need to retrieve Cyrillic data from MSSQL database with PHP but I get back "???

Uh, check the post date.

__________________
"Never stop learning, because life never stops teaching"
arnelgp is offline   Reply With Quote
Reply

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
How to retrieve data from other table in Access 2010 web database irslan rafique Access Web 0 11-03-2014 06:22 PM
Back to work on an old project and greeted with "unrecognized database format" Jon-G General 8 06-20-2013 07:44 AM
How to fill "Local Tables" with Password Protected back-end database tables Khalid_Afridi Tables 8 11-01-2012 06:45 AM
Retrieve email data to database NigelShaw General 3 02-13-2009 09:58 PM
Data Insert...getting back the "autonumber" value. Chatbox Modules & VBA 11 10-18-2004 02:17 PM




All times are GMT -8. The time now is 11:55 AM.


Microsoft Access Help
General
Tables
Queries
Forms
Reports
Macros
Modules & VBA
Theory & Practice
Access FAQs
Code Repository
Sample Databases
Video Tutorials

Sponsored Links

How to advertise

Media Kit


Powered by vBulletin®
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
(c) copyright 2017 Access World