Dim commandAs Data.OleDb.OleDbCommand =New Data.OleDb.OleDbCommand("Select Cusip,Fundnofeeclass,FundNamewfeeclass,FundDescription FROM [Sheet1$] Select Cusip, FundNoFeeClass,InvestmentName,InvestmentPercentage FROM [Sheet2$]", connection)
Regards,
Karen
Hi Karen,
Yes this is possible! Altough you have to seperate the query statements with a; (a semicollon with a dot or how do you call it? )
Then when you assign the command to an sqlDataReader, you can first touch your 1st resultset, and by calling SqlDataReader.NextResult, you can touch the next resultset and so on.
To view an example of this kind of code you should look here:http://msdn2.microsoft.com/en-us/library/haa3afyz(VS.80).aspx (Using the SQL DataReader).
Scroll down a bit and you will see the examples with the nextresult.
Good luck!
Wim
No comments:
Post a Comment