SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Connection String worked with SQL2005 but not with SQL2012


Connection String worked with SQL2005 but not with SQL2012

Author
Message
lonex
lonex
Forum Newbie
Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)

Group: General Forum Members
Points: 8 Visits: 31
I have an application for document management that when we index documents, we retrieve some info from SQL2012 tables.
My connection string is:

Driver={SQL Server};Server=SERVER8;Database=Live2012;Uid=Intact_Select;Pwd=1234;

When I retrieve info from database to index a document I get error "the connection cannot be used to perform this operation. it is either closed or invalid in this context"

Same connection string format works with SQL2005. I appreciate your help asap.
Thanks and happy new year!
patricklambin
patricklambin
SSCarpal Tunnel
SSCarpal Tunnel (4.1K reputation)SSCarpal Tunnel (4.1K reputation)SSCarpal Tunnel (4.1K reputation)SSCarpal Tunnel (4.1K reputation)SSCarpal Tunnel (4.1K reputation)SSCarpal Tunnel (4.1K reputation)SSCarpal Tunnel (4.1K reputation)SSCarpal Tunnel (4.1K reputation)

Group: General Forum Members
Points: 4072 Visits: 1241
Hello,

Please, could you provide more information about your problem ? For example :
- the OS on which the SQL Server is installed and the OS for the computer on which you are executing your task
if it is a Windows Server 2003 , I would suggest you to have a look at :
http://support.microsoft.com/kb/839428 ( MDAC not updated )

- the provider you are using to connect ( ADODB,...)
if ADODB, I would suggest you to have a look at
http://forums.aspfree.com/asp-development-5/adodb-recordset-error-800a0e7d-connection-cannot-used-perform-opera-514972.html
- if it is inside in an application , the code related to the connection should be useful

Have a nice day and happy new year
lonex
lonex
Forum Newbie
Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)

Group: General Forum Members
Points: 8 Visits: 31
Hello and happy new year

I am executing task from remote desktop on Server2008 Standard edition. On this server I have installed Document management
that uses this connection string to access SQL2012 database that is on another server with Windows 2012

As I noted before we had following string previously that worked and only difference was that the server that run database was
Windows 2003 and database was SQL2005. So the only difference is the server that is hosting database and datbase version.


Previouly I had this connection string:
Driver={SQL Server};Server=SERVER7;Database=AXDB;Uid=Intact_Select;Pwd=1234;

And now new script that pointing to new server with Windows2012 and SQL2012 is:

Driver={SQL Server};Server=SERVER8;Database=Live2012;Uid=Intact_Select;Pwd=1234;


This string is configurable inside Document management system and not in the code. Not sure about any database provider
Hope this gives any idea for any possible solutions to try
patricklambin
patricklambin
SSCarpal Tunnel
SSCarpal Tunnel (4.1K reputation)SSCarpal Tunnel (4.1K reputation)SSCarpal Tunnel (4.1K reputation)SSCarpal Tunnel (4.1K reputation)SSCarpal Tunnel (4.1K reputation)SSCarpal Tunnel (4.1K reputation)SSCarpal Tunnel (4.1K reputation)SSCarpal Tunnel (4.1K reputation)

Group: General Forum Members
Points: 4072 Visits: 1241
Hello,
I have done some research about Document Management but I am annoyed because I don't know the company which provided it , so it is difficult to find the good connection string even in http://www.connectionstrings.com/
Thru http://search.yahoo.com/search;_ylt=Ap9Do80WtjKtHmn4lZ7nwp2vulI6?p=Document+Management&type=2button&fr=ush-mailn_02 , I found SharePoint 2013 and other products not Microsoft that I have never used.
We need more information to try to help you more efficiently.

Have a nice day
SQLRNNR
SQLRNNR
SSC-Forever
SSC-Forever (40K reputation)SSC-Forever (40K reputation)SSC-Forever (40K reputation)SSC-Forever (40K reputation)SSC-Forever (40K reputation)SSC-Forever (40K reputation)SSC-Forever (40K reputation)SSC-Forever (40K reputation)

Group: General Forum Members
Points: 40259 Visits: 18565
Have you checked with the application provider to a) confirm the application is SQL 2012 compatible and b) verified connection string changes for SQL 2012 that they recommend?

Based on the database name, it appears the software you are looking at configuring is either Axapta or it is Dynamics AX. Unless you are using the latest version of Dynamics AX, it is not SQL 2012 compatible. And looking at the versions of Axapta that were available in SQL 2005, I would say that app is also not compatible.

But these are just wild guesses at your application.



Jason AKA CirqueDeSQLeil
I have given a name to my pain...
MCM SQL Server, MVP


SQL RNNR

Posting Performance Based Questions - Gail Shaw

