sql server compact installed but i can't find the provider - windows-ce

i have sql server compact installed in my computer (version 3.5 and 4)
but i can't find the provider [Microsoft.SQLSERVER.CE.OLEDB.3.5 or] [Microsoft.SQLSERVER.CE.OLEDB.4]
installation : https://drive.google.com/file/d/0B_CGIKuMl3CwR2dNWXhrbkx4Mk0/view?usp=sharing
providers : https://drive.google.com/file/d/0B_CGIKuMl3Cwa2VqUncwdm56aWM/view?usp=sharing
1000 thanks

so
I dont find "Microsoft.SQLSERVER.CE.OLEDB.3.5" in the sql server providers list
or in ODBC providers but if search it with regedit i found it in then key_classes_root so i try to connect with the vb6 program by :
Private Sub Form_Load()
Dim MyConnObj As New ADODB.Connection
MyConnObj.ConnectionString "Provider=Microsoft.SQLSERVER.CE.OLEDB.3.5;Data Source=c:\articles.sdf;"
MyConnObj.Open
End Sub
and it works very well :-)

Related

Informatica workflow(MS SQL SERVER data source and target) fails error RR_4036"Data Source name not found and no default driver specified ."

I have windows 64bit and a Informatica client 32bit installed on it, so I added a DSN entry using the ODBC administrator for 32bit with driver native client "sql server" to connect to a Mssql 2008 R2 database on another pc. I added an entry in system DSN tab because informatica service is using System account. No problems when I have to import source and target in informatica using that ODBC DSN 32 bit "TARGET_DB_sciolto" (see odbc.ini below) entry. I build up my mapping and in the workflow session property than I change the connection from mssql server to ODBC.
The worflow is failing with same RR_4036 error.I think that the only thing I still have to try is to modify my ODBC.ini file since I read that I must add "enablequotedidentifiers=1" so I opened the file expecting to see a lot of entries but I only see following few lines and don't know what to do and would really appreciate if someone would help:
[ODBC 32 bit Data Sources]
test_infa=SQL Server Native Client 10.0 (32 bit)
TARGET_DB_sciolto=SQL Server (32 bit)
Target_DB=SQL Server (32 bit)
[test_infa]
Driver32=C:\WINDOWS\SysWOW64\sqlncli10.dll
[TARGET_DB_sciolto]
Driver32=C:\WINDOWS\system32\SQLSRV32.dll
[Target_DB]
Driver32=C:\WINDOWS\system32\SQLSRV32.dll
You need to set it up using lots of parameters. Please make sure you add the connection info in below format. Pls mention host,port,database at least. also make sure informatica machine has access to the datbase.
[TARGET_DB_sciolto]
Driver32=C:\WINDOWS\system32\SQLSRV32.dll
Description=DataDirect 7.1 SQL Server Wire Protocol
AlternateServers=
AlwaysReportTriggerResults=0
AnsiNPW=1
ApplicationName=
ApplicationUsingThreads=1
AuthenticationMethod=1
BulkBinaryThreshold=32
BulkCharacterThreshold=-1
BulkLoadBatchSize=1024
BulkLoadOptions=2
ConnectionReset=0
ConnectionRetryCount=0
ConnectionRetryDelay=3
Database=<database_name>
EnableBulkLoad=0
EnableQuotedIdentifiers=0
EncryptionMethod=0
FailoverGranularity=0
FailoverMode=0
FailoverPreconnect=0
FetchTSWTZasTimestamp=0
FetchTWFSasTime=1
GSSClient=native
HostName=<SQL_Server_host>
HostNameInCertificate=
InitializationString=
Language=
LoadBalanceTimeout=0
LoadBalancing=0
LoginTimeout=15
LogonID=
MaxPoolSize=100
MinPoolSize=0
PacketSize=-1
Password=
Pooling=0
PortNumber=<SQL_Server_server_port>
QueryTimeout=0
ReportCodePageConversionErrors=0
SnapshotSerializable=0
TrustStore=
TrustStorePassword=
ValidateServerCertificate=1
WorkStationID=
XML Describe Type=-10

