Mssql connection with vbscript - error

http://gallery.technet.microsoft.com/scriptcenter/a6a9d2a4-705f-4e37-86db-33caca7473cb
Im using above script but get and error.
The setup is mssql express 2012
DB name: testdb
DB user: testusr
pass: Test12345
Server: testsrv
From another mashine could i fine connect to the server with server management studio with above info:
Servername: testsrv\sqlexpress
Auth: SQL Server Authentication
Login: testusr
Pwd: Test12345
I have updatet the script with my info:
Const adOpenStatic = 3 
Const adLockOptimistic = 3 
Set objConnection = CreateObject("ADODB.Connection") 
Set objRecordSet = CreateObject("ADODB.Recordset") 
objConnection.Open _ 
    "Provider=SQLOLEDB;Data Source=testsrv/sqlexpress;" & _ 
        "Trusted_Connection=Yes;Initial Catalog=testdb;" & _ 
             "User ID=testusr;Password=Test12345;" 
objRecordSet.Open "SELECT * FROM [testdb].[dbo].[Persons]", _ 
        objConnection, adOpenStatic, adLockOptimistic 
objRecordSet.MoveFirst 
Wscript.Echo objRecordSet.RecordCount 
Get this error:
Line 7, char 1
[dbnetlib][connectionopen (Connect()).]SQL Server does not exist or access denied.
code. 80004005
Source: Microsoft OLE DB Provider for SQL Server
Helpdesk Supporter

Remove Trusted:
 objConnection.Open   "Provider=SQLOLEDB.1;Password=12345;Persist Security Info=True;User ID=tessuser;Initial Catalog=testdb;Data Source=testsvr"
¯\_(ツ)_/¯

