Multiple row deletes in a Smart Object?

  • 7 December 2007
  • 2 replies
  • 1 view

Badge +3

I am trying to delete multiple rows in a smart object, e.g. delete all rows where a certain column=X.  However, the delete method requires that I send it the autonumber key.  I can use a GetList method first, but it only returns a single number (not an array of keys).  Any ideas?


 Thanks.


2 replies

Badge +10

loop through all the records and do 1 at a time thorugh the delete method or if you are using hte ADO.net provider instead of using the delete method you can use your own query like



delete FROM SmartObject Where Column = 'value'


 


Do you have any more context, is this just smartbox or is it a backend system etc?

Badge +3
Thanks for the response.  I am using a smartbox in this case, so I assume the ADO.net provider is out of the question.  Thus I'll probably need to loop through and delete one at a time, although that won't be very efficient.

Reply