What is the method for making an ADODB connection from VBA to a (Google) Cloud SQL database?

Connecting to Cloud SQL appears to be different than connecting to normal MySQL databases.
I have added the 'Instance connection name' after the 'Public IP address'.
I am getting an error:
'Unknown MySQL server host'
Dim Cnn As Object
Set Cnn = CreateObject("ADODB.Connection")
Cnn.Open ("DRIVER={MySQL ODBC 5.3 Unicode Driver};SERVER=xxx.xxx.xxx.xxx\instanceConnectionName;DATABASE=databaseName" & ";USER=user;PASSWORD=abcd")
If Cnn.State = adStateOpen Then
Debug.Print "Connection"
Else
Debug.Print "No Connection"
End If
Cnn.Close
I would recommend to use the SQL Proxy and then for the connection would be like if the database was in your localhost.
So the steps would be:
Install Cloud SQL Proxy in your computer
Start the cloud SQL Proxy
Connect as I f you were connecting to a local database
the code would be:
Dim Cnn As Object
Set Cnn = CreateObject("ADODB.Connection")
Cnn.Open ("DRIVER={MySQL ODBC 5.3 Unicode Driver};SERVER=172.0.0.1;DATABASE=<DATABASENAME>;USER=<USERNAME>;PASSWORD=<PASSWORD>)
If Cnn.State = adStateOpen Then
Debug.Print "Connection"
Else
Debug.Print "No Connection"
End If
Cnn.Close
What kind of DB are you connection to? You can find all kinds of connection strings here.
https://www.connectionstrings.com/
Also, go to your ODBC drivers and see what you have installed. Your code has to match what you have installed. Here is an image of what I have on my system.
So, for instance, you have to have 'MySQL ODBC 5.3 Unicode Driver' installed because that's what you are referencing in your code. Try that and feed back with your findings and results.

Error while creating Sybase Connection from VB

I am trying to connect to Sybase ASE from VB and getting following error
Function createConnection() As ADODB.Connection
Dim ConnectString As String Dim ConnString As String
Set conn = New ADODB.Connection
.Mode = adModeReadWrite
.ConnectionTimeout = 15
.ConnectionString = "Provider=ASEOLEDB;" & _
"Server Name=" & Range("DBServerName") & _
";Initial Catalog=db;" & _
"User Id=user;" & _
"Password=password"
.Open
End With
Set createConnection = conn
End Function
Any help would be much appreciated.
I would suggest you fist to check odbcad as described here.
If you can find any mention of ASEOLEDB there, then you just have problem either with the app using wrong type of drivers (32-bit vs 64-bit) or with a connection string.
But as the error message suggests, you might be missing just the provider - same problem as here. These libraries are usually part of these installations:
SAP/Sybase ASE
SAP/Sybase ASE PC Client CD
SAP/Sybase ASE SDK
All of these can be acquired on SAP portal, however you need a login to that place as this software is accessible only on purchase. You can find here a link of PC Client CD content (Sybase infocenter website) and a manual on OLEDB here.
Unfortunately only freely downloadable ASE is for Linux, which is useless for you. Maybe you can find on that W7 machine installation media ...
Download & Install Provider
http://devzone.advantagedatabase.com/dz/content.aspx?key=20&Release=19&Product=15
use below commands to register provider
regsvr32 sybdrvodb.dll
regsvr32 sybdrvodb64.dll
Details:
http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.infocenter.dc20116.1550/html/aseodbc/aseodbc43.htm

Drivers to connect to an Oracle Database using VBA

I'm trying to connect to an Oracle Database from an Excel application and whithout a DNS. I found on a website that it's possible to use ADO, so this is why I tried to do. I'm new to this so I juste copied what I found on this website.
Here is my code so far :
Sub ADOtest()
Dim connection As New ADODB.connection
connection.ConnectionString = "UID = user1; PWD= my_pwd; DRIVER = {Microsoft ODBC for Oracle; Server= localhost; Database= orcl.my_domain;"
connection.Open
End sub
When I run this code, I get an error saying that the driver was not found.
The problem is that I have no idea of what I have to do with the driver (how to install it and configure it). Plus, I don't know which one I should use : I've read that there is a driver from Microsoft, another one from Oracle and also I've seen something about providers like msdaora.
The program will be used by many users, so I would like to choose the solution that is the lightest (not much to install on computers).
Thank you !
For COM based ADO (ADODB) you can use the OLE DB Providers.
One is from Oracle, called "Oracle Provider for OLE DB". You can download it from 32-bit Oracle Data Access Components (ODAC) and NuGet Downloads (assuming your Excel is 32-bit). The connection string would be
"Provider=OraOLEDB.Oracle;Data Source=orcl;User ID=myUsername;Password=myPassword"
The other one is from Microsoft. Please note, this provider is deprecated, you should not use it for new projects. Usually it should be available on your Windows. Be aware, like the provider from Oracle it also requires an Oracle Client to be installed on the PC! The connection string would be
"Provider=MSDAORA;Data Source=orcl;User ID=myUsername;Password=myPassword"
The data source is usually defined in tnsnames.ora file or at a LDAP server, for example:
orcl.my_domain =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(Host = localhost)(Port = 1521))
(CONNECT_DATA =
(SERVICE_NAME = orcl)
)
)
If you don't have such entry you can put everything into the connection string, e.g.
"Provider=OraOLEDB.Oracle;Data Source=(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(Host=localhost)(Port=1521))(CONNECT_DATA=(SERVICE_NAME=orcl)));User ID=myUsername;Password=myPassword"
Perhaps you have to enclose the data source value by double-quotes ("), I am not sure.
So, in any case you would have to install an Oracle Client at all PC's.
Where is your database server hosted? In your question you say Server=localhost;, this would be quite unlikely, i.e. it is in contradiction to The program will be used by many users. I doubt everybody has an Oracle Database server installed on his local host.

ASP 80004005 error on IIS 7.5

We are trying to run an ASP application on windows 2008 R2 standard (64 bit processor & iis 7.5). ASP application connects to MS Access database. IIS is running fine and Asp is running fine. But when ASP code tries to connect to MS-Access DB, its giving 500 error.
FilePath C:\INETPUB\WWWROOT\XXXXXX\XXXXX_SECTIONS.ASP
LineNumber 14
CurrentStatement LevelTop.Open()
ErrorCode 80004005
Error is coming exactly while opening connection to MS Access DB.
We checked with Process Monitor utility. I have attached the log file of process monitor. We assumed its a permission issue and granted all permissions, but still we are getting same error.
We even tried giving administration group user as IIS user. But still getting same issue.
[Edit]
Ok thanks joel. I am newbie to this environment.
I checked this link and installed this http://www.microsoft.com/downloads/en/details.aspx?FamilyID=C06B8369-60DD-4B64-A44B-84B371EDE16D.
Now I am getting this error
*ErrorCode: 800a0e7a
Description: Provider cannot be found. It may not be properly installed *
this is my connection string
"Provider=Microsoft.ACE.OLEDB.12.0;DBQ=C:\inetpub\wwwroot\xxxxx\App_Data\xxxxx.mdb;Persist Security Info=False;"
Set ThisSection = Server.CreateObject("ADODB.Recordset")
ThisSection.ActiveConnection = ConnectionString
ThisSection.Source = "SELECT * FROM table WHERE ID = " + Replace(ThisSection__MMColParam, "'", "''") + ""
ThisSection.CursorType = 0
ThisSection.CursorLocation = 2
ThisSection.LockType = 1
ThisSection.Open() ->** getting error exactly at this line**
The error message is that the provider cannot be found.
Two sources of this error could be:
Access is not installed
Access 32bit is installed and IIS is looking for the 64bit version, or the other way around
There should be an error in your eventlog.
Also you could try a restart after the installation of the Access driver.

Resources