Advertisement

11.09.2006 at 10:29AM PST, ID: 22055114
[x]
Attachment Details
[x]
The Solution Rating System

With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.

  • The Grade of the Solution
  • The Zone Rank of the Expert Providing the Solution
  • The Number of Author and Expert Comments
  • The Number of Experts Contributing
  • The Feedback of the Community

Your Input Matters
Because of the way the system is set up, the most important variable in this equation is you. As a member of Experts Exchange, you are able to cast your vote on the quality of the solutions in regard to how complete, accurate, helpful and easy to understand each solution is. When you provide your feedback, each rating is adjusted accordingly. So, if you see a solution that has a poor rating that you think is a good solution, let us know by rating it. As you do, the rating will be adjusted and will become more accurate for other members of our site.

If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support.

Thank you!

Update DB using DataSet Modifications

Tags: dataset, modifications, update
Hi,,

Basically, i am currently dumping a specific record from the DB(using a DataAdapter) into a DS... then i'm making changes to the DS manually based on the type of submission from the user, then i'm TRYING to update the database, for that one record, to match the new DS contents. But somehow it gives me an Unhandled Exception Error without further instructions except the stack trace... grrr... anyway... is there a way to update/modify an existing row just by dumping the modified DS into the DA and using Update() ??

Here's my code, it will give you a better idea of what i'm trying to do...

Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
        Dim Conn As New OleDbConnection(ConfigurationSettings.AppSettings("conInterDB"))
        Dim DA As New OleDbDataAdapter("SELECT * FROM Requests WHERE RequestID=" & Request.Form("RequestID"), Conn)
        Dim DS As New DataSet
        Dim row As DataRow
        DA.MissingSchemaAction = MissingSchemaAction.AddWithKey

        DA.Fill(DS, "RS")


        If DS.Tables(0).Rows.Count = 0 Then
            ErrorMsg.Text = "<center><b>Error 5! Could not find specific record to save to!</b></center>"
            DA = Nothing
            DS = Nothing
            Response.End()
        End If

        DS.AcceptChanges()

        If Request.Form("ActionPerf") = "DevSave" Then
            DS.Tables(0).Rows(0).Item("History") = DS.Tables(0).Rows(0).Item("History") & "Saved in Log by " & Session("UN") & " on " & Today.Date & ","
            DS.Tables(0).Rows(0).Item("DevComments") = DS.Tables(0).Rows(0).Item("DevComments") & Request.Form("DevComments")
            DS.Tables(0).Rows(0).Item("WorkFiles") = CInt(DS.Tables(0).Rows(0).Item("WorkFiles")) + CInt(Request.Form("DevDocsSess"))
            DS.Tables(0).Rows(0).Item("WorkTime") = CInt(DS.Tables(0).Rows(0).Item("WorkTime")) + CInt(Request.Form("DevTimeSess"))
            DS.Tables(0).Rows(0).Item("Status") = "Working"
           
        ElseIf Request.Form("ActionPerf") = "WebSave" Then
            DS.Tables(0).Rows(0).Item("History") = DS.Tables(0).Rows(0).Item("History") & "Saved by " & Session("UN") & " on " & Today.Date & ","
            DS.Tables(0).Rows(0).Item("WebComments") = DS.Tables(0).Rows(0).Item("WebComments") & Request.Form("WebComments")
            DS.Tables(0).Rows(0).Item("WebTypeID") = Request.Form("WebType")
            DS.Tables(0).Rows(0).Item("WebSiteID") = Request.Form("WebSites")
            DS.Tables(0).Rows(0).Item("AssignedTo") = Request.Form("Assigning")
            DS.Tables(0).Rows(0).Item("Status") = "Working"

        ElseIf Request.Form("ActionPerf") = "Close" Then
            DS.Tables(0).Rows(0).Item("History") = DS.Tables(0).Rows(0).Item("History") & "Closed by " & Session("UN") & " on " & Today.Date & ","
            DS.Tables(0).Rows(0).Item("WebComments") = DS.Tables(0).Rows(0).Item("WebComments") & Request.Form("WebComments")
            DS.Tables(0).Rows(0).Item("WebTypeID") = Request.Form("WebType")
            DS.Tables(0).Rows(0).Item("WebSiteID") = Request.Form("WebSites")
            DS.Tables(0).Rows(0).Item("AssignedTo") = Request.Form("Assigning")
            DS.Tables(0).Rows(0).Item("Status") = "Closed"

        ElseIf Request.Form("ActionPerf") = "Delete" Then
            DS.Tables(0).Rows(0).Item("History") = DS.Tables(0).Rows(0).Item("History") & "Deleted by " & Session("UN") & " on " & Today.Date & ","
            DS.Tables(0).Rows(0).Item("WebComments") = DS.Tables(0).Rows(0).Item("WebComments") & Request.Form("WebComments")
            DS.Tables(0).Rows(0).Item("WebTypeID") = Request.Form("WebType")
            DS.Tables(0).Rows(0).Item("WebSiteID") = Request.Form("WebSites")
            DS.Tables(0).Rows(0).Item("AssignedTo") = Request.Form("Assigning")
            DS.Tables(0).Rows(0).Item("Status") = "Deleted"

        ElseIf Request.Form("ActionPerf") = "Assign" Then
            DS.Tables(0).Rows(0).Item("History") = DS.Tables(0).Rows(0).Item("History") & "Assigned to " & Request.Form("Assigning") & " by " & Session("UN") & " on " & Today.Date & ","
            DS.Tables(0).Rows(0).Item("WebComments") = DS.Tables(0).Rows(0).Item("WebComments") & Request.Form("WebComments")
            DS.Tables(0).Rows(0).Item("WebType") = Request.Form("WebType")
            DS.Tables(0).Rows(0).Item("WebSite") = Request.Form("WebSites")
            DS.Tables(0).Rows(0).Item("AssignedTo") = Request.Form("Assigning")
            DS.Tables(0).Rows(0).Item("Status") = "Working"

        ElseIf Request.Form("ActionPerf") = "Publish" Then
            DS.Tables(0).Rows(0).Item("History") = DS.Tables(0).Rows(0).Item("History") & "Published by " & Session("UN") & " on " & Today.Date & "," & "Confirmation sent to client"
            DS.Tables(0).Rows(0).Item("WebComments") = DS.Tables(0).Rows(0).Item("WebComments") & Request.Form("WebComments")
            DS.Tables(0).Rows(0).Item("WebTypeID") = Request.Form("WebType")
            DS.Tables(0).Rows(0).Item("WebSiteID") = Request.Form("WebSites")
            DS.Tables(0).Rows(0).Item("AssignedTo") = Request.Form("Assigning")
            DS.Tables(0).Rows(0).Item("Status") = "Completed"

        ElseIf Request.Form("ActionPerf") = "SendQA" Then
            DS.Tables(0).Rows(0).Item("History") = DS.Tables(0).Rows(0).Item("History") & "Sent to QA by " & Session("UN") & " on " & Today.Date & ","
            DS.Tables(0).Rows(0).Item("DevComments") = DS.Tables(0).Rows(0).Item("DevComments") & Request.Form("DevComments")
            DS.Tables(0).Rows(0).Item("OAT") = DS.Tables(0).Rows(0).Item("AssignedTo")
            DS.Tables(0).Rows(0).Item("AssignedTo") = "QA"
            DS.Tables(0).Rows(0).Item("Status") = "Quality Assurance"

        ElseIf Request.Form("ActionPerf") = "QADone" Then
            DS.Tables(0).Rows(0).Item("History") = DS.Tables(0).Rows(0).Item("History") & "QA Completed on " & Today.Date & ","
            DS.Tables(0).Rows(0).Item("DevComments") = DS.Tables(0).Rows(0).Item("DevComments") & Request.Form("DevComments")
            DS.Tables(0).Rows(0).Item("AssignedTo") = "Webmaster"
            DS.Tables(0).Rows(0).Item("Status") = "Publishing"
        End If
       
        DS.AcceptChanges()
        DA.Update(DS)


        'Put user code to initialize the page here

    End Sub
