How to read files using the OPENDATASOURCE method? I am trying to understand what a particular piece of source code does. The original author has written the following excerpt:
/*******************************************/
-- Inserează în tabela temporară.
/*******************************************/
INSERT INTO #tmp
(
    [tip]
  , [ev]
  , [ap]
  , [cant]
  , [preț]
  , [data]
)
SELECT *
FROM
OPENDATASOURCE
(
    'Microsoft.Jet.OLEDB.4.0'
  , 'Data Source=C:\ETU; Extended Properties=&quot;TEXT; HDR=yes; FMT=DELIMITED&quot;'
)...[EV#csv]

When I am executing this piece of code in SSMS, I get the following error:

Msg 7314, Level 16, State 1, Line 4
The OLE DB provider &quot;Microsoft.Jet.OLEDB.4.0&quot; for linked server &quot;(null)&quot; does not contain the table &quot;EV#csv&quot;. The table either does not exist or the current user does not have permissions on that table.

MSDN shows certain syntaxes for linked servers, but I do not think that the original author meant that.
There is a certain file on the hard disk which full path is C:\ETU\EV20150126000001.csv.
I have attempted to rename the file to the EV#csv new name, yet to no avail.
SELECT @@VERSION says:

Microsoft SQL Server 2008 (SP2) - 10.0.4000.0 (Intel X86)   Sep 16 2010 20:09:22   Copyright (c) 1988-2008 Microsoft Corporation  Express Edition with Advanced Services on Windows NT 5.1  (Build 2600: Service Pack 3)
The Jet.OLEDB.4.0 is data access library for Excel/Access so the code is trying to read data from CSV file into a temporary table. 

If you change the source to OPENDATASOURCE('Microsoft.Jet.OLEDB.4.0', 'Data Source=C:\ETU;Extended Properties="Text;HDR=YES;"')...[etu#csv] you will open c:\etu\etu.csv so changing the last parameter to ...EV20150126000001#csv will open your file. See:http://blog.waynesheffield.com/wayne/code-library/ad-hoc-querying/ As this is a CSV file I would prefer to use openrowset bulk as the Jet.OLEDB drivers are "interesting" on 64bit platforms:  see: http://bradsruminations.blogspot.com/2011/01/ for further ideas.