[Mono-list] ADO and mono

Morten Krog mk@i3m.dk
Wed, 20 Oct 2004 03:06:12 +0200


No it is not redundant. It signals that the returned data is stored in a
datatable named 'Customers'. If you do not supply the name the datatable
is unnamed.

If you used typed datasets (look into the xsd.exe tool) this is even
more useful as you get strongly typed return values from the database.

/Morten Krog

On Wed, 2004-10-20 at 00:44, Eric Damron wrote:
> I have a question about using ADO with mono. I'm reading a book that 
> explains the DataSet and DataAdapter but it doesn't make sense to me.
> 
> The book says that one creates a data Adaptor like this:
> 
> SqlDataAdapter( commandString, connectionString)
> 
> Okay, no problem there. Lets say the command string contains what is 
> suggested in the book:
> 
> “Select CompanyName, ContactName from Customers”
> 
> The book then says you create a DataSet:
> 
> DataSet ds = new DataSet;
> 
> Okay so far. Then the book says to fill the dataset:
> 
> DataAdapter.Fill(ds, “Customers”);
> 
> My question is what is “Customers” about? Isn't it redundant since the 
> SQL statement already specified exactly what was to be returned?
> 
> Thanks
> _______________________________________________
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list