Start your free trial to view this solution
Question Stats
Zone: Programming
Question Asked By: MaxOvrdrv2
Solution Provided By: riyazthad
Participating Experts: 3
Solution Grade: A
Views: 0
Translate:
Loading Advertisement...
11.09.2006 at 10:47AM PST, ID: 17908330

Rank: Sage

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
11.09.2006 at 11:05AM PST, ID: 17908471

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
11.09.2006 at 11:08AM PST, ID: 17908496

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
11.09.2006 at 11:54AM PST, ID: 17908873

Rank: Master

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
11.09.2006 at 12:00PM PST, ID: 17908932

Rank: Master

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
11.09.2006 at 12:09PM PST, ID: 17908998

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
11.09.2006 at 12:18PM PST, ID: 17909075

Rank: Sage

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
11.09.2006 at 12:36PM PST, ID: 17909241

Rank: Master

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
11.09.2006 at 12:41PM PST, ID: 17909285

Rank: Master

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
11.09.2006 at 12:44PM PST, ID: 17909321

Rank: Master

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
11.09.2006 at 04:33PM PST, ID: 17910864

Rank: Wizard

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
11.14.2006 at 04:47AM PST, ID: 17937572

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
11.14.2006 at 04:49AM PST, ID: 17937581

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
11.14.2006 at 04:50AM PST, ID: 17937585

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
11.14.2006 at 04:59AM PST, ID: 17937636

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
11.14.2006 at 05:15AM PST, ID: 17937721

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
11.14.2006 at 05:41AM PST, ID: 17937858

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
11.14.2006 at 06:57AM PST, ID: 17938501

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
11.14.2006 at 09:38AM PST, ID: 17939840

Rank: Master

All comments and solutions are available to Premium Service Members only.

Start your 7-day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
 
Loading Advertisement...
20080236-EE-VQP-29