Got a legacy PHP app. The SQL database instance moved from 2012 to 2017 and in the process, we had to change the sql driver from 'SQL Server' to 'ODBC Driver 17 for SQL Server'. Now getting the question mark symbols and what appears to be encoding issues. Feel like I've tried everything to get this working but no luck. Did however find something strange, if I cast the fields to varchar(8000) in the sql select statment, it would render the text correctly. Example below:
Does not work even though the underlying fields in the view are varchar(x):
SELECT * FROM ExampleView
This does however seem to work and render the text correctly to screen:
SELECT
convert(varchar(8000), ExampleOne) as ExampleOne
,convert(varchar(8000),ExampleTwo) as ExampleTwo
,convert(varchar(8000),ExampleThree) as ExampleThree
FROM ExampleView