Wrox Programmer Forums
Go Back   Wrox Programmer Forums > Visual Basic > VB 6 Visual Basic 6 > Pro VB Databases
|
Pro VB Databases Advanced-level VB coding questions specific to using VB with databases. Beginning-level questions or issues not specific to database use will be redirected to other forums.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Pro VB Databases section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old August 14th, 2003, 02:58 AM
Authorized User
 
Join Date: Jul 2003
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Default Critical Problem in accessing ODBC From XP

Dear friends,

       I m facing a strange problem but it's like an old problem.
The problem is I m Installing my application on XP systems. My specification are

Product Developed in : Visual Basic 6.0

Database : Oracle 9i(Running on Windows 2000 server)

when i developed my product i used MDAC supplied bydeafault with VB. Now it has been upgraded to MDAC2.7 which would be installed with XP OS.

When i m trying to access my database from an XP system i m getting an error.

My code is

dim Cn as new Adodb.Connection
Cn.open "Proider=MSDASQL;DSN=MYDSN;UID=MYUSER;PWD=MYPA SS"

I tried another way also

Cn.open "Proider=MSDAORA;Data Source=MYDSN;User name=MYUSER;Password=MYPASS"


But I m prompted with the following error

[Microsoft][ODBC For Oracle][Oracle]

This the error.and i created System DSN.

Some XP systems are working fine with the above code,
And some systems are not able to connect.

If any body can help me on this problem.It would be a great help to me.

Thanking you all in advance.

Veerendrakumar


B.V.Kumar
__________________
B.V.Kumar
 
Old August 21st, 2003, 03:46 PM
Ned Ned is offline
Authorized User
 
Join Date: Jun 2003
Posts: 66
Thanks: 0
Thanked 0 Times in 0 Posts
Default

You can use
cn.open "DSN=mydsn;"
When you create a DSN, it includes everything like provider, database etc. You can also use like that
cn.open "DSN=mydsn;uid=sa;pwd=sa-password;"

Cheers,

-Ned
 
Old June 12th, 2004, 12:12 AM
Registered User
 
Join Date: Jun 2004
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi

I encountered similar problem as bveerendrakumar, and i'm already using "DSN=mydsn;uid=sa;pwd=sa-password;" as the connection string.

The strangest thing is that it works fine on some xp machines and not in some. Can this be somekind of security level which causes this ODBC - call fail problem?








Similar Threads
Thread Thread Starter Forum Replies Last Post
Javascript Critical Section ? tal Javascript How-To 1 April 11th, 2008 04:39 PM
critical problem s_a_ravi Classic ASP Basics 1 August 28th, 2005 06:13 PM
ODBC - insert on a linked field - [microsoft][ODBC chimp MySQL 0 April 7th, 2005 04:44 AM
Critical Query ps_kaushik Access 1 March 15th, 2005 12:54 PM
Critical problem in Biztalk server Bala chandra Sekhar Biztalk 1 November 12th, 2003 05:30 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.