Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Problem

Connectivity issues from the client to the SQL server can manifest itself in a number of ways. Sometimes no connection is possible at all, other times communication between the client and server is "flaky", giving intermittent error messages. Below are two examples of common connectivity issues:

...

Example 2 - Running a report within Jiwa gives an error message of "Logon Failed. Please try again."

Solution

If you are having trouble connecting to the SQL Server, you should begin the troubleshooting process by using SQL Server Management Studio - this is the official tool used to connect to and manage Microsoft SQL Servers. Microsoft offer this as a free download available from [here]. After installing, confirm that you still cannot connect to the SQL Server by attempting a connection using the SQL Server Management Studio:

...

There will normally be a delay between clicking the connect button and receiving the error message if it is connectivity issue rather than an authentication issue. This is because in the case of an authentication issue, the connection is made immediately but the server refuses login, whilst in the case of a connectivity issue the SQL Management Studio will try over and over to connect for around 15-30 seconds before giving up and reporting the error.


Anchor
SQLNativeClient
SQLNativeClient
SQL Native Client Version

If you are able to connect using the credentials with SQL Management Studio, and Jiwa the application is able to connect but generating reports produces the "Logon Failed" error - then the problem is may be the SQL Native Client has been removed from the machine, or the SQL Native client version is no longer the version Jiwa expects.

...

To rectify this, either re-instate the correct version of SQL Native Client, or use one of the following plugins to modify Jiwa's behaviour to force Crystal Reports to instead use the OLEDB provider - making report generation in Jiwa no longer dependent on the SQL Native Client.

07.01.00.00

View file
namePlugin Crystal Reports DB Provider to OLEDB 07.01.00.00.xml
height250

07.00.175.00

View file
namePlugin Crystal Reports DB Provider to OLEDB 07.00.175.00.xml
height250

DNS Problems

If you are able to connect using the credentials with SQL Management Studio, and Jiwa the application is able to connect but generating reports produces the "Logon Failed" error - then the problem may be your DNS service of your network. Jiwa uses connection resiliency and transient fault tolerance which masks DNS issues, but Crystal Reports does not, and so you may see the generating of reports produce the "Logon Failed" error.

To test if your DNS service is a factor, change the connections in Jiwa to use the IP address of the SQL Server instead of the SQL Server name. If the problems no longer occur when generating reports, then you should make corrective action with the DNS configuration of your network - consult your IT Department or IT consultant.

Connectivity Error

In the case of a connectivity error (unable to connect using the credentials with SQL Management Studio ), then there are 3 troubleshooting steps we can take in the case of a connectivity error.

Panel
bgColor#fff
  1. Allow SQL Server Through the Firewall
  2. Prefer TCP/IP Connections
  3. Allow Remote Connections

Anchor
AllowSQLServerThroughTheFirewall
AllowSQLServerThroughTheFirewall
Allow SQL Server Through the Firewall

The server machine may have a firewall enabled that is blocking incoming connections to the SQL Server. To allow SQL Server communication to occur through the firewall follow the steps below.

...

SQL Server Management Studio should now be again used to attempt to establish a connection. If the connection still fails, follow the second troubleshooting step provided below.

Anchor
PreferTCPIPConnections
PreferTCPIPConnections
Prefer TCP/IP Connections

If allowing the SQL Server program through the firewall as per above does not solve the connectivity issue, then we must check that the SQL Server itself is listening for TCP/IP connections. To do this the "SQL Server Configuration Manager" is used on the SQL Server machine.

...

After a minute the SQL Server Service will have restarted and will be listening for TCP/IP connections. SQL Server Management Studio should now be again used to attempt to establish a connection. If the connection still fails, follow the third troubleshooting step provided below.

Anchor
AllowRemoteConnections
AllowRemoteConnections
Allow Remote Connections

If you are able to connect to the SQL Server using SQL Server Management Studio on the server machine itself, then you should ensure that the SQL Server is configured to accept connections from remote computers.

...

4. On the right hand pane, ensure that the "Allow remote connections to this server" is ticked (see screenshot above). If it is not, tick it, and restart the SQL Server Service for changes to take affect.

Filter by label (Content by label)
showLabelsfalse
max5
spacesJ7UG
showSpacefalse
sortmodified
reversetrue
typepage
cqllabel in ("sqlserver","connectivity","connection") and type = "page" and space = "J7UG"
labelsconnection sqlserver connectivity

...