Solved

Crystal Reports work fine on laptop but not on deployment to server.

Posted on 2007-03-29
13
1,442 Views
Last Modified: 2012-06-21
Hi,
I am writing a web application that will display a Crytal Report on my ASP.NET 2.0 website.  The setup is as follows:  My web application is written in ASP.NET 2.0 using Visual Studio 2005 Pro. The crystal report retrieves data from an Oracle database running on a Unix server.  I am developing on my laptop and I am deploying to a Windows 2003 Web server.   I have installed the Oracle Client on the server and my laptop.  I have installed the Crystal Runtime on the server. All of this is on the same domain. My problem is:

I run the solution on my laptop and the website loads, I enter my logon credentials to the oracle server and the report displays.  I therefore deploy to the server and when I run it I get the following error:

"Failed to open the connection. Details: [Database Vendor Code: 12154 ] Failed to open the connection. C:\WINDOWS\TEMP\1300_sp_Rep_Stock {0CFEDA9D-B567-4F31-9980-944C394C8BA9}.rpt Details: [Database Vendor Code: 12154 ] "

I have put the same TNSnames.ora file on both machines, I have checked the TNS Admin path.  I am now at a loss - what have I missed?

Any help greatly appreciated.

Mike

0
Comment
Question by:hydev
13 Comments
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 18816136
It's almost defiantly a tnsnames problem.  The vendor code equates to ORA-12154.

Does the server maybe have multiple Oracle_homes?
From the server see if you can tnsping the instance.  From a command prompt:  tnsping ORCL

Where ORCL is the database from the tnsnames file.
0
 

Author Comment

by:hydev
ID: 18816185
Yes that pings fine
0
 

Author Comment

by:hydev
ID: 18816292
By using Process Monitor I have found the following thing in c:\windows\system32\inetsrv\sqlnet.log:

"Fatal NI connect error 12560, connecting to:
 (DESCRIPTION=(ADDRESS=(PROTOCOL=BEQ)(PROGRAM=oracle)(ARGV0=oracleORCL)(ARGS='(DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))'))(CONNECT_DATA=(SID=ORCL)(CID=(PROGRAM=c:\windows\system32\inetsrv\w3wp.exe)(HOST=LIGHTSHIP)(USER=NETWORK?SERVICE))))

  VERSION INFORMATION:
      TNS for 32-bit Windows: Version 10.2.0.1.0 - Production
      Oracle Bequeath NT Protocol Adapter for 32-bit Windows: Version 10.2.0.1.0 - Production
  Time: 29-MAR-2007 15:14:42
  Tracing not turned on.
  Tns error struct:
    ns main err code: 12560
    TNS-12560: TNS:protocol adapter error
    ns secondary err code: 0
    nt main err code: 530
    TNS-00530: Protocol adapter error
    nt secondary err code: 126
    nt OS err code: 0"

Interesting bit is this part "CONNECT_DATA=(SID=ORCL)" This should be surley my SID as defined in TNSnames.ora, in this case its "CIMSG".  where is it getting that SID from?  My TNSNAMES.ORA is in c:\oracle\product\10.2.0\client_2\ is this the correct place?

My TNSNAMEs.ORA reads as:

CIMSX =
  (DESCRIPTION =
    (ADDRESS_LIST =
      (ADDRESS = (PROTOCOL = TCP)(HOST = 10.0.0.19)(PORT = 1521))
    )
    (CONNECT_DATA =
      (SERVICE_NAME = x)
    )
  )

CIMSG =
  (DESCRIPTION =
    (ADDRESS_LIST =
      (ADDRESS = (PROTOCOL = TCP)(HOST = 10.0.0.19)(PORT = 1521))
    )
    (CONNECT_DATA =
      (SERVICE_NAME = g)
    )
  )

EXTPROC_CONNECTION_DATA =
  (DESCRIPTION =
    (ADDRESS_LIST =
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC0))
    )
    (CONNECT_DATA =
      (SID = PLSExtProc)
      (PRESENTATION = RO)
    )
  )


0
 
LVL 100

Expert Comment

by:mlmcc
ID: 18816321
What Crystal runtime and dlls did you install?

Did you install the Crystal database driver?

mlmcc
0
 
LVL 47

Expert Comment

by:schwertner
ID: 18816415
If you have installed Oracle client try to ping the Listener:

C:\>tnsping CIMSX

It will show the directory of tnsnames.ora file and if it can reach
the listener.

Is the server  10g?
If yes try to post LISTENER.ORA here.
0
 

Author Comment

by:hydev
ID: 18816434
Ah... now you might be onto something.  I installed the Crystal Reports XI Release 2 server install. (crXI2_net_server_install.zip)

Whats that about a Crystal Database Driver? I have the Oracle client installed on the web server aswell.  Thought Crystal talked to that..
0
How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

 
LVL 100

Expert Comment

by:mlmcc
ID: 18816547
How did you connect the report to the database?  Most reports use a Crystal database driver.

mlmcc
0
 

Author Comment

by:hydev
ID: 18817419
In Crystal I used the OLE DB (ADO) connection and then selected the "Microsoft OLE DB Provider for Oracle"
0
 
LVL 100

Expert Comment

by:mlmcc
ID: 18818293
Did you install the MS OLE DB Provider for Oracle?  That is not the Oracle client that you installed.

mlmcc

0
 
LVL 100

Expert Comment

by:mlmcc
ID: 18818316
I am not sure which file(s) you need.  Here are the 2 from CR8
P2SORA7.DLL  - Oracle
P2SMON.DLL - ADO

mlmcc
0
 

Author Comment

by:hydev
ID: 18818927
mlmmc - So could be a school boy error here - Even though I have installed the Oracle Client on the server, I also need to install the MS OLE DB Provider for Oracle on it aswell?  That would make sense then, because the report on the server would be looking for that.  Where can I donwload that from and is it straight forward to install?
0
 
LVL 100

Accepted Solution

by:
mlmcc earned 500 total points
ID: 18820119
You should hacve it or it is on the Crystal CDs.

mlmcc
0
 
LVL 100

Expert Comment

by:mlmcc
ID: 19136120
Glad i could help

mlmcc
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Background In several of the companies I have worked for, I noticed that corporate reporting is off loaded from the production database and done mainly on a clone database which needs to be kept up to date daily by various means, be it a logical…
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
This video explains at a high level with the mandatory Oracle Memory processes are as well as touching on some of the more common optional ones.
This video shows how to copy a database user from one database to another user DBMS_METADATA.  It also shows how to copy a user's permissions and discusses password hash differences between Oracle 10g and 11g.

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now