Can't connect to local MySQL database using Crystal Reports

给你一囗甜甜゛ 提交于 2019-12-12 02:46:55

问题


I'm trying to create a report using Crystal Reports and that first requires connecting to my local MySQL Database.

I'm using this database connector string:

Driver={MySQL ODBC 5.3.6 Driver};Server=localhost:3306;Database=mcs;User=admin;Password=admin123;Option=3

I get this error:

The connector is installed and the MySQL database is there.


回答1:


  • start >> search microsoft odbc administrator
  • on user dsn click add >> search mysql odbc (if not found close >> right click on microsoft odbc administrator >> properties >> set target to "C:\Windows\SysWOW64\odbcad32.exe")
  • set data source name=localhost >> tcp/ip=127.0.0.1 >> port=3306 >> user=admin >> password=admin123
  • click test >> select database=mcs >> ok
  • open database expert on crystal report >> make new connection >> odbc
  • check select data source >> choose your data source name >> finish


来源:https://stackoverflow.com/questions/40516796/cant-connect-to-local-mysql-database-using-crystal-reports

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!