This OLE DB Provider is provided by Sybase.
Include «Provider=Advantage OLE DB Provider» in the connection string to use this provider.
More info about this provider can be found at the Sybase product page.
Download
This OLE DB Provider, Advantage OLE DB Provider, can be downloaded here.
Connection Strings
The Advantage OLE DB Provider provider can be used to connect to the following data sources by using the following connection string references:
Sybase Advantage
The Advantage OLE DB Provider allows ADO to access data via an Advantage Database Server or Advantage Local Server. The Advantage OLE DB Provider supports the ADO 2.1 specification.
Using the Advantage OLE DB Provider with ADO
The Advantage OLE DB Provider allows ADO to access data via an Advantage Database Server or Advantage Local Server. The Advantage OLE DB Provider supports the ADO 2.1 specification.
Connection String Parameters
To connect to this provider, set the Provider argument of the ConnectionString property to either:
Advantage OLE DB Provider or Advantage.OLEDB.1
Reading the Provider property will return the string:
Advantage.OLEDB.1
Typical Connection String
A typical connection string for the Advantage OLE DB Provider is:
Provider=Advantage OLE DB Provider; Data Source=DatabaseDirectory
Consisting of the following keywords:
Keyword |
Description |
Provider |
Specifies the Advantage OLE DB Provider. |
Data Source |
Specifies the fully qualified database path where the data files exist (for example, x:\data\tables). |
Provider-Specific Connection Parameters
The Advantage OLE DB Provider supports several provider-specific connection parameters in addition to those defined by ADO. As with all other connection parameters, they can be set via the Connection object’s Properties collection or as part of the connection string. Available provider-specific connection parameters are:
Parameter |
Description |
TableType |
Specifies the desired table type. Valid values include ADS_ADT and ADS_CDX. The default is ADS_ADT. |
ServerType |
Specifies the Advantage server types in which to connect. Valid values include ADS_REMOTE_SERVER, ADS_AIS_SERVER, and ADS_LOCAL_SERVER. These values can be logically ORed together with the vertical bar character | in order to choose multiple server types. The default is ADS_REMOTE_SERVER | ADS_AIS_SERVER. If multiple types are specified and multiple server types are available, the order of precedence is ADS_REMOTE_SERVER first, ADS_AIS_SERVER second, and ADS_LOCAL_SERVER third. |
LockMode |
Specifies the locking mode to use. Valid values include ADS_PROPRIETARY_LOCKING and ADS_COMPATIBLE_LOCKING. The default is ADS_PROPRIETARY_LOCKING. |
SecurityMode |
Specifies the security mode to use. Valid values include ADS_CHECKRIGHTS and ADS_IGNORERIGHTS. The default is ADS_CHECKRIGHTS. |
ShowDeleted |
Specifies whether deleted records in DBF tables are visible. Valid values are TRUE or FALSE. This setting is only applicable to the ADS_CDX TableType option. If set to TRUE, deleted records in the DBF table will be visible. The default is FALSE. |
CharType |
Specifies whether the data in the tables is ANSI or OEM. Valid values include ADS_ANSI and ADS_OEM. The default is ADS_ANSI. |
For example, to specify that the provider is to use Advantage Local Server and FoxPro tables, you could use the ADO connection string specified below. Note the provider name can be specified by either its friendly name,Advantage OLE DB Provider, or by it’s official registry name, Advantage.OLEDB.1:
Provider=Advantage OLE DB Provider; Data Source=z:\data\tables; ServerType=ADS_LOCAL_SERVER; TableType=ADS_CDX;
Join the DZone community and get the full member experience.
Join For Free
In one of my projects I have to read FoxPro DBF-files and import data
from them. As this code must run in server and customer doesn’t want to
install FoxPro there we found another solution that seems at least to
me way better. In this posting I will show you how to read DBF-files
using Sybase Advantage data providers.
Getting Advantage data providers
Here are the download links to data providers:
- Advantage .NET Data Provider Release 10.1 for Windows (32-bit and 64-bit)
- Platforms for Advantage OLE DB Provider Release 10.1
- Platforms for Advantage ODBC Driver Release 10.1
I downloaded and installed .NET data provider and my example here is fully based on this.
Configuring application
If you run application without configuring some data providers stuff before you will get the following error:
Error 5185: Local server connections are restricted in this environment. See the 5185 error code documentation for details.
Go to your application bin folder and add there usual text file called ads.ini. Here is the content for this file:
[SETTINGS]
MTIER_LOCAL_CONNECTIONS=1
Make sure you add reference to Advantage data provider assembly and include ads.ini to your project like shown on image above.
Getting data to DataTable
Here is short code example about how to get data from DBF-file to DataTable.
static void Main(string[] args) { var tableName = "TABLENAME_WITHOUT_EXTENSION"; var connStr = "data source={0};tabletype=vfp;servertype= local;"; connStr = string.Format(connStr, "c:\\temp\\"); var table = new DataTable(); using (var conn = new AdsConnection(connStr)) using (var adapter = new AdsDataAdapter()) using (var cmd = new AdsCommand()) { cmd.Connection = conn; cmd.CommandText = "select * from " + tableName; adapter.SelectCommand = cmd; conn.Open(); adapter.Fill(table); conn.Close(); } Console.WriteLine("Table fields:"); foreach (DataColumn col in table.Columns) Console.WriteLine(col.ColumnName); Console.WriteLine(" "); Console.WriteLine("Rows: " + table.Rows.Count); Console.Read(); }
If
Advantage data providers were installed correctly and there are no
errors in table names, locations and your SQL query then you should see
list of table column names and row count on console window when you run
the application.
Data (computing)
Advantage (cryptography)
Database
Published at DZone with permission of Gunnar Peipman, DZone MVB.
See the original article here.
Opinions expressed by DZone contributors are their own.
Related
Published by Sybase, Inc. |
Details
Latest version: | 11.00.0000 |
Location: | C:\Program Files\Advantage 11.0\ |
Install size: | 51.8 KB (53,044 bytes) |
About URL: | http://www.AdvantageDatabase.com |
Help link: | http://www.AdvantageDatabase.com/go/ads/support |
Language: | English (United States) (1033) |
Uninstall: | MsiExec.exe /I{2F24FE76-E5C6-4771-B455-91D57CEC0F54} |
Trust
The trust score is the reputation of Advantage OLE DB Provider based on a number of factors including malware scans, behvaior, uninstall trends and general user experiences.
Poor
Below average
Good
Excellent
Reasons behind trust score
- This app has a very high trust score.
Trends
Trend data unavailable until this program becomes quantified in the next few days.
Technical Details
ads.exe | |
Publisher: | iAnywhere Solutions |
MD5: | 75b661efcdafaddb9ebae356f2cdb7a0 |
ads_cfg.exe | |
Publisher: | iAnywhere, Inc |
MD5: | 784e5aa0d2d40fdc95304327167fa3bf |
adsbackup.exe | |
Publisher: | iAnywhere Solutions, Inc |
Name: | AdsBackup |
MD5: | f3e6aa0ef81e128b9ce69ed09fd0b59b |
adsstamp.exe | |
Publisher: | iAnywhere Solutions |
MD5: | 7df4579f8129f303b44fef542d9eccda |
ADSSupportCapture.exe | |
Publisher: | iAnywhere Solutions |
MD5: | 72639659b6dd1415b6f4a7b07b6a83ed |
adsver.exe | |
MD5: | 881bf314adabd743b24663e0f659ce9e |
aep_tester.exe | |
MD5: | aba05dd4388c46358c1c8ec3916ad296 |
arc32.exe | |
Publisher: | iAnywhere Solutions |
MD5: | b300887e1f6e69125733b33916a5e333 |
asqlcmd.exe | |
Publisher: | iAnywhere Solutions |
MD5: | 50e5bf267fa414c1d84a2fe2684edfa0 |
BLOBIFY.EXE | |
MD5: | 7a3b946108bb0174c8b02368814c8615 |
Build_DCU.exe | |
MD5: | 12a17ce5e6f61f956f7366d6fae0f14a |
Geography of Installations
Installs by Country
Comments for Advantage OLE DB Provider
Other Software
Ошибка открытия ТС:{ВнешняяОбработка.ЗагрузкаДанных.МодульОбъекта(845)}: Ошибка при вызове метода контекста (Open): Произошла исключительная ситуация (ADODB.Connection): Не удается найти указанный поставщик. Вероятно, он установлен неправильно. |
|
Добрый день, Владимир, уточните, пожалуйста, читали ли Вы справку к обработке? |
|
Advantage OLE DB Provider Release 11.1 for Windows 64-bit заново установил Ошибка открытия ТС:{ВнешняяОбработка.ЗагрузкаДанных.МодульОбъекта(845)}: Ошибка при вызове метода контекста (Open): Произошла исключительная ситуация (ADODB.Connection): Не удается найти указанный поставщик. Вероятно, он установлен неправильно |
|
Решил загрузка пошла надо было установить oledb.exe для 32 разрядной Теперь после загрузки документа ругается на метод объекта не обнаружен (ДобавитьКонтактнуюИнформацию) |
|
Владимир, от которого числа обработка загрузки в БП3,0? Изменено: Светлана Сулименко — 14.12.2018 15:29:03 |
|
размер файла 34,0 МБ (35 746 972 байт) |
|
https://yadi.sk/d/hdLLZfuTSx4h9Q
ссылка на файл загрузки в БП 3 |
|
Светлана Сулименко Посетитель Сообщений: 9084 |
#10
19.12.2018 14:32:41 Владимир, обратитесь на alfa@rarus.ru за получением актуальной обработки. |