[dba-VB] dba-VB Digest, Vol 54, Issue 28

jwcolby jwcolby at colbyconsulting.com
Tue Apr 29 10:43:45 CDT 2008


 > Yes, that is correct. He is ending up loading the records into memory.
 > Then passing individual updates back for each row of data that he
 > changed.

Yes, and most records have updates.

 > This method is not designed for doing large datasets like he is doing.
 >
 > It should be done on the SQL Server side.

ROTFL.  That is a definite NSS.

Unfortunately I am not a DBA and with the responses I get from the SQL 
group I am not even going there.  I can do this purely in VB.Net (it is 
cranking as we speak) so I will.

 > Just what are you updating...the UPDATE statement you would use to
 > do what you are doing.

No idea.  I thought I could find out from the DA after the command 
builder was finished building the update statement but I am getting an 
error if I try to access the update property.

John W. Colby
www.ColbyConsulting.com


Robert L. Stewart wrote:
> Yes, that is correct. He is ending up loading the records into memory.
> Then passing individual updates back for each row of data that he
> changed.
> 
> This method is not designed for doing large datasets like he is doing.
> 
> It should be done on the SQL Server side.
> 
> 
> John,
> 
> Just what are you updating...the UPDATE statement you would use to
> do what you are doing.
> 
> Robert
> 
> At 09:40 AM 4/29/2008, you wrote:
>> Date: Mon, 28 Apr 2008 17:44:24 -0700
>> From: "Eric Barro" <ebarro at verizon.net>
>> Subject: Re: [dba-VB] vb.net - Updates
>> To: "'Discussion concerning Visual Basic and related programming
>>         issues.'"       <dba-vb at databaseadvisors.com>
>> Message-ID: <0K02006A29SFSYJ0 at vms173005.mailsrvcs.net>
>> Content-Type: text/plain; charset=us-ascii
>>
>> Yeah it is a terrible thing from a DBA point of view because it opens it up
>> to SQL injection attacks since it builds your SQL statement on the fly.
>>
>> I've tried it before and since it is generating it on the fly it makes it
>> all the more harder to debug and offers the least amount of control from a
>> DBA point of view. So...I let SQL server do all the work on the back end
>> when it comes to batch updates by collecting the parameters and sending it
>> to SQL server to process for the records it needs to process.
>>
>> Based on what you are trying to do you are building an image of the data
>> structure in memory, manipulating the data in memory and then committing the
>> changes to the database in memory basically sending the update command for
>> each record to the database back end right? Or am I mistaken in thinking
>> that all of this magically happens by sending a single update command
>> containing several individual update commands strung together?
> 
> 
> _______________________________________________
> dba-VB mailing list
> dba-VB at databaseadvisors.com
> http://databaseadvisors.com/mailman/listinfo/dba-vb
> http://www.databaseadvisors.com
> 
> 



More information about the dba-VB mailing list