ORA-12514: TNS:listener does not currently know of service requested in connect descriptor

Posts   
 
    
Skeeterbug
User
Posts: 165
Joined: 21-May-2004
# Posted on: 04-Jan-2007 20:48:34   

Using ODP.NET Version 10.1.0.400. I think something got messed up with the configuration when I installed Oracle10g ODAC 10.1.0.4.0. This should work with the express edition right? The express edition installed 10.2.0.100, that gave a different error when I used that version :-s. Using the latest version of LLBLGen v2.

Connection string: <add key="Main.ConnectionString" value="data source=127.0.0.1;user id=sa;password=;persist security info=false;"/>

Stack trace:


   at Oracle.DataAccess.Client.OracleException.HandleErrorHelper(Int32 errCode, OracleConnection conn, IntPtr opsErrCtx, OpoSqlValCtx* pOpoSqlValCtx, Object src, String procedure)
   at Oracle.DataAccess.Client.OracleException.HandleError(Int32 errCode, OracleConnection conn, IntPtr opsErrCtx, Object src)
   at Oracle.DataAccess.Client.OracleConnection.Open()
   at SD.LLBLGen.Pro.ORMSupportClasses.DataAccessAdapterBase.OpenConnection()
   at SD.LLBLGen.Pro.ORMSupportClasses.DataAccessAdapterBase.ExecuteMultiRowRetrievalQuery(IRetrievalQuery queryToExecute, IEntityFactory2 entityFactory, IEntityCollection2 collectionToFill, IFieldPersistenceInfo[] fieldsPersistenceInfo, Boolean allowDuplicates, IEntityFields2 fieldsUsedForQuery)
   at SD.LLBLGen.Pro.ORMSupportClasses.DataAccessAdapterBase.FetchEntityCollectionInternal(IEntityCollection2 collectionToFill, IRelationPredicateBucket& filterBucket, Int32 maxNumberOfItemsToReturn, ISortExpression sortClauses, Int32 pageNumber, Int32 pageSize)
   at SD.LLBLGen.Pro.ORMSupportClasses.DataAccessAdapterBase.FetchEntityCollection(IEntityCollection2 collectionToFill, IRelationPredicateBucket filterBucket, Int32 maxNumberOfItemsToReturn, ISortExpression sortClauses, Int32 pageNumber, Int32 pageSize)
   at SD.LLBLGen.Pro.ORMSupportClasses.DataAccessAdapterBase.FetchEntityCollection(IEntityCollection2 collectionToFill, IRelationPredicateBucket filterBucket, Int32 maxNumberOfItemsToReturn)
   at MissionFire.BLL.Security.SecurityTicket.Create(String username, String password) in C:\Mission3Source\trunk\MissionFire\Security\SecurityTicket.cs:line 227
   at WebMissionFire.Login.mLogIn() in c:\Mission3Source\trunk\MissionFire\WebMissionFire\Login.aspx.cs:line 169
   at WebMissionFire.Login.btnLogin_Click(Object sender, EventArgs e) in c:\Mission3Source\trunk\MissionFire\WebMissionFire\Login.aspx.cs:line 53
   at Mission3.Web.UI.ImgButton.OnClick(EventArgs e) in C:\Mission3Source\trunk\MissionFire\Mission3.Web.UI\ImgButton\ImgButton.cs:line 237
   at Mission3.Web.UI.ImgButton.RaisePostBackEvent(String eventArgument) in C:\Mission3Source\trunk\MissionFire\Mission3.Web.UI\ImgButton\ImgButton.cs:line 272
   at System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument)
   at System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData)
   at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

Skeeterbug
User
Posts: 165
Joined: 21-May-2004
# Posted on: 04-Jan-2007 23:19:59   

So the ODAC really messed up the express server configuration. I am re-installing it now (I installed ODAC first, to get the 10.1 provider, hopefully this works).

Skeeterbug
User
Posts: 165
Joined: 21-May-2004
# Posted on: 05-Jan-2007 01:49:33   

I added a redirect and got 10.2 to load OK. However, now I am getting yet another error wink

