=?Utf-8?B?THVpZ2k=?= <(E-Mail Removed)> wrote in
news:925F1F79-1BF4-41F4-9463-(E-Mail Removed):
> Hi all,
> having a DataReader populater with an Excel file, how can add a column
> with a fixed value to it?
>
> For example, having DbDataReader dr = cmd.ExecuteReader()
>
> I need to add another column to it.
How do you add food coloring to water coming out of a firehose?
Answer: You don't.
A DataReader is a firehose cursor, so much like trying to add food
coloring to water during a fire, you can't add to it.
In short: You cannot add a column to the cursor. You can, however, add
information as you pull records from the cursor.
With a DataSet, you have more options, as you can add a column.
Do you want to know how to add data as you pull from the DataReader?
Peace and Grace,
--
Gregory A. Beamer (MVP)
Twitter: @gbworld
Blog:
http://gregorybeamer.spaces.live.com
*******************************************
| Think outside the box! |
*******************************************