Ok, I understand: you named your file *.xls but it is not an Excel file at all, it's just a text file with tab separated values! I was surprised of such a feature from the <sql> task.
dataDriven can currently work with Excel files and properties files but not with text files with tab separated values. If you want, you can extend it for this (I thought that there was a - not applied - patch for csv files but couldn't find it). Cheers, Marc. -- Web: http://www.efficient-webtesting.com Blog: http://mguillem.wordpress.com Hitesh Gupta wrote: > Hi Marc, > > sql task has generated a xls file with data in it and I can open that > file with Microsoft excel. > > I observed that the excel file created by sql task is not a normal excel > file that we create manually through MS Excel. When I opened that excel > and made some changes and try to save then I got a message that "File > may contains features that are not compatible with (Tab delimited). Do > you want to keep the workbook in this format?" > > I think the format of the workbook is different i.e. tab delimited and > because of that only canoo can not read the data from the file. > > But I dont know what to change so as to make canoo able to read the data > from this excel and why sql task has created a xls file in this strange > format. > > If you have any suggestion then please let me know. > > Thanks for your help...!! > > Hitesh > > On Wed, Feb 4, 2009 at 1:58 PM, Marc Guillemot <[email protected] > <mailto:[email protected]>> wrote: > > Hi. > > can the sql task generate an xls file? Is this a valid file that you can > open with Excel? > > Cheers, > Marc. > -- > Web: http://www.efficient-webtesting.com > Blog: http://mguillem.wordpress.com > > Hitesh Gupta wrote: > > Hi All, > > > > I got a strange error, I am creating a excel file through the > below code > > > > <dataDriven container=".config.xls" table="config" filterclass="All"> > > <!--to change the validy date to be > > old--> > > > > <sql > > classpath="${basedir}/../../../../../lib/optional/jconn3-6.0.jar" > > onerror="continue" > > driver="com.sybase.jdbc3.jdbc.SybDriver" > > > url="jdbc:sybase:Tds:${idb_host}:${idb_port}/${idb}" > > userid="${idb_user}" password="${idb_password}" > > print="true" > > autocommit="true" output="passnumber.xls"> > > <![CDATA[ select ord_code from xyz where > > ord_id='412401' ; ]]> > > </sql> > > </dataDriven> > > > > And I found that the passnumber.xls excel sheet is created with > data in it. > > > > Then I want to read the data from the above created excel file > > passnumber.xls through the code:- > > > > <propertytable container="passnumber.xls" filterclass="All"> > > <property name="Order_Code" value="${ord_code}" /> > > > > </propertytable> > > > > During this step I got an error > > "*java.lang.RuntimeException: Cannot read container > >>D:\WebTestHome\resources\Sara\VFMMODebit\tests\scripts\passnumber.xls<: > > Unable to read entire header; 46 bytes read; expected 512 bytes at > > > > org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:115)* > > " > > > > If any one of you how to resolve this error then please let me know. > > > > Thanks in advance for your help..!! > > > > Hitesh > > > > > _______________________________________________ > WebTest mailing list > [email protected] <mailto:[email protected]> > http://lists.canoo.com/mailman/listinfo/webtest > > _______________________________________________ WebTest mailing list [email protected] http://lists.canoo.com/mailman/listinfo/webtest