[OracleException: Data provider internal error(-3000) [System.String]]
   Oracle.DataAccess.Client.OracleException.HandleErrorHelper(Int32 errCode, OracleConnection conn, IntPtr opsErrCtx, OpoSqlValCtx* pOpoSqlValCtx, Object src, String procedure) +1005
   Oracle.DataAccess.Client.OracleException.HandleError(Int32 errCode, OracleConnection conn, IntPtr opsErrCtx, Object src) +45
   Oracle.DataAccess.Client.OracleConnection.Open() +4527
   SD.LLBLGen.Pro.ORMSupportClasses.DataAccessAdapterBase.OpenConnection() +188
   SD.LLBLGen.Pro.ORMSupportClasses.DataAccessAdapterBase.ExecuteMultiRowRetrievalQuery(IRetrievalQuery queryToExecute, IEntityFactory2 entityFactory, IEntityCollection2 collectionToFill, IFieldPersistenceInfo[] fieldsPersistenceInfo, Boolean allowDuplicates, IEntityFields2 fieldsUsedForQuery) +618
   SD.LLBLGen.Pro.ORMSupportClasses.DataAccessAdapterBase.FetchEntityCollectionInternal(IEntityCollection2 collectionToFill, IRelationPredicateBucket& filterBucket, Int32 maxNumberOfItemsToReturn, ISortExpression sortClauses, Int32 pageNumber, Int32 pageSize) +822
   SD.LLBLGen.Pro.ORMSupportClasses.DataAccessAdapterBase.FetchEntityCollection(IEntityCollection2 collectionToFill, IRelationPredicateBucket filterBucket, Int32 maxNumberOfItemsToReturn, ISortExpression sortClauses, Int32 pageNumber, Int32 pageSize) +237
   SD.LLBLGen.Pro.ORMSupportClasses.DataAccessAdapterBase.FetchEntityCollection(IEntityCollection2 collectionToFill, IRelationPredicateBucket filterBucket, Int32 maxNumberOfItemsToReturn) +45
   MissionFire.BLL.Security.SecurityTicket.Create(String username, String password) in C:\Mission3Source\trunk\MissionFire\Security\SecurityTicket.cs:217
   WebMissionFire.Login.mLogIn() in c:\Mission3Source\trunk\MissionFire\WebMissionFire\Login.aspx.cs:169
   WebMissionFire.Login.btnLogin_Click(Object sender, EventArgs e) in c:\Mission3Source\trunk\MissionFire\WebMissionFire\Login.aspx.cs:53
   Mission3.Web.UI.ImgButton.OnClick(EventArgs e) in C:\Mission3Source\trunk\MissionFire\Mission3.Web.UI\ImgButton\ImgButton.cs:237
   Mission3.Web.UI.ImgButton.RaisePostBackEvent(String eventArgument) in C:\Mission3Source\trunk\MissionFire\Mission3.Web.UI\ImgButton\ImgButton.cs:272
   System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +32
   System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +244
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3835

Does ASP.NET handle redirects differently? I copied the code from my web Login() method to a Winforms application and it ran without any problems (using the same DAL/DBSpecific libraries).

bclubb
User
Posts: 934
Joined: 12-Feb-2004
# Posted on: 05-Jan-2007 02:27:39   

Can you post the code that is causing the problem?

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39614
Joined: 17-Aug-2003
# Posted on: 05-Jan-2007 10:09:52   

I always find errors with 'internal' in their description a matter of the vendor. wink

Seriously: I have no idea what is causing this. One thing that might be a problem is the localhost IP address you're using. If you refer to your system's normal IP address, do you get different results? Did you setup the oracle listener correctly?

Frans Bouma | Lead developer LLBLGen Pro
Skeeterbug
User
Posts: 165
Joined: 21-May-2004
# Posted on: 05-Jan-2007 17:52:34   

Otis wrote:

I always find errors with 'internal' in their description a matter of the vendor. wink

Seriously: I have no idea what is causing this. One thing that might be a problem is the localhost IP address you're using. If you refer to your system's normal IP address, do you get different results? Did you setup the oracle listener correctly?

