Lost first row data reading Excel file using FireDAC [Edit]

Hi experts, please help

I used FireDAC connection, FDQuery, DataSource and DBGrid to create a small interface to try out reading an excel file.

ODBCDriver={Microsoft Excel Driver (*.xls, *.xlsx, *.xlsm, *.xlsb)}

The problem is the first row in each worksheet in that excel file is always read as column names (field names). but in my excel example, a lot of the first rows are just data rather than headings.

How do I indicate the FireDAC Connection to read the first row as data, rather than field names?

Thank you.
6/11/2014 6:56:26 PM
embarcadero.delphi.firedac 822 articles. 2 followers. Follow

1 Replies

Similar Articles

[PageSpeed] 56

> The problem is the first row in each worksheet in that excel file is always read as column names (field names). but in my excel example, a lot of the first rows are just data rather than headings.
> How do I indicate the FireDAC Connection to read the first row as data, rather than field names?

Try to add connection parameter:

With best regards,
Dmitry Arefiev / FireDAC Architect
6/13/2014 6:34:53 AM

Similar Artilces:

Can FireDac be used to read *.dbf files (same files used with ShapeFiles)
Hello all, Just wondering if FireDac can be used to access *.dbf file that usually associate with shapefiles? Also, is available for iOS FireDac support? Regards, Bryan Hello Bryan > Just wondering if FireDac can be used to access *.dbf file that usually > associate with shapefiles? If these "dbf" files are standard DBase DB files, then - yes. For that you should use FireDAC Advantage driver: http://docs.embarcadero.com/products/rad_studio/firedac/Connect_to_Advantage_Database_Server.html Most simple will be to use Advantage local engine, which is free for...

Question about Excel reading into Firebird database using FireDAC
Hi Fellas: I have a problem and I need some ideas. I have my application that reads Excel files using ADO to populate Firebird tables. The process is very simple. First, I open the Excel File, after A long "While...Do" where I validate the fields and finally, I put records into the Firebird GDB. The Excel spreadsheet are big: a long record -several column titles- with 60000 rows... My problems are: * Sometimes my apps freezes. I do not know if it's FireDAC or ADO. * I solve the FireDAC part using ArrayDML, but the process with ADO is slow. Even with...

Creating Database Files using Firedac (Delphi XE7)
I have been able to get Firedac to display and edit the following file types in a simple app using FDConnection, FDTable, FDPhysSQLiteDriverLink (and others according to file type) : sdb, gdb, mdb and xls (with ODBC link and drivers). I have been able to create a SQLLite File (.sdb) from scratch and add tables using roughly: FDTable1.Connection = FDConnection1; (set in form) FDConnection1.Params.Clear; FDConnection1.Params.Add('DriverID=SQLite'); FDConnection1.Params.Add('Database='+DATABASE_FILE); FDConnection1.ResourceOptions.DefaultParamType := ptOutput; ...

XE5 Data Exploer for encrypted SQLite files from Firedac? [Edit]
Using XE5 We use aes-256 on sqlite files. But appears Firedac uses a non standard for doing so? Which means I can't seem to open these files in Data Explorer as that uses DBX which can't seem to access these encrypted files. Rebuilt the files with no encryption and worked fine. Any workaround for this? besides building the data twice? takes 3.5 hours to build the data each time. Having problems trying to figure out how to setup the connection in Data Explorer.. the documentation like most else where seems to stink. Basically, is there any data viewer in XE5 that ca...

Reading DataTable to Text file
Hi, I've cobbled a bit of code together to perform an output script to a tab delimited text file. The output seems to be fine, but it chops the top row of the database off, and if there is just one row, that goes, only showing the header. Any ideas? I'm scratching my head here! I know the SQL works fine! Cheers, Barnaby   SqlConnection sqlconnection1 = ConnectionManager.GetProjectConnection(); sqlconnection1.Open(); //creates a new table for the webGIS SqlCommand SqlCommand_table4export = new SqlCommand("SELECT HoleId, SampleType, Ar...

Datasets are read-only, when using FireDAC over TDBX and RDBMS=FIREFIRD [Edit]
Hi, with a simple TFDConnection (DriverID Firebird) and TFDTable, TDatasource and Edit-Components like TDBGrid/TDBField I can change all table values and post updates back to the database. But I want to use a TDBX connection for tunneling all database traffic through a datasnap connection. I've changed the DriverID to TDBX and added the following connection parameters to the connection: DriverName=DataSnap Port=2110 DriverID=TDBX ServerConnection=TServerMethods.getConnection ExtendedMetadata=True RDBMS=FIREBIRD With the RDBMS=FIREBIRD parameter, the table query is very fast...

