I'm trying to get linux, php and MSSQL to play well with together.
I was able to get it to work for the most part - except that any OID (binary) data types are returned as gibberish UTF-8. For example:
string '�"Ή�%�' (length=8)
What I want to be returned is the hex value as seen when selecting from SQL Server Management tools. For example: 0x15C122CE89002595
Details:
Server: CentOS 6.4
PHP Version: 5.5.9
FreeTDS Version : 0.91RC2 (May 14, 2011)
I'm initalizing the connection with php function mssql_connect. I then execute the query with mssql_query and then fetch the results with mssql_fetch_assoc. I have tried this with PDO as well with no success. This makes me think its an issue with the FreeTDS install? Additionally, my coworkers install of SqlSrv on his windows machine returns the binary OID as expected.
Anyone else experience this issue with OID's being returned not as expected?
Thanks in advance.