Questions tagged [oledb]

OLE DB (Object Linking and Embedding, Database, sometimes written as OLEDB or OLE-DB) is an API designed by Microsoft for accessing data from a variety of sources in a uniform manner.

It is a set of interfaces implemented using the Component Object Model (COM); it is otherwise unrelated to OLE. It was designed as a higher-level replacement for, and successor to, ODBC, extending its feature set to support a wider variety of non-relational databases, such as object databases and spreadsheets that do not necessarily implement SQL.

OLE DB separates the data store from the application that needs access to it through a set of abstractions that include the datasource, session, command and rowsets. This was done because different applications need access to different types and sources of data and do not necessarily want to know how to access functionality with technology-specific methods. OLE DB is conceptually divided into consumers and providers. The consumers are the applications that need access to the data, and the provider is the software component that implements the interface and therefore provides the data to the consumer. OLE DB is part of the Microsoft Data Access Components (MDAC) stack. MDAC is a group of Microsoft technologies that interact together as a framework that allows programmers a uniform and comprehensive way of developing applications for accessing almost any data store. OLE DB providers can be created to access such simple data stores as a text file and spreadsheet, through to such complex databases as Oracle, SQL Server and Sybase ASE. It can also provide access to hierarchical datastores such as email systems.

However, because different data store technologies can have different capabilities, OLE DB providers may not implement every possible interface available to OLE DB. The capabilities that are available are implemented through the use of COM objects - an OLE DB provider will map the data store technologies functionality to a particular COM interface. Microsoft describes the availability of an interface as "provider-specific," as it may not be applicable depending on the database technology involved. Note also that providers may augment the capabilities of a data store - these capabilities are known as services in Microsoft parlance.

http://en.wikipedia.org/wiki/OLE_DB

4441 questions
1
vote
1 answer

Why isn't OleDbCommand and OleDbType.Date not working, and no error?

Sorry for the rather lame question... But here is my dilemma... I'm trying to reduce repetitive code as much as possible here, since I have several similar queries, that just vary in parameter counts. Using AccessDB ( I don't have a choice here ).…
Tony Arnold
  • 649
  • 2
  • 7
  • 15
1
vote
7 answers

What is best way to read CSV data?

I am using C# and trying to read a CSV by using this connection string; Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\Documents and Settings\rajesh.yadava\Desktop\orcad;Extended Properties="Text;HDR=YES;IMEX=1;FMT=Delimited" This works for tab…
Rajesh
1
vote
0 answers

Getting records from MS Access

After running my code, it shows this message: At most one record can be returned by this subquery. So, how can I get all the roecords? Here is my code: connection.Open(); OleDbCommand command1 = new OleDbCommand(); …
user5278314
1
vote
1 answer

OleDb Object Invalid or No Longer Set

I'm trying to read an excel file using an OleDb Reader, I couldn't debug the code because this error only comes out on a production server. It really doesn't make sense to me, could anyone help me? From the logs the error comes out…
Jonn
  • 4,599
  • 9
  • 48
  • 68
1
vote
0 answers

Reading Custom column name instead of Value from excel using Oledb

I have Excel Data Like above. Whenever i trying to get the value as 12/1/2015. I used to get 1-Dec,2-Dec etc Like this image bool hasHeaders = true; string HDR = hasHeaders ? "Yes" : "No"; string strConn; if…
vinodh
  • 714
  • 1
  • 7
  • 20
1
vote
1 answer

Access denied when trying to run stored procedure on MS SQL Server

I am getting below error message when I am trying to run stored procedure. Msg 7399, Level 16, State 1, Procedure accountupdater, Line 10 The OLE DB provider "Microsoft.ACE.OLEDB.12.0" for linked server "(null)" reported an error. Access…
1
vote
1 answer

.NET OleDb parameterized query not working as expected

I'm trying to pass this Update command to a database, it completes ok with no errors but it doesnt update the database and I can't understand why? Dim Cmd As OleDbCommand Dim SQL As String Dim objCmd As New OleDbCommand Dim Con =…
LBPLC
  • 1,570
  • 3
  • 27
  • 51
1
vote
1 answer

Error executing update over OLEDB from C#

I am using OLEDB to Update data in .dbf database from c#. I get Error: System.Data.OleDb.OleDbException {"Undefined function 'replace' in expression."} on ExecuteNonQuery. How can I make this work with least changes, i need to replace double quotes…
watbywbarif
  • 6,487
  • 8
  • 50
  • 64
1
vote
1 answer

C# Alter add column on excel with OLEDB

I am trying to add a column in Excel sheet with OLEDB by using ALTER statement. I am not able to do it. I tried with following code but its not working out sqladd = "ALTER TABLE Data ADD NewRow varchar(50)"; Here, Data is the Sheet name in Excel…
1
vote
2 answers

How to add rich text column to Access database table using C# and OleDB?

in an Access database we can set Text Format attribute of a Long Text column to either Plain Text or Rich Text. How can we add a Rich text column to a table programmatically in C# using OleDb API?
mohas
  • 1,911
  • 1
  • 16
  • 20
1
vote
0 answers

if (!IsPostBack) not working with 2nd language

I have 2 tables in my page. I can select between those 2, to choice the language. In my code I have this: public partial class _Default : System.Web.UI.Page { protected void Page_Load(object sender, EventArgs e) { username.Text =…
KikoFHM
  • 122
  • 14
1
vote
1 answer

SSIS - Output a single value from an OLE DB Command and use it on a OLE DB Source

I have a data flow working just fine, it is compound of a source that is evaluated by a lookup component and then it does an upsert, diagram is shown here: Now, on BanqueCIBI (the ole db source), I have a SQL Command Text where I would like to…
Multitut
  • 2,089
  • 7
  • 39
  • 63
1
vote
0 answers

cannot delete, date criteria mismatch vb.net

Im new to vb.net and for some odd reason my delete is not working.It says Data type mismatch in criteria expression. Dim currentRows = DataGridView1.CurrentRow.Index If Not cnn.State = ConnectionState.Open Then cnn.Open() End…
yuyu
  • 9
  • 1
1
vote
1 answer

Reading Excel sheet with OleDb having String, Number and Date fields in the same column

OleDb offers comfortable possibilities to read excel files. One of the limitations for me seem to be the case when a column has different data types not being convertible from a string to other data types unambiguously. An example is a column having…
josh
  • 671
  • 5
  • 10
1
vote
1 answer

Ms Access - System resource exceeded inserting rows

I want to insert 1500 rows to Ms access database from vb.net datagridview. Inserting up to 400 rows no issue, but above 400 rows its showing error - System resource exceeded. Im using below code. The error is highlighting to: readinputs =…
phil_19
  • 105
  • 1
  • 9
1 2 3
99
100