Trying to read two files using a sub to get the data, but 2nd read on the 2nd file goes to EOF
------_=_NextPart_001_01C73F21.48FF8233 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Here is a snippet of the code: my $MyFileHand; =20 my $MyFileHand1; =20 =20 open($MyFileHand,"<$MyFileIn") || diet (3, $MyFileIn, $!); open($MyFileHand1,"<$MyFileIn1") || diet (3, $MyFileIn1, $!); =20 ............ =20 proc_getrcd( $MyFileHand , $MyEOFProd, $MyWorkp, $MyInp , $GlblInfo{compcnt}, $MyUnpackSw ); proc_getrcd( $MyFileHand1, $MyEOFTest, $MyWorkt, $MyInt , $GlblInf...

How to add or edit first row when dynamically binding data using Gridview.
Hello: I am using Gridview control dynamically binding the data. The databound is from second row. I want to add some titles on the first row. How to add or edit it?   Thanks, \   Customer   You can set the autogenerate columns for edit, delete and update to true and then u can do the modifications. Can you be more specific about ur problem, its a bit vaguekartheek Hello:  I figured it out. Thanks...

Reading data from Excel using data adapter
Hi All, I am reading data from excel sheet and then connecting it with a datagrid. But the problem that I m facing during this is, data grid is not showing all the data of excel sheet(specially dates and numbers). But if I am taking a small range it is showing all data. Can any one give me the solution for this. I m using data adapter and oledb connection for it. Thanks....

How to Save Data grid data as Excel file as read only
 Hi,       I need to Save my data grid data as Excel file that should be read only.Please give the solution.Saran...

deleting a row of data and a file in a folder using File.Delete
I am trying to delete an image file that is in a folder.  The path to that file is in a database field. I have a DetailsView that displays the correct record, including a Label in a Template Field that displays the path (I think I can hide that Label once everything is working, right?). I have read and tried many ways to delete the file and I think the simplest would be to use something like File.Delete(LabelName.Text); but I cannot get it to work.I've added "using System.IO; " to the top of the page and I am trying to use the ItemDeleting Event because I figured that...

Cannot use Microsoft Excel when a Delphi application that uses automat. run [Edit]
Dear all, I built an application that connect to an Excel file using a OleObject: Excel := CreateOleObject('Excel.Application'); LCID := GetUserDefaultLCID; all works fine but I cannot use Microsoft Excel externally when my application is running. If I try to open another xls file, Excel tries to open the file in my Delphi application in read only mode. It does not even show it properly but opens a weir transparent application. I just want to be able to use Excel externally and I'd like the instance opened by my Delphi application to be independent from other Exc...

ADO.net problem: i can not view image data for the rest of my table rows except the image for the first row but i can read all the other non image fields for all rows.
Hi i have a table with the following fields imgid............int imgdata........image imgtitle.........varchar(max) imgType........varchar(max) imgLength.....bigint incident_id.....int i have no problem with uploading the image but viewing the uploaded image(s) in a gridview has caused me great pain. The probelm is i have two pages. page1 grabs the image to display and page2 has a gridview that displays the grabed image. I wanted to have an sql statement like SELECT * FROM mytable WHERE incident_id=someValue. IF i have 5 records in this table and i view page2 ...

How to read data from and Excel File
--0-16043011-1092247360=:90705 Content-Type: text/plain; charset=us-ascii Do I need to have a special module to open/read an Excel spreadsheet, parse it, etc.? I am trying to figure out if one is needed and what module is recommended. I went on CPAN and I saw SQL Parser, but I am not sure if this is best method. Please advise. JC --0-16043011-1092247360=:90705-- Hi there=20 You can check this=20 http://search.cpan.org/~kwitknr/Spreadsheet-ParseExcel-0.2603/ParseExcel ..pm the modules for excell are in Spreadsheet (for the search) -----Original Message----- From:...

Web resources about - Lost first row data reading Excel file using FireDAC [Edit] - embarcadero.delphi.firedac

Sight-reading - Wikipedia, the free encyclopedia
Sight-reading is the reading and performing of a piece of written music , specifically when the performer has not seen it before, also called ...

Raise a Reader: The Advertiser and Sunday Mail launch campaign to champion importance of reading - AdelaideNow ...
THE Advertiser and Sunday Mail have launched a campaign to champion the importance of reading to build a smarter Australia.

Newsela helps students improve their literacy by reading the news
According to the National Assessment of Educational Progress, nearly two thirds of students in the U.S. are not reading at their grade level. ...

Dallas Fed Region Activity Plunges to Lowest Reading Since 2009; Production Collapsed
... that things got worse at a decreasing rate. Dallas Region Collapse The Dallas Fed General Activity Index plunged to -34.6 from a revised reading ...

Weekend Reading: Paul Krugman (1999): Thinking About the Liquidity TRap
**Paul Krugman** (1999): [Thinking about the liquidity trap](http://web.mit.edu/krugman/www/trioshrt.html): >We live in the Age of the Central ...

UKIP former leader criticised for suggesting reading Bible in public may be illegal
A UKIP peer was heavily criticised by bishops and ministers alike for asking if it will be illegal to read the Bible out loud in public.

Apple wants to get better at reading your face
... iPhone may know you, but does it truly understand you? It may get a chance to learn. Apple has purchased a company that specializes in reading ...

Hell Yeah Buddy, It's Time For More Bad NFL Lip Reading
... to come out of the week leading up to the Super Bowl so far is the latest installment of NFL players being subjected to very bad lip-reading ...

Recommended Reading: Will high-tech fighter jets replace pilots?
The Last Fighter Pilot Kevin Gray, Popular Science Forgive us for missing this one during the holiday rush, but Popular Science's look at what ...

Lena Headey Deserves a Rose for Reading 'Bachelor' Insults as Cersei Lannister
Lena Headey Deserves a Rose for Reading 'Bachelor' Insults as Cersei Lannister

Resources last updated: 2/3/2016 10:42:44 PM