﻿<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>StrataFrame Forum » StrataFrame Application Framework - V1 » WinForms (How do I?)  » A good Forum for VB Help with data adapters and datasets?</title><generator>InstantForum 2017-1 Final</generator><description>StrataFrame Forum</description><link>http://forum.strataframe.net/</link><webMaster>StrataFrame Forum</webMaster><lastBuildDate>Tue, 09 Jun 2026 09:35:00 GMT</lastBuildDate><ttl>20</ttl><item><title>A good Forum for VB Help with data adapters and datasets?</title><link>http://forum.strataframe.net/FindPost21688.aspx</link><description>This is really not a Strataframe issue. I am trying to save values from an array to a database table. I am not sure if I can use a BO or not but I was trying to write it on my own. I can get it to save one value from the array but not more? If anyone knows where I might post my code and let the Pro's have at it, I would apprecaite it. TIA.&lt;P&gt;Buffie</description><pubDate>Thu, 29 Jan 2009 14:46:42 GMT</pubDate><dc:creator>Terry Bottorff</dc:creator></item><item><title>RE: A good Forum for VB Help with data adapters and datasets?</title><link>http://forum.strataframe.net/FindPost21727.aspx</link><description>That's the kind of thing I was looking for. Thank you.</description><pubDate>Thu, 29 Jan 2009 14:46:42 GMT</pubDate><dc:creator>Terry Bottorff</dc:creator></item><item><title>RE: A good Forum for VB Help with data adapters and datasets?</title><link>http://forum.strataframe.net/FindPost21716.aspx</link><description>Well, you can just add a new row for each array element by enumerating the array.&amp;nbsp; So you may want to create a method on the BO that accepts an array and creates the record:&lt;/P&gt;&lt;P&gt;[codesnippet]Public Sub CreateRecordsByArray(ByVal e As Integer())&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; '-- Place any deletion logic here to remove any undesired records from within the BO or back at the server.&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; '-- Cycle through all of the array rows and add a record for each row&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; For Each i As Integer in e&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Me.NewRow()&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Me.MyField = i&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Next&lt;BR&gt;End Sub[/codesnippet]</description><pubDate>Thu, 29 Jan 2009 10:13:44 GMT</pubDate><dc:creator>Trent L. Taylor</dc:creator></item><item><title>RE: A good Forum for VB Help with data adapters and datasets?</title><link>http://forum.strataframe.net/FindPost21706.aspx</link><description>Yes to both of your questions. 1 row for each array element and delete All data in the table before I start saving the new array data.&lt;/P&gt;&lt;P&gt;TIA.</description><pubDate>Wed, 28 Jan 2009 11:13:06 GMT</pubDate><dc:creator>Terry Bottorff</dc:creator></item><item><title>RE: A good Forum for VB Help with data adapters and datasets?</title><link>http://forum.strataframe.net/FindPost21700.aspx</link><description>Also, when you say that you are trying to save an array to a database, are you wanting to create a new row for each array element or store an array within a single row of a record?&amp;nbsp; This could alter our response as well.</description><pubDate>Wed, 28 Jan 2009 09:29:46 GMT</pubDate><dc:creator>Trent L. Taylor</dc:creator></item><item><title>RE: A good Forum for VB Help with data adapters and datasets?</title><link>http://forum.strataframe.net/FindPost21694.aspx</link><description>So you are bulding the command in .NET via SqlCommandBuilder?&amp;nbsp; What data are you wanting to delete first? The entire existing table in SQL? Any records in the table matching entries in your array? Something else?&lt;/P&gt;&lt;P&gt;Forgive me, I'm a bit slow at times :)</description><pubDate>Tue, 27 Jan 2009 19:04:27 GMT</pubDate><dc:creator>Dustin Taylor</dc:creator></item><item><title>RE: A good Forum for VB Help with data adapters and datasets?</title><link>http://forum.strataframe.net/FindPost21693.aspx</link><description>I'm truly a newbie so I believe that is over kill for what I want. I want to iterate thru and array and write to a table.&amp;nbsp;&lt;/P&gt;&lt;P&gt;By using the command builder I am now able to write the data and the PK to the table. Learned a great deal doing that but now I can not seem to delete the old data &lt;STRONG&gt;just&lt;/STRONG&gt; before I write the new data. Should I be able to use the command builder to do that?&lt;/P&gt;&lt;P&gt;TIA</description><pubDate>Tue, 27 Jan 2009 14:33:38 GMT</pubDate><dc:creator>Terry Bottorff</dc:creator></item><item><title>RE: A good Forum for VB Help with data adapters and datasets?</title><link>http://forum.strataframe.net/FindPost21692.aspx</link><description>We've written a couple of routines in .NET to help with this situation in SQL for our medical appliation. We sometimes need to pass over a dynamically sized list of PKs&amp;nbsp;for&amp;nbsp;use within&amp;nbsp;a SQL sproc. To do that we first convert the list into a binary stream within .NET and pass that stream to the SQL sproc as a VarBinary(MAX) paramater. Once in the sproc, we have a a custom CLR udf that turns the binary stream into a single-column table containing all of the PKs from the list.&amp;nbsp; &lt;/P&gt;&lt;P&gt;So, within the sproc, you just join in the results of the UDF to a select statement to limit the results down to the contents of the list:&lt;/P&gt;&lt;P&gt;[code]SELECT&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;CST.*&lt;BR&gt;FROM Customers AS CST&lt;BR&gt;INNER JOIN dbo.Udf_BytesToPkList(@CustomerPKs) AS&amp;nbsp;CPK ON CST.cst_pk = CPK.pk[/code]&lt;/P&gt;&lt;P&gt;Does that sound like something that would handle your need here?&amp;nbsp;The custom UDF is really the only part of the process that&amp;nbsp;has any&amp;nbsp;complexity at all, and I can go into greater detail there if it sounds like something that can help you out :).</description><pubDate>Tue, 27 Jan 2009 13:53:12 GMT</pubDate><dc:creator>Dustin Taylor</dc:creator></item></channel></rss>