Adding new rows

  • Thread starter Thread starter maz
  • Start date Start date
M

maz

Is there anyway to add rows to a dataset/datatable without having to
populate the object with rows from the source table????

It seems to be pretty daunting in terms of memory/processing
requirements to have to fill the dataset with all rows from a source
and then make additions.
 
No, you don't need to fill it beforhand.
What makes you think you have to fill it before adding new rows?
 
No, you don't need to fill it beforhand.
What makes you think you have to fill it before adding new rows?

--
Miha Markic [MVP C#, INETA Country Leader for Slovenia]
RightHand .NET consulting & developmentwww.rthand.com
Blog:http://cs.rthand.com/blogs/blog_with_righthand/




Is there anyway to add rows to a dataset/datatable without having to
populate the object with rows from the source table????
It seems to be pretty daunting in terms of memory/processing
requirements to have to fill the dataset with all rows from a source
and then make additions.- Hide quoted text -

- Show quoted text -

The examples given in a text I have called the fill method. That's
what made me think so, which I found to be extremely unreasonable!

Note that the table I want to add rows to already has existing rows.

if u have references to web resources that may help please provide
them.

Thanks
 
You can do a schema-only query or construct the DataTable in code and
populated it as needed.

--
____________________________________
William (Bill) Vaughn
Author, Mentor, Consultant, Dad, Grandpa
Microsoft MVP
INETA Speaker
www.betav.com
www.betav.com/blog/billva
Please reply only to the newsgroup so that others can benefit.
This posting is provided "AS IS" with no warranties, and confers no rights.
__________________________________
Visit www.hitchhikerguides.net to get more information on my latest book:
Hitchhiker's Guide to Visual Studio and SQL Server (7th Edition)
and Hitchhiker's Guide to SQL Server 2005 Compact Edition (EBook)
-----------------------------------------------------------------------------------------------------------------------

maz said:
No, you don't need to fill it beforhand.
What makes you think you have to fill it before adding new rows?

--
Miha Markic [MVP C#, INETA Country Leader for Slovenia]
RightHand .NET consulting & developmentwww.rthand.com
Blog:http://cs.rthand.com/blogs/blog_with_righthand/




Is there anyway to add rows to a dataset/datatable without having to
populate the object with rows from the source table????
It seems to be pretty daunting in terms of memory/processing
requirements to have to fill the dataset with all rows from a source
and then make additions.- Hide quoted text -

- Show quoted text -

The examples given in a text I have called the fill method. That's
what made me think so, which I found to be extremely unreasonable!

Note that the table I want to add rows to already has existing rows.

if u have references to web resources that may help please provide
them.

Thanks
 
Back
Top