mister.magoo
mister.magoo
SSCertifiable
SSCertifiable (5.4K reputation)SSCertifiable (5.4K reputation)SSCertifiable (5.4K reputation)SSCertifiable (5.4K reputation)SSCertifiable (5.4K reputation)SSCertifiable (5.4K reputation)SSCertifiable (5.4K reputation)SSCertifiable (5.4K reputation)

Group: General Forum Members
Points: 5400 Visits: 7871
You may need to install the new ODBC drivers for SQL 2012 from http://www.microsoft.com/en-gb/download/details.aspx?id=36434

It will install a new ODBC driver called "ODBC Driver 11 For SQL Server" which you could try in place of "SQL Server" as the "Driver=" part of your connection string.

I don't guarantee this is the solution, and it is your responsibility to read all about it first ;-)

Introducing the new Microsoft ODBC Drivers for SQL Server

EDIT: This is a client install, not a server install.

MM


select geometry::STGeomFromWKB(0x0106000000020000000103000000010000000B0000001000000000000840000000000000003DD8CCCCCCCCCC0840000000000000003DD8CCCCCCCCCC08408014AE47E17AFC3F040000000000104000CDCCCCCCCCEC3F9C999999999913408014AE47E17AFC3F9C99999999991340000000000000003D0000000000001440000000000000003D000000000000144000000000000000400400000000001040000000000000F03F100000000000084000000000000000401000000000000840000000000000003D0103000000010000000B000000000000000000143D000000000000003D009E99999999B93F000000000000003D009E99999999B93F8014AE47E17AFC3F400000000000F03F00CDCCCCCCCCEC3FA06666666666FE3F8014AE47E17AFC3FA06666666666FE3F000000000000003D1800000000000040000000000000003D18000000000000400000000000000040400000000000F03F000000000000F03F000000000000143D0000000000000040000000000000143D000000000000003D, 0);




  • Forum Etiquette: How to post Reporting Services problems
  • Forum Etiquette: How to post data/code on a forum to get the best help - by Jeff Moden
  • How to Post Performance Problems - by Gail Shaw

  • James Horsley
    James Horsley
    Old Hand
    Old Hand (367 reputation)Old Hand (367 reputation)Old Hand (367 reputation)Old Hand (367 reputation)Old Hand (367 reputation)Old Hand (367 reputation)Old Hand (367 reputation)Old Hand (367 reputation)

    Group: General Forum Members
    Points: 367 Visits: 451
    Big change is probably the OS Win 2003 -> Win 2012 (change of SQL Server may have compatibility issues but they are more likely to show after connect because error you are getting is saying it ca't connect so at that point the application won't even know what server version it is.

    My guess is it may be something simple like the Win 2012 firewall blocking connections or the protocol not enabled on with new SQL server - make sure you can connect to the new server and db from chosen client with ISQL using the same credentials etc.




    James Horsley
    Workflow Consulting Limited
    lonex
    lonex
    Forum Newbie
    Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)

    Group: General Forum Members
    Points: 8 Visits: 31
    I have turned off windows firewall on the machine that is Windows 2012 and host SQL2012 that I am trying to access it but still same error 'The connection cannot be used to perform this operation. It is either closed or invalid in this context'.

    You mentioned other protocol may need to be enabled on SQL2012. Can you be more specific so I can try that as well.
    James Horsley
    James Horsley
    Old Hand
    Old Hand (367 reputation)Old Hand (367 reputation)Old Hand (367 reputation)Old Hand (367 reputation)Old Hand (367 reputation)Old Hand (367 reputation)Old Hand (367 reputation)Old Hand (367 reputation)

    Group: General Forum Members
    Points: 367 Visits: 451
    Are you able to connect using ISQL or equivalent from the same client machine? As for protocol make sure TCP/IP is enabled in the SQL Server configuration manager, server network configuration




    James Horsley
    Workflow Consulting Limited
    lonex
    lonex
    Forum Newbie
    Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)Forum Newbie (8 reputation)

    Group: General Forum Members
    Points: 8 Visits: 31
    Now is working and not getting error. I restarted this document management application and is working. However now even after enabling firewall is working so need to see more what is happening but looks that I am close. Thanks all for your help
    Go


    Permissions

    You can't post new topics.
    You can't post topic replies.
    You can't post new polls.
    You can't post replies to polls.
    You can't edit your own topics.
    You can't delete your own topics.
    You can't edit other topics.
    You can't delete other topics.
    You can't edit your own posts.
    You can't edit other posts.
    You can't delete your own posts.
    You can't delete other posts.
    You can't post events.
    You can't edit your own events.
    You can't edit other events.
    You can't delete your own events.
    You can't delete other events.
    You can't send private messages.
    You can't send emails.
    You can read topics.
    You can't vote in polls.
    You can't upload attachments.
    You can download attachments.
    You can't post HTML code.
    You can't edit HTML code.
    You can't post IFCode.
    You can't post JavaScript.
    You can post emoticons.
    You can't post or upload images.

    Select a forum

































































































































































    SQLServerCentral


    Search