I am not having a problem with the listener anymore. The internal error is only happening in the ASP.NET app. I copied the code from my login to a windows form app and it ran OK. Really ackward.

Here is the code that is throwing an error


                //create relationpredicate and predicate expression
                IRelationPredicateBucket bucket = new RelationPredicateBucket();

                //setup comparison
                bucket.PredicateExpression.Add(UserFields.UserName == username);
                bucket.PredicateExpression.AddWithAnd(UserFields.Password == password);

                EntityCollection<UserEntity> col = new EntityCollection<UserEntity>();

                try
                {
                    //fetch
                    adapter.FetchEntityCollection(col, bucket, 1);

Here is the stacktrace


   at Oracle.DataAccess.Client.OracleException.HandleErrorHelper(Int32 errCode, OracleConnection conn, IntPtr opsErrCtx, OpoSqlValCtx* pOpoSqlValCtx, Object src, String procedure)
   at Oracle.DataAccess.Client.OracleException.HandleError(Int32 errCode, OracleConnection conn, IntPtr opsErrCtx, Object src)
   at Oracle.DataAccess.Client.OracleConnection.Open()
   at SD.LLBLGen.Pro.ORMSupportClasses.DataAccessAdapterBase.OpenConnection()
   at SD.LLBLGen.Pro.ORMSupportClasses.DataAccessAdapterBase.ExecuteMultiRowRetrievalQuery(IRetrievalQuery queryToExecute, IEntityFactory2 entityFactory, IEntityCollection2 collectionToFill, IFieldPersistenceInfo[] fieldsPersistenceInfo, Boolean allowDuplicates, IEntityFields2 fieldsUsedForQuery)
   at SD.LLBLGen.Pro.ORMSupportClasses.DataAccessAdapterBase.FetchEntityCollectionInternal(IEntityCollection2 collectionToFill, IRelationPredicateBucket& filterBucket, Int32 maxNumberOfItemsToReturn, ISortExpression sortClauses, Int32 pageNumber, Int32 pageSize)
   at SD.LLBLGen.Pro.ORMSupportClasses.DataAccessAdapterBase.FetchEntityCollection(IEntityCollection2 collectionToFill, IRelationPredicateBucket filterBucket, Int32 maxNumberOfItemsToReturn, ISortExpression sortClauses, Int32 pageNumber, Int32 pageSize)
   at SD.LLBLGen.Pro.ORMSupportClasses.DataAccessAdapterBase.FetchEntityCollection(IEntityCollection2 collectionToFill, IRelationPredicateBucket filterBucket, Int32 maxNumberOfItemsToReturn)
   at MissionFire.BLL.Security.SecurityTicket.Create(String username, String password) in C:\Mission3Source\trunk\MissionFire\Security\SecurityTicket.cs:line 217
   at WebMissionFire.Login.mLogIn() in c:\Mission3Source\trunk\MissionFire\WebMissionFire\Login.aspx.cs:line 169
   at WebMissionFire.Login.btnLogin_Click(Object sender, EventArgs e) in c:\Mission3Source\trunk\MissionFire\WebMissionFire\Login.aspx.cs:line 53
   at Mission3.Web.UI.ImgButton.OnClick(EventArgs e) in C:\Mission3Source\trunk\MissionFire\Mission3.Web.UI\ImgButton\ImgButton.cs:line 237
   at Mission3.Web.UI.ImgButton.RaisePostBackEvent(String eventArgument) in C:\Mission3Source\trunk\MissionFire\Mission3.Web.UI\ImgButton\ImgButton.cs:line 272
   at System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument)
   at System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData)
   at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

Like I said, I copied this function, and the DAL/Specific libraries to a new test project, and it runs without any problems. I will go over my ASP.NET configuration a bit more I guess disappointed

Skeeterbug
User
Posts: 165
Joined: 21-May-2004
# Posted on: 05-Jan-2007 18:38:53   

I marked this thread as done, I will go on the Oracle forums and bug them wink

Thanks.

Skeeterbug
User
Posts: 165
Joined: 21-May-2004
# Posted on: 05-Jan-2007 22:30:25