Similar Messages

  • Java.sql.SQLException:listener refused the connection with the  error

    hi my problem is in repository assistant IN 2ND STEP
    After i enter the
    Repository User name sindhu
    Repository User Password tiger (As i kept the password of Oracle 10g)
    SYSDBA User name SYS
    SYSDBA Password tiger (As i kept the password of Oracle 10g)
    Host name Local Host
    Port number 1521 (default)
    Oracle Service name OracleServiceXE
    and i am not clicking the SQL* Plus
    and clicking on " Next "
    then my prob is
    INS0009:Unable to connect to the database with the user SYS
    java.sql.SQLException : Listener refused the connection with the following error
    ORA-12514, TNS: listener dosenot currently know of service requested in connect descriptor
    The Connection Descriptor used by the client was
    (DESCRIPTION=(ADDRESS=(HOST=LOCALHOST)(PROTOCOL=tcp)(PORT=1521))(CONNECT_DATA=
    (SERVICE_NAME=ORACLESERVICEXE)))
    hope some one will give me a gud solution
    Waiting for ur reply
    Sindhu

    ...OWB repository cannot be installed into Oracle XE.
    Cheers
    David

  • "Lost connection with AIM" error message

    Hi all,
    I've been a long-time iChat user — I've had very few problems, but now, at home, whenever I've been connected for about 10-15mins, iChat just disconnects with the simple iChat Connect Alert that the app has "Lost connection with AIM. The connection with the host was unexpectedly lost."
    My Buddy List collapses to a "disconnected" header and I diappear from my Buddies' buddy lists. If I'm in the middle of a chat (video, audio or text), the chat continues uninterrupted, but I still disappear from people's lists as if I'd disconnected manually. Weird.
    The net result is that I have to keep checking to see if I'm connected and then reconnecting all the time. A real pain in the proverbial.
    It only happens at the house. My laptop doesn't disconnect if I'm at the office, for instance.
    I have cable, coming in to Netgear 814v2 router; out to an 8-port gigabit switch, which then feeds my three main machines. All via ethernet cabling.
    All machines have the same problem described above.
    I've made the usual Quicktime setting changes.
    I've listed the necessary ports in my Mac firewall settings (even though the firewall is turned off).
    Each machine has a dedicated IP issued by the router (10.0.0.2 thru 10.0.0.5)
    The router firmware is up to date.
    What else is there?! I have no problems initiating or joining any sort of chat with my buddies around the world. I have excellent bandwidth. My internet and email are never interrupted 24/7.
    Can someone help me? Pretty please?
    17" Powerbook G4 & Dual G5 2.5Ghz   Mac OS X (10.4.7)  

    Hi
    Try this log on to AIM on port 443 rather than port 5190
    Go to IChat > Preferences > Accounts.
    Log out of AIM and then use the Server Settings tab
    Set the port to 443.
    Log back in again.
    Tony

  • DB connect error  (MSSQL connectivity with SAP BI)- Urgent

    Hi all,
    I am trying to connect the MSSQL 2005 Database to the SAP BI system through RAC.During the creation of the source System(DB Connect) it placed an error as
    DIA RSA1 BY G No shared library found for the database with ID SALMSSQL.
    Can someone please let me know how we can comeup with this issue?Where we can download LIB_DBSL.SAR and the process to load it into theDIR_LIBRARY default path as we are using RAC connectivity.This is very important.Please suggest me
    During the process of creation DB connect source system for MSS what we need to fill for the Connection Info option i.e System IP or the IP of Database and which Databasetable
    DB Connection MSSQL
    DBMS MSS
    User Name sa
    DB password /
    Conn. info MSSQL_SERVER= ? MSSQL_DBNAME= ?
    Connection Limit
    Optimum Conns
    Will reward points.
    Thanks
    D

    Hello Dash,
    Follow the below mentioned steps to create a dbconnect source system.
    1. Goto RSA1 -> Source systems. Right click and Create
    2. Give some name and description and hit enter
    3. a. Con Name : Any name (SQLSRV, etc)
    b. DBMS : MSS
    c. UserName : Any username which is present in the SQL Server. Eg: SA.
    If you have to use Windows Authentication, there is a seperate method :
    For windows authentication, you will have to add your Admin login of BI Server to the SQL Server Security logins group (For Eg: If BI Server name is BID and the admin login for this server is BIDADM, you need to add BIDADM to Logins/Users group of SQL Server and also for the specific database).
    d. Password : Anything.
    e. Con Env : MSSQL_SERVER=<sql server name> MSSQL_DBNAME=<database name> OBJECT_SOURCE= DBO.
    For Example:
    MSSQL_SERVER=ps14apollo MSSQL_DBNAME=PROJECTSERVER_REPORTING OBJECT_SOURCE=DBO
    Here ps14apollo is my SQL Server name. Similarly ProjectServer_Reporting is my database name. DBO should be the Object_Source for most of the SQL Server dbs. I think it should work in your case as well.
    f. DB RECO = select or let it remain unselected.
    g & h Max Connections & OPT Connections = 0, for unlimited connections.
    Regards,
    F-S

  • CCMS Connectivity with Status Error

    Hi,
    I am in the process of System Monitoring using Solution Manager.
    In Setup System Monitoring window, Check CCMS connectivity is Red color, then I generated & save RFC connections for systems , but still I am getting same error with CCMS connectivity. If any idea please explain me with step by step.
    Thanks in advance
    Regards
    Srinivas

    Hi Srinivas,
    Can u check teh Alerts as shown by in the Help doc as below.
    http://help.sap.com/saphelp_sm40/helpdata/en/3b/a8413599b244b6a03ac9d2a3bdaf2f/content.htm
    as always the good old best blog on thsi topic can be referred. /people/luisfelipe.lanz/blog/2006/02/07/installing-a-solution-manager-diagnostics-the-easy-way
    Hope this should clarify your quests.
    Br,
    Sri
    Award points for helpful answers

  • Ipad not connect with computer. error number (0xE8000084), ipad not connect with computer error number (0xE8000084)

    ipad not connected to computer. erreo number (0xE8000084)

    Hello Mohamed Abdo,
    It sounds like you are unable to connect your iPad to the computer because you get this error code when you try. I would use the troubleshooting for these types of errors from the following article:
    iOS: Unknown error containing '0xE' when connecting to a Windows PC
    http://support.apple.com/kb/TS3221
    Start with these steps, and there are additional steps in the article if you need them:
    1. Restart your computer.
    2. Install the latest version of iTunes.
    3. Verify that your computer meets the minimum system requirements. iOS devices require the following minimum version of Windows:
    Windows XP Service Pack 3
    Windows Vista
    Windows 7
    Windows 8
    4. Download and install any available software updates from Microsoft.
    5. Connect the device directly to your computer; not to an external USB hub. Find out if your computer has USB 2.0 ports.
    6. Check that the Dock Connector or Lightning Connector on both the device and cable are clean of any lint or other debris. If possible, connect your device using a different Apple 30-pin to USB cable or Apple Lightning Connector to USB cable.
    7. Disconnect other USB peripherals from your computer, with the exception of your keyboard and mouse. After disconnecting these peripherals, restart your computer, connect your device, and open iTunes.
    8. Connect your device to a different USB port on your computer.
    Thank you for using Apple Support Communities.
    Take care,
    Sterling

  • MSSQL connection with PHP in DW

    Hello,
    I know that DW 8 has a built-in connection when using php
    with a mysql database.
    However, I would like to connect to a remote Microsoft SQL
    Server with DW and php.
    Is there a way to make this connection ? Probably not
    built-in but maybe through any other way ? I have full access to
    the SQL Server.
    Thanks in advance for your help.
    Marion

    MarionKi wrote:
    > Hello,
    > I know that DW 8 has a built-in connection when using
    php with a mysql
    > database.
    > However, I would like to connect to a remote Microsoft
    SQL Server with DW and
    > php.
    > Is there a way to make this connection ? Probably not
    built-in but maybe
    > through any other way ? I have full access to the SQL
    Server.
    All the server behaviors in Dreamweaver are MySQL specific,
    so even if
    you make a connection, none of the DW code will work.
    PHP 5 introduced PDO (PHP Data Objects), which allow
    connection to any
    database (providing the appropriate drivers are installed on
    the
    server). However, DW doesn't yet support PDO.
    You will need to hand-code everything yourself.
    David Powers, Adobe Community Expert
    Author, "Foundation PHP for Dreamweaver 8" (friends of ED)
    Author, "PHP Solutions" (friends of ED)
    http://foundationphp.com/

  • Epson 3800 and Airport Express...drops connection with communication error

    My problem is: my airport express worked fine for over a year as a wireless printer usb hook-up...but now it always says communication error after it starts to send data. I am using a epson 3800 with the newest driver (for leopard) and I have tested to see that the printer works by hooking it directly to the computer with a USB cable. I have also reset the airport express and reconfigured it. I have also switched out the airport express with another one in my house to test to see if it works. The airport express seems fine and will play iTunes remotely....but just will not print. I have also uninstalled the printer and re-installed it. I am at a loss to even what steps to try next, I upgraded to leopard and was not able to print much till the epson leopard drivers came out a few weeks ago...so I don't even know if its a leopard problem or epson...help

    I had the same problem after I upgraded to Leopard and installed the newest R1800 driver from Epson and I got the same response from Epson. The Gutenprint driver does work but it does not handle color management properly and as you have discovered, not all of the print options are properly supported.
    You can solve the problem by reverting to the older V3.0aAs driver available at Epson's website. When I did this I believe I used the epson installer to uninstall the v6.12 driver. Then I restarted and installed V3.0aAs and restarted once again. The old printer driver was automatically selected when I installed the printer.
    Note. Before you do this, upgrade to 10.5.2 and see if that resolves the problem. The installation notes state that this upgrade resolves the issues printing to "some" printers but it does not say which. If this works, please post your findings and the rest of us R1800 owners can re-install the new driver.

  • Exchange Server 2013 // MFCMAPI could connect with errors

    While connecting with Exchange Server 2013 I have started facing problem with my application.
    My application fails to connect to Exchange with below parameters, then i have tried using MFCMAPI to if everything is okay. MFCMAPI could connect with above errors.
    And I have tried with program using below parameters, i still get network error from MAPI call. Can you kindly help, I can provide any additional
    details needed.
    ___ props[prop_count].ulPropTag = PR_PROFILE_UNRESOLVED_NAME;
        props[prop_count].Value.lpszA   = <ProfileUnresolvedName>;
        prop_count++;
        props[prop_count].ulPropTag     = PR_PROFILE_UNRESOLVED_SERVER;
        props[prop_count].Value.lpszA   = <[email protected]>;
        prop_count++;
        // Setting this to TRUE causes OpenMsgStore() to fail with MAPI_E_UNCONFIGURED
        props[prop_count].ulPropTag      = PR_CONVERSION_PROHIBITED;
        props[prop_count].Value.b        = FALSE;
        prop_count++;
        props[prop_count].ulPropTag     = PR_PROFILE_CONFIG_FLAGS;
        props[prop_count].Value.l       = CONFIG_SERVICE /*| CONFIG_PROMPT_FOR_CREDENTIALS
    | CONFIG_SHOW_CONNECT_UI */;
        prop_count++;
        props[prop_count].ulPropTag     = PR_DISPLAY_NAME;
        props[prop_count].Value.lpszA   = <Mailbox Profile Name>;
        prop_count++;
        //Above setting used to be sufficient to connect using RPC
        //Below parameters added to connect via HTTPS
        LPSTR pwszUser = "domain\\username"; //also tried
    [email protected] AND username
        LPWSTR pwszPassword = L"paswword"; // Password has been encrypted using CryptProtectData
        props[prop_count].ulPropTag = PR_PROFILE_RPC_PROXY_SERVER_W;
        props[prop_count].Value.lpszW = L"https://ProxyHostname.domain";
        prop_count++;
        props[prop_count].ulPropTag = PR_PROFILE_RPC_PROXY_SERVER_AUTH_PACKAGE;
        props[prop_count].Value.l = RPC_C_AUTHN_NONE;      // RPC_C_HTTP_AUTHN_SCHEME_NTLM,
    RPC_C_HTTP_AUTHN_SCHEME_BASIC
        prop_count++;
        props[prop_count].ulPropTag =  PR_PROFILE_RPC_PROXY_SERVER_FLAGS;
        props[prop_count].Value.l = PRXF_ENABLED | PRXF_SSL;// | PRXF_IGNORE_SEC_WARNING; // | PRXF_IGNORE_SEC_WARNING;
        prop_count++;
        props[prop_count].ulPropTag = PR_PROFILE_RPC_PROXY_SERVER_PRINCIPAL_W;
        props[prop_count].Value.lpszW = L"msstd:certificateserverhostname.domain";
        prop_count++;
        props[prop_count].ulPropTag = PR_PROFILE_AUTH_PACKAGE;
        props[prop_count].Value.l = RPC_C_AUTHN_GSS_NEGOTIATE;               
    // RPC_C_AUTHN_WINNT, RPC_C_AUTHN_GSS_NEGOTIATE, RPC_C_AUTHN_NONE
        prop_count++;
        props[prop_count].ulPropTag = PR_PROFILE_AUTH_USER_W;
        props[prop_count].Value.lpszA = pwszUser;
        prop_count++;
        props[prop_count].ulPropTag = PR_PROFILE_AUTH_PASSWORD;
        props[prop_count].Value.bin.lpb = dataBlobOut.pbData;
        props[prop_count].Value.bin.cb = dataBlobOut.cbData;
        prop_count++;
        DB( (DB_PR _T("ConfigureExchangeService() About to configureMsgService\r\n"),
    this ) );
        hres = lpServiceAdmin->ConfigureMsgService( exchUID, 0, config_flags, prop_count, props
        I still get MAPI_E_NETWORK not found
    Are there any configuration changes need to be done on Exchange Server?
    Is there any mistake in above parameters?
    Kindly suggest.

    You can refer Dave's blog post @
    http://blogs.msdn.com/b/dvespa/archive/2013/05/21/how-to-mfcmapi-create-mapi-profile-exchange-2013.aspx
    DeVa, M.S., {MSFT} Please remember to mark the replies as answers if they help

  • My NetExtender VPN will no longer connect with the Lion upgrade. Can anyone help me?

    My NetExtender VPN will no longer connect since I've upgraded to Lion. Can anyone offer some advice?

    I have not found this to be a solution in my case. I have some Apple OS users, Fedora/Ubuntu users and Windows 7 users who are using the SonicWall client. They can connect to either location in the US fine. Once connected, they receive a DNS search domain of pppFrameEncoded =0; instead of our AD domains which are passed fine in Windows and additionally the correct DNS servers (IP addresses) are listed in preference above the local router IP of the user.
    I found that the correct DNS and routes were listed in the SonicWall client and while could ping the IP of the resource, I could not resolve its hostname with the Network Utility. After manually adding the Search Domains (we have two) in preference and removing the previous above, I was then able to resolve lookups to the FQDN and IP but not the hostname. This really ***** for our Apple users who are mainly execs and use samba connections to shared resources. Strangely enough this also seems to impact the Apple iPad and iPhone 4 I have on iOS 5.1 as well. Any thoughts anyone? Can connect with no error, ping IP, can resolve easily FQDN and can access resources by IP or FQDN but not by hostname.
    172.xxx.xxx.xxx works fine
    smb://hostname.sub.domain.com works fine
    smb://hostname does not but resolves
    Anyone else run into this? It doesn't affect any Windows users at all.

  • Install with no error but, Cmcapp is blank page.. what should i do???

    installed crystalreports server 2008 on windows 2003 server (using IIS and MSSQL database).with no error
    After installing, Im trying to access CMC using link "http://server:8080/CmcApp/logon.faces".
    Im getting the screen to enter login credentials and once I enter the user id and password, the screen goes blank and nothing
    happens.
    I think it relate with IIS..............CMC didnt generate at the IIS application.. how can I generate it into IIS? I just installed it with no
    error
    I made sure that CMS is running. I need help on this. Thanks.
    Edited by: cafielo on Aug 11, 2009 2:07 AM

    aH. I got the . answer..
    i fixed it, through following steps
    Gone to Tools->Internet Options->Security->Local Intranet
    and then added "http://dmt3  "                               (servername :dmt3)
    after that i refreshed my page and then application start running properly.
    my webapps is deployed properly, i checked it
    Thank you very much for your .interest...
    EVerybody Thanks
    Edited by: cafielo on Aug 11, 2009 6:10 PM

  • Whenever i try and open a social network app it comes up with an error message sayinng "Connect to itunes to use Push Notifications" I have successfully conntected to itunes via phone and computer however this message is still appearing and will not go?

    Whenever i try and open a social network app it comes up with an error message sayinng "Connect to itunes to use Push Notifications" I have successfully conntected to itunes via phone and computer however this message is still appearing and will not go, therefore i cannot use the apps?HELP PLEASE

    http://support.apple.com/kb/TS3281

  • Internet Download error message: the connection with the server has been reset

    With an WRT54GS v6 firmware v 1.50.9 on Windows XP SP2 with Internet Explorer 7, Intel wireless internal adaptor w/ 802.11b,  I was getting the error message "The connection with the server has been reset" when downloading most anything from the Internet.  My IP address would then be reset and download would be interrupted.  To resolve, I turned off the WZC (Wireless Zero Configuration) Services, and this seems to correct the problem.
    Control Panel > Admin Tools > Services > Wireless Zero Configuration > Disable
    Hopes this helps.

    Hi!
    Im using Windows 7.... I tried looking for the Wireless Config - but it isn't in the Services options!
    So, what can I do now?
    Thanx

  • Error when i try to connect with blogger from firefox

    when i try to connect with blogger.com and i enter my password the firefox is loading me as it should and then it returns to the blogger page...
    it doesn t say that i put the password wrong it does not say anything its like i m stuck there...i can connect to gmail
    but not to blogger and since the problems occurs only with firefox , as i can connect with other explorers i suppose the problem comes from firefox
    i reinstalled the firefox nothing changes
    also at blogger the firefox crashes in a way that it shows on the top of the page an error instead of the blogger links(connect , new post etc)

    See if this helps you. <br />
    http://support.mozilla.com/en-US/kb/Changing+the+e-mail+program+used+by+Firefox

  • Error while making connection with remote oracle database

    Dear,
    I am trying to make connection with oracle database but when i run java file it's raise an error "classnotfoundexception oracle.jdbc.driver.oracledriver"
    DriverManager.getConnection(
      "jdbc:oracle:thin:@erp:1521:ORCL", "apps",
      "apps");
    Pls any body have idea.
    Thanks.

    Thanks for support.
    Below is error which i am getting while making connection with remote database.
    C:\Program Files\Java\jdk1.7.0_05\bin>java OracleJDBC
    -------- Oracle JDBC Connection Testing ------
    Where is your Oracle JDBC Driver?
    java.lang.ClassNotFoundException: oracle.jdbc.driver.OracleDriver
            at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
            at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
            at java.security.AccessController.doPrivileged(Native Method)
            at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
            at java.lang.ClassLoader.loadClass(ClassLoader.java:423)
            at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
            at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
            at java.lang.Class.forName0(Native Method)
            at java.lang.Class.forName(Class.java:186)
            at OracleJDBC.main(OracleJDBC.java:13)
    Advice.

Maybe you are looking for

  • Ipad 3 won't read photos from sd card

    Tried both inserting card into camera connection and using cable connection from camera.  Neither work.

  • I cannot install creative cloud I get error code 48

    I had tried updating LR to LR6 and I received and error code 48.  I tried everything I saw except for the adobe cleaner.  Including(you guess it) uninstalling CC.  Now what?

  • Mini cd stuck inside the drive

    Hi, New MBP, 6 months old. Accidentally inserted a mini cd inside the drive. Cannt get it out now. Any help will do. Thanks

  • CS4 does not open jpegs it generated itself

    I have just spent half a day preparing jpegs from hires psd's, and I have just found out that the jpegs are all corrupt. When I try to open them, I get a warning message: Could not complete your request because an unknown or invalid jpeg marker type

  • Is it possible to copy message in solman workcenter (Incident Management)?

    Dear all Is it possible to copy message in solman workcenter (Incident Management)? For example, we created a Support Notification (SLFN) message as follows; [ID]                                80007000 [Priority:Text]               3:Medium [Descrip