I have been trying to update a record that I edited and can't seem to figure
out what I'm missing. Here is the code that I have to load the record on
the form:
'
************************************************** **************************
*****************
Private Sub ContactMain_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load
Dim strSQL As String
strSQL = "Select * from Contact WHERE sysID = '" & g_sysID & "'"
objDS.Clear()
Dim cmb As SqlClient.SqlCommandBuilder = New
SqlClient.SqlCommandBuilder(DA)
Dim selectCommand As New SqlClient.SqlCommand(strSQL)
DA.SelectCommand = selectCommand
DA.SelectCommand.Connection = CN
DA.Fill(objDS, "Contact")
Me.txtFirstName.DataBindings.Add("Text", objDS,
"Contact.first_name")
Me.txtLastName.DataBindings.Add("Text", objDS, "Contact.Last_name")
Me.txtFullName.DataBindings.Add("Text", objDS, "Contact.full_name")
Me.txtAddress1.DataBindings.Add("Text", objDS, "Contact.con1_02_03")
Me.txtPhone.DataBindings.Add("Text", objDS, "Contact.Phone1")
Me.txtCity.DataBindings.Add("Text", objDS, "Contact.con1_02_05")
Me.txtState.DataBindings.Add("Text", objDS, "Contact.con1_02_06")
Me.txtZip.DataBindings.Add("Text", objDS, "Contact.con1_02_07")
Me.txtEMail.DataBindings.Add("Text", objDS, "Contact.con1_03_01")
End Sub
And here is the code for the update:
'
************************************************** **************************
*****************
Private Sub btnSave_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles btnSave.Click
Try
DirectCast(BindingContext(objDS.Tables(0)),
CurrencyManager).EndCurrentEdit()
Me.Close()
Catch ex As Exception
MsgBox(ex.Message)
End Try
End Sub
What am I missing? Do I need to code the INSERT, UPDATE, and DELETE command
and if so, where do I put them? I have nine fields that I'm working with so
please help me update my record. Any code examples would be appreciated.
Thanks,
Gary 22 1578
Hi Gary,
Where did you let that special code, that should work, although it is not
standard, I did find it very nice to check concurrency errors.
However change it in this what is standard used in this newsgroups and in
samples.
Private Sub btnSave_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles btnSave.Click
BindingContext(objDS.Tables(0)).EndCurrentEdit()
Try
if objDS.haschanges then
Da.update(objDS)
end if
Catch ex As Exception
MsgBox(ex.Message)
End Try
End Sub
Cor
Hi Gary,
Where did you let that special code, that should work, although it is not
standard, I did find it very nice to check concurrency errors.
However change it in this what is standard used in this newsgroups and in
samples.
Private Sub btnSave_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles btnSave.Click
BindingContext(objDS.Tables(0)).EndCurrentEdit()
Try
if objDS.haschanges then
Da.update(objDS)
end if
Catch ex As Exception
MsgBox(ex.Message)
End Try
End Sub
Cor
Hi Cor,
I tried the code you suggested and I get the following error message:
Update unable to find TableMapping['Table'] or Datatable 'Table'
Any suggestions?
Thanks,
Gary
"Cor Ligthert" <no**********@planet.nl> wrote in message
news:Oq**************@TK2MSFTNGP12.phx.gbl... Hi Gary,
Where did you let that special code, that should work, although it is not standard, I did find it very nice to check concurrency errors.
However change it in this what is standard used in this newsgroups and in samples.
Private Sub btnSave_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnSave.Click BindingContext(objDS.Tables(0)).EndCurrentEdit() Try if objDS.haschanges then Da.update(objDS) end if Catch ex As Exception MsgBox(ex.Message) End Try End Sub
Cor
Hi Cor,
I tried the code you suggested and I get the following error message:
Update unable to find TableMapping['Table'] or Datatable 'Table'
Any suggestions?
Thanks,
Gary
"Cor Ligthert" <no**********@planet.nl> wrote in message
news:Oq**************@TK2MSFTNGP12.phx.gbl... Hi Gary,
Where did you let that special code, that should work, although it is not standard, I did find it very nice to check concurrency errors.
However change it in this what is standard used in this newsgroups and in samples.
Private Sub btnSave_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnSave.Click BindingContext(objDS.Tables(0)).EndCurrentEdit() Try if objDS.haschanges then Da.update(objDS) end if Catch ex As Exception MsgBox(ex.Message) End Try End Sub
Cor
Cor,
I just tried the following change (Putting the table name 'Contact' in) and
I received an error saying "Incorrect syntax near the word 'trigger'".
HELP! Do I need to specify UPDATE statements? If so where EXACTLY do I put
them?
Gary
Private Sub btnSave_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles btnSave.Click
BindingContext(objDS.Tables("Contact")).EndCurrent Edit()
Try
If objDS.HasChanges Then
DA.Update(objDS, "Contact")
End If
Me.Close()
Catch ex As Exception
MsgBox(ex.Message)
End Try
End Sub
"Cor Ligthert" <no**********@planet.nl> wrote in message
news:Oq**************@TK2MSFTNGP12.phx.gbl... Hi Gary,
Where did you let that special code, that should work, although it is not standard, I did find it very nice to check concurrency errors.
However change it in this what is standard used in this newsgroups and in samples.
Private Sub btnSave_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnSave.Click BindingContext(objDS.Tables(0)).EndCurrentEdit() Try if objDS.haschanges then Da.update(objDS) end if Catch ex As Exception MsgBox(ex.Message) End Try End Sub
Cor
Cor,
I just tried the following change (Putting the table name 'Contact' in) and
I received an error saying "Incorrect syntax near the word 'trigger'".
HELP! Do I need to specify UPDATE statements? If so where EXACTLY do I put
them?
Gary
Private Sub btnSave_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles btnSave.Click
BindingContext(objDS.Tables("Contact")).EndCurrent Edit()
Try
If objDS.HasChanges Then
DA.Update(objDS, "Contact")
End If
Me.Close()
Catch ex As Exception
MsgBox(ex.Message)
End Try
End Sub
"Cor Ligthert" <no**********@planet.nl> wrote in message
news:Oq**************@TK2MSFTNGP12.phx.gbl... Hi Gary,
Where did you let that special code, that should work, although it is not standard, I did find it very nice to check concurrency errors.
However change it in this what is standard used in this newsgroups and in samples.
Private Sub btnSave_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnSave.Click BindingContext(objDS.Tables(0)).EndCurrentEdit() Try if objDS.haschanges then Da.update(objDS) end if Catch ex As Exception MsgBox(ex.Message) End Try End Sub
Cor
Hi Gary,
As forever I do not want to change to much in peoples code.
This is your code, how can that commandbuilder build commands if he does not
know nothing about what he has to build. Replace the commandbuilder to the
place where it has all information.
(Before the fill)
This did cost time to see this.
And others place it direct for the update, which I messaged you before last
week.
Cor
strSQL = "Select * from Contact WHERE sysID = '" & g_sysID & "'"
objDS.Clear()
Dim cmb As SqlClient.SqlCommandBuilder = New
SqlClient.SqlCommandBuilder(DA)
Dim selectCommand As New SqlClient.SqlCommand(strSQL)
DA.SelectCommand = selectCommand
DA.SelectCommand.Connection = CN
DA.Fill(objDS, "Contact")
Hi Gary,
As forever I do not want to change to much in peoples code.
This is your code, how can that commandbuilder build commands if he does not
know nothing about what he has to build. Replace the commandbuilder to the
place where it has all information.
(Before the fill)
This did cost time to see this.
And others place it direct for the update, which I messaged you before last
week.
Cor
strSQL = "Select * from Contact WHERE sysID = '" & g_sysID & "'"
objDS.Clear()
Dim cmb As SqlClient.SqlCommandBuilder = New
SqlClient.SqlCommandBuilder(DA)
Dim selectCommand As New SqlClient.SqlCommand(strSQL)
DA.SelectCommand = selectCommand
DA.SelectCommand.Connection = CN
DA.Fill(objDS, "Contact")
Hi Cor,
I did go back and look at the messages from the other day and I just don't
see what else I need to do. I'm sorry but I don't understand. I did place
the CommandBuilder before the fill as you requested. I don't understand the
"Replace the commandbuilder to the place where it has all the information"
line. To me it is already there. Can you elaborate more or give me a
better example of what I have to do? I am lost.
Thanks,
Gary
"Cor Ligthert" <no**********@planet.nl> wrote in message
news:O2*************@TK2MSFTNGP09.phx.gbl... Hi Gary,
As forever I do not want to change to much in peoples code.
This is your code, how can that commandbuilder build commands if he does
not know nothing about what he has to build. Replace the commandbuilder to
the place where it has all information. (Before the fill)
This did cost time to see this.
And others place it direct for the update, which I messaged you before
last week.
Cor
strSQL = "Select * from Contact WHERE sysID = '" & g_sysID & "'" objDS.Clear()
Dim cmb As SqlClient.SqlCommandBuilder = New SqlClient.SqlCommandBuilder(DA) Dim selectCommand As New SqlClient.SqlCommand(strSQL) DA.SelectCommand = selectCommand DA.SelectCommand.Connection = CN
DA.Fill(objDS, "Contact")
Hi Cor,
I did go back and look at the messages from the other day and I just don't
see what else I need to do. I'm sorry but I don't understand. I did place
the CommandBuilder before the fill as you requested. I don't understand the
"Replace the commandbuilder to the place where it has all the information"
line. To me it is already there. Can you elaborate more or give me a
better example of what I have to do? I am lost.
Thanks,
Gary
"Cor Ligthert" <no**********@planet.nl> wrote in message
news:O2*************@TK2MSFTNGP09.phx.gbl... Hi Gary,
As forever I do not want to change to much in peoples code.
This is your code, how can that commandbuilder build commands if he does
not know nothing about what he has to build. Replace the commandbuilder to
the place where it has all information. (Before the fill)
This did cost time to see this.
And others place it direct for the update, which I messaged you before
last week.
Cor
strSQL = "Select * from Contact WHERE sysID = '" & g_sysID & "'" objDS.Clear()
Dim cmb As SqlClient.SqlCommandBuilder = New SqlClient.SqlCommandBuilder(DA) Dim selectCommand As New SqlClient.SqlCommand(strSQL) DA.SelectCommand = selectCommand DA.SelectCommand.Connection = CN
DA.Fill(objDS, "Contact")
Hi Gary,
It should work now, I do not look anymore to this newsgroup today, (It is
here 20:00 saterday night, however I was curious if you did succeed)
However past in that part of code from the fill and from the update, I
really do not know why it should not work
Before I did send the message some days ago I tested it with your previous
methode completly and now with that new methode I did test it also.
I look to it what is here tomorrow morning, there should be something very
simple what is on the wrong place.
Cor
Hi Gary,
It should work now, I do not look anymore to this newsgroup today, (It is
here 20:00 saterday night, however I was curious if you did succeed)
However past in that part of code from the fill and from the update, I
really do not know why it should not work
Before I did send the message some days ago I tested it with your previous
methode completly and now with that new methode I did test it also.
I look to it what is here tomorrow morning, there should be something very
simple what is on the wrong place.
Cor
Gary:
1) Do yourself a favor and get rid of the concatenated sql, opt for
Paramaterized queries instead. It's not the problem you are asking about,
but it can introduce some really really bad security problems, not to
mention performance issues.
strSQL = "Select * from Contact WHERE sysID = @g_sysID"
cmd.Parameters.Add("@g_sysID", SqlDbType.WhateverType,
FieldLengthInDb).value = g_sysID
2) The commandbuilder should genereate these for you (Update, Delete etc)
but CB's really suck. The problem is that you aren't calling update that I
can see. In your btn_Save code, add DA.Update(objDS1, "TableName")
That should fix it for you.
Let me know if not.
Bill
"Gary" <ra******@yahoo.com> wrote in message
news:%2******************@tk2msftngp13.phx.gbl... I have been trying to update a record that I edited and can't seem to
figure out what I'm missing. Here is the code that I have to load the record on the form:
'
************************************************** ************************** ***************** Private Sub ContactMain_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim strSQL As String
strSQL = "Select * from Contact WHERE sysID = '" & g_sysID & "'" objDS.Clear()
Dim cmb As SqlClient.SqlCommandBuilder = New SqlClient.SqlCommandBuilder(DA) Dim selectCommand As New SqlClient.SqlCommand(strSQL) DA.SelectCommand = selectCommand DA.SelectCommand.Connection = CN
DA.Fill(objDS, "Contact")
Me.txtFirstName.DataBindings.Add("Text", objDS, "Contact.first_name") Me.txtLastName.DataBindings.Add("Text", objDS,
"Contact.Last_name") Me.txtFullName.DataBindings.Add("Text", objDS,
"Contact.full_name") Me.txtAddress1.DataBindings.Add("Text", objDS,
"Contact.con1_02_03") Me.txtPhone.DataBindings.Add("Text", objDS, "Contact.Phone1") Me.txtCity.DataBindings.Add("Text", objDS, "Contact.con1_02_05") Me.txtState.DataBindings.Add("Text", objDS, "Contact.con1_02_06") Me.txtZip.DataBindings.Add("Text", objDS, "Contact.con1_02_07") Me.txtEMail.DataBindings.Add("Text", objDS, "Contact.con1_03_01")
End Sub
And here is the code for the update:
'
************************************************** ************************** ***************** Private Sub btnSave_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnSave.Click
Try DirectCast(BindingContext(objDS.Tables(0)), CurrencyManager).EndCurrentEdit() Me.Close()
Catch ex As Exception
MsgBox(ex.Message)
End Try
End Sub
What am I missing? Do I need to code the INSERT, UPDATE, and DELETE
command and if so, where do I put them? I have nine fields that I'm working with
so please help me update my record. Any code examples would be appreciated.
Thanks,
Gary
Gary:
1) Do yourself a favor and get rid of the concatenated sql, opt for
Paramaterized queries instead. It's not the problem you are asking about,
but it can introduce some really really bad security problems, not to
mention performance issues.
strSQL = "Select * from Contact WHERE sysID = @g_sysID"
cmd.Parameters.Add("@g_sysID", SqlDbType.WhateverType,
FieldLengthInDb).value = g_sysID
2) The commandbuilder should genereate these for you (Update, Delete etc)
but CB's really suck. The problem is that you aren't calling update that I
can see. In your btn_Save code, add DA.Update(objDS1, "TableName")
That should fix it for you.
Let me know if not.
Bill
"Gary" <ra******@yahoo.com> wrote in message
news:%2******************@tk2msftngp13.phx.gbl... I have been trying to update a record that I edited and can't seem to
figure out what I'm missing. Here is the code that I have to load the record on the form:
'
************************************************** ************************** ***************** Private Sub ContactMain_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim strSQL As String
strSQL = "Select * from Contact WHERE sysID = '" & g_sysID & "'" objDS.Clear()
Dim cmb As SqlClient.SqlCommandBuilder = New SqlClient.SqlCommandBuilder(DA) Dim selectCommand As New SqlClient.SqlCommand(strSQL) DA.SelectCommand = selectCommand DA.SelectCommand.Connection = CN
DA.Fill(objDS, "Contact")
Me.txtFirstName.DataBindings.Add("Text", objDS, "Contact.first_name") Me.txtLastName.DataBindings.Add("Text", objDS,
"Contact.Last_name") Me.txtFullName.DataBindings.Add("Text", objDS,
"Contact.full_name") Me.txtAddress1.DataBindings.Add("Text", objDS,
"Contact.con1_02_03") Me.txtPhone.DataBindings.Add("Text", objDS, "Contact.Phone1") Me.txtCity.DataBindings.Add("Text", objDS, "Contact.con1_02_05") Me.txtState.DataBindings.Add("Text", objDS, "Contact.con1_02_06") Me.txtZip.DataBindings.Add("Text", objDS, "Contact.con1_02_07") Me.txtEMail.DataBindings.Add("Text", objDS, "Contact.con1_03_01")
End Sub
And here is the code for the update:
'
************************************************** ************************** ***************** Private Sub btnSave_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnSave.Click
Try DirectCast(BindingContext(objDS.Tables(0)), CurrencyManager).EndCurrentEdit() Me.Close()
Catch ex As Exception
MsgBox(ex.Message)
End Try
End Sub
What am I missing? Do I need to code the INSERT, UPDATE, and DELETE
command and if so, where do I put them? I have nine fields that I'm working with
so please help me update my record. Any code examples would be appreciated.
Thanks,
Gary
Apologies for butting in, but just trying to clarify one of Cor's points -
The CommandBuilder cannot function correctly unless it knows what the select
command for the adapter is. The help file example looks like this...
Public Function SelectSqlSrvRows(myDataSet As DataSet, myConnection As
String, mySelectQuery As String, myTableName As String) As DataSet
Dim myConn As New SqlConnection(myConnection)
Dim myDataAdapter As New SqlDataAdapter()
myDataAdapter.SelectCommand = New SqlCommand(mySelectQuery, myConn)
Dim custCB As SqlCommandBuilder = New SqlCommandBuilder(myDataAdapter)
..
..
..
i.e. the select command (and, incidentally, the connection) is set up before
using the CommandBuilder.
"Gary" <ra******@yahoo.com> wrote in message
news:eZ**************@TK2MSFTNGP12.phx.gbl... Hi Cor,
I did go back and look at the messages from the other day and I just don't see what else I need to do. I'm sorry but I don't understand. I did
place the CommandBuilder before the fill as you requested. I don't understand
the "Replace the commandbuilder to the place where it has all the information" line. To me it is already there. Can you elaborate more or give me a better example of what I have to do? I am lost.
Thanks,
Gary
"Cor Ligthert" <no**********@planet.nl> wrote in message news:O2*************@TK2MSFTNGP09.phx.gbl... Hi Gary,
As forever I do not want to change to much in peoples code.
This is your code, how can that commandbuilder build commands if he does not know nothing about what he has to build. Replace the commandbuilder to the place where it has all information. (Before the fill)
This did cost time to see this.
And others place it direct for the update, which I messaged you before last week.
Cor
strSQL = "Select * from Contact WHERE sysID = '" & g_sysID & "'" objDS.Clear()
Dim cmb As SqlClient.SqlCommandBuilder = New SqlClient.SqlCommandBuilder(DA) Dim selectCommand As New SqlClient.SqlCommand(strSQL) DA.SelectCommand = selectCommand DA.SelectCommand.Connection = CN
DA.Fill(objDS, "Contact")
Apologies for butting in, but just trying to clarify one of Cor's points -
The CommandBuilder cannot function correctly unless it knows what the select
command for the adapter is. The help file example looks like this...
Public Function SelectSqlSrvRows(myDataSet As DataSet, myConnection As
String, mySelectQuery As String, myTableName As String) As DataSet
Dim myConn As New SqlConnection(myConnection)
Dim myDataAdapter As New SqlDataAdapter()
myDataAdapter.SelectCommand = New SqlCommand(mySelectQuery, myConn)
Dim custCB As SqlCommandBuilder = New SqlCommandBuilder(myDataAdapter)
..
..
..
i.e. the select command (and, incidentally, the connection) is set up before
using the CommandBuilder.
"Gary" <ra******@yahoo.com> wrote in message
news:eZ**************@TK2MSFTNGP12.phx.gbl... Hi Cor,
I did go back and look at the messages from the other day and I just don't see what else I need to do. I'm sorry but I don't understand. I did
place the CommandBuilder before the fill as you requested. I don't understand
the "Replace the commandbuilder to the place where it has all the information" line. To me it is already there. Can you elaborate more or give me a better example of what I have to do? I am lost.
Thanks,
Gary
"Cor Ligthert" <no**********@planet.nl> wrote in message news:O2*************@TK2MSFTNGP09.phx.gbl... Hi Gary,
As forever I do not want to change to much in peoples code.
This is your code, how can that commandbuilder build commands if he does not know nothing about what he has to build. Replace the commandbuilder to the place where it has all information. (Before the fill)
This did cost time to see this.
And others place it direct for the update, which I messaged you before last week.
Cor
strSQL = "Select * from Contact WHERE sysID = '" & g_sysID & "'" objDS.Clear()
Dim cmb As SqlClient.SqlCommandBuilder = New SqlClient.SqlCommandBuilder(DA) Dim selectCommand As New SqlClient.SqlCommand(strSQL) DA.SelectCommand = selectCommand DA.SelectCommand.Connection = CN
DA.Fill(objDS, "Contact")
Thanks for giving me an example, but here is my code and it works bringing
in the record but I'm not sure it's correct
Private Sub ContactMain_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load
Dim strSQL As String
strSQL = "Select * from Contact WHERE sysID = '" & g_sysID & "'"
objDS.Clear()
Dim selectCommand As New SqlClient.SqlCommand(strSQL)
DA.SelectCommand = selectCommand
DA.SelectCommand.Connection = CN
Dim cmb As SqlClient.SqlCommandBuilder = New
SqlClient.SqlCommandBuilder(DA)
DA.Fill(objDS, "Contact")
Me.txtFirstName.DataBindings.Add("Text", objDS,
"Contact.first_name")
Me.txtLastName.DataBindings.Add("Text", objDS, "Contact.Last_name")
Me.txtFullName.DataBindings.Add("Text", objDS, "Contact.full_name")
Me.txtAddress1.DataBindings.Add("Text", objDS, "Contact.con1_02_03")
Me.txtPhone.DataBindings.Add("Text", objDS, "Contact.Phone1")
Me.txtCity.DataBindings.Add("Text", objDS, "Contact.con1_02_05")
Me.txtState.DataBindings.Add("Text", objDS, "Contact.con1_02_06")
Me.txtZip.DataBindings.Add("Text", objDS, "Contact.con1_02_07")
Me.txtEMail.DataBindings.Add("Text", objDS, "Contact.con1_03_01")
End Sub
When I want to update, I have the following code:
Private Sub btnSave_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles btnSave.Click
BindingContext(objDS.Tables("Contact")).EndCurrent Edit()
Try
If objDS.HasChanges Then
DA.Update(objDS, "Contact")
End If
Me.Close()
Catch ex As Exception
MsgBox(ex.Message)
End Try
End Sub
but the above code doesn't work. HELP
"Rob Oldfield" <rob@oldfield100_wow_freeserve_yikes_co_incredible !_uk> wrote
in message news:%2******************@TK2MSFTNGP09.phx.gbl... Apologies for butting in, but just trying to clarify one of Cor's points -
The CommandBuilder cannot function correctly unless it knows what the
select command for the adapter is. The help file example looks like this...
Public Function SelectSqlSrvRows(myDataSet As DataSet, myConnection As String, mySelectQuery As String, myTableName As String) As DataSet Dim myConn As New SqlConnection(myConnection) Dim myDataAdapter As New SqlDataAdapter() myDataAdapter.SelectCommand = New SqlCommand(mySelectQuery, myConn) Dim custCB As SqlCommandBuilder = New SqlCommandBuilder(myDataAdapter) . . . i.e. the select command (and, incidentally, the connection) is set up
before using the CommandBuilder. "Gary" <ra******@yahoo.com> wrote in message news:eZ**************@TK2MSFTNGP12.phx.gbl... Hi Cor,
I did go back and look at the messages from the other day and I just
don't see what else I need to do. I'm sorry but I don't understand. I did place the CommandBuilder before the fill as you requested. I don't understand the "Replace the commandbuilder to the place where it has all the
information" line. To me it is already there. Can you elaborate more or give me a better example of what I have to do? I am lost.
Thanks,
Gary
"Cor Ligthert" <no**********@planet.nl> wrote in message news:O2*************@TK2MSFTNGP09.phx.gbl... Hi Gary,
As forever I do not want to change to much in peoples code.
This is your code, how can that commandbuilder build commands if he
does not know nothing about what he has to build. Replace the commandbuilder
to the place where it has all information. (Before the fill)
This did cost time to see this.
And others place it direct for the update, which I messaged you before last week.
Cor
strSQL = "Select * from Contact WHERE sysID = '" & g_sysID & "'" objDS.Clear()
Dim cmb As SqlClient.SqlCommandBuilder = New SqlClient.SqlCommandBuilder(DA) Dim selectCommand As New SqlClient.SqlCommand(strSQL) DA.SelectCommand = selectCommand DA.SelectCommand.Connection = CN
DA.Fill(objDS, "Contact")
Thanks for giving me an example, but here is my code and it works bringing
in the record but I'm not sure it's correct
Private Sub ContactMain_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load
Dim strSQL As String
strSQL = "Select * from Contact WHERE sysID = '" & g_sysID & "'"
objDS.Clear()
Dim selectCommand As New SqlClient.SqlCommand(strSQL)
DA.SelectCommand = selectCommand
DA.SelectCommand.Connection = CN
Dim cmb As SqlClient.SqlCommandBuilder = New
SqlClient.SqlCommandBuilder(DA)
DA.Fill(objDS, "Contact")
Me.txtFirstName.DataBindings.Add("Text", objDS,
"Contact.first_name")
Me.txtLastName.DataBindings.Add("Text", objDS, "Contact.Last_name")
Me.txtFullName.DataBindings.Add("Text", objDS, "Contact.full_name")
Me.txtAddress1.DataBindings.Add("Text", objDS, "Contact.con1_02_03")
Me.txtPhone.DataBindings.Add("Text", objDS, "Contact.Phone1")
Me.txtCity.DataBindings.Add("Text", objDS, "Contact.con1_02_05")
Me.txtState.DataBindings.Add("Text", objDS, "Contact.con1_02_06")
Me.txtZip.DataBindings.Add("Text", objDS, "Contact.con1_02_07")
Me.txtEMail.DataBindings.Add("Text", objDS, "Contact.con1_03_01")
End Sub
When I want to update, I have the following code:
Private Sub btnSave_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles btnSave.Click
BindingContext(objDS.Tables("Contact")).EndCurrent Edit()
Try
If objDS.HasChanges Then
DA.Update(objDS, "Contact")
End If
Me.Close()
Catch ex As Exception
MsgBox(ex.Message)
End Try
End Sub
but the above code doesn't work. HELP
"Rob Oldfield" <rob@oldfield100_wow_freeserve_yikes_co_incredible !_uk> wrote
in message news:%2******************@TK2MSFTNGP09.phx.gbl... Apologies for butting in, but just trying to clarify one of Cor's points -
The CommandBuilder cannot function correctly unless it knows what the
select command for the adapter is. The help file example looks like this...
Public Function SelectSqlSrvRows(myDataSet As DataSet, myConnection As String, mySelectQuery As String, myTableName As String) As DataSet Dim myConn As New SqlConnection(myConnection) Dim myDataAdapter As New SqlDataAdapter() myDataAdapter.SelectCommand = New SqlCommand(mySelectQuery, myConn) Dim custCB As SqlCommandBuilder = New SqlCommandBuilder(myDataAdapter) . . . i.e. the select command (and, incidentally, the connection) is set up
before using the CommandBuilder. "Gary" <ra******@yahoo.com> wrote in message news:eZ**************@TK2MSFTNGP12.phx.gbl... Hi Cor,
I did go back and look at the messages from the other day and I just
don't see what else I need to do. I'm sorry but I don't understand. I did place the CommandBuilder before the fill as you requested. I don't understand the "Replace the commandbuilder to the place where it has all the
information" line. To me it is already there. Can you elaborate more or give me a better example of what I have to do? I am lost.
Thanks,
Gary
"Cor Ligthert" <no**********@planet.nl> wrote in message news:O2*************@TK2MSFTNGP09.phx.gbl... Hi Gary,
As forever I do not want to change to much in peoples code.
This is your code, how can that commandbuilder build commands if he
does not know nothing about what he has to build. Replace the commandbuilder
to the place where it has all information. (Before the fill)
This did cost time to see this.
And others place it direct for the update, which I messaged you before last week.
Cor
strSQL = "Select * from Contact WHERE sysID = '" & g_sysID & "'" objDS.Clear()
Dim cmb As SqlClient.SqlCommandBuilder = New SqlClient.SqlCommandBuilder(DA) Dim selectCommand As New SqlClient.SqlCommand(strSQL) DA.SelectCommand = selectCommand DA.SelectCommand.Connection = CN
DA.Fill(objDS, "Contact")
Some questions:
Where does objDS get defined?
If you add a breakpoint on the Try line of your btnSave_Click and then step
through the code (use F11) then what happens?
If it gets to the line DA.Update(objDS, "Contact") then what does SQL
profiler show?
"Gary" <ra******@yahoo.com> wrote in message
news:uJ**************@TK2MSFTNGP09.phx.gbl... Thanks for giving me an example, but here is my code and it works bringing in the record but I'm not sure it's correct
Private Sub ContactMain_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim strSQL As String
strSQL = "Select * from Contact WHERE sysID = '" & g_sysID & "'" objDS.Clear()
Dim selectCommand As New SqlClient.SqlCommand(strSQL) DA.SelectCommand = selectCommand DA.SelectCommand.Connection = CN
Dim cmb As SqlClient.SqlCommandBuilder = New SqlClient.SqlCommandBuilder(DA)
DA.Fill(objDS, "Contact")
Me.txtFirstName.DataBindings.Add("Text", objDS, "Contact.first_name") Me.txtLastName.DataBindings.Add("Text", objDS,
"Contact.Last_name") Me.txtFullName.DataBindings.Add("Text", objDS,
"Contact.full_name") Me.txtAddress1.DataBindings.Add("Text", objDS,
"Contact.con1_02_03") Me.txtPhone.DataBindings.Add("Text", objDS, "Contact.Phone1") Me.txtCity.DataBindings.Add("Text", objDS, "Contact.con1_02_05") Me.txtState.DataBindings.Add("Text", objDS, "Contact.con1_02_06") Me.txtZip.DataBindings.Add("Text", objDS, "Contact.con1_02_07") Me.txtEMail.DataBindings.Add("Text", objDS, "Contact.con1_03_01")
End Sub
When I want to update, I have the following code:
Private Sub btnSave_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnSave.Click
BindingContext(objDS.Tables("Contact")).EndCurrent Edit()
Try If objDS.HasChanges Then DA.Update(objDS, "Contact") End If
Me.Close()
Catch ex As Exception
MsgBox(ex.Message)
End Try
End Sub
but the above code doesn't work. HELP "Rob Oldfield" <rob@oldfield100_wow_freeserve_yikes_co_incredible !_uk>
wrote in message news:%2******************@TK2MSFTNGP09.phx.gbl... Apologies for butting in, but just trying to clarify one of Cor's
points - The CommandBuilder cannot function correctly unless it knows what the
select command for the adapter is. The help file example looks like this...
Public Function SelectSqlSrvRows(myDataSet As DataSet, myConnection As String, mySelectQuery As String, myTableName As String) As DataSet Dim myConn As New SqlConnection(myConnection) Dim myDataAdapter As New SqlDataAdapter() myDataAdapter.SelectCommand = New SqlCommand(mySelectQuery, myConn) Dim custCB As SqlCommandBuilder = New
SqlCommandBuilder(myDataAdapter) . . . i.e. the select command (and, incidentally, the connection) is set up before using the CommandBuilder. "Gary" <ra******@yahoo.com> wrote in message news:eZ**************@TK2MSFTNGP12.phx.gbl... Hi Cor,
I did go back and look at the messages from the other day and I just don't see what else I need to do. I'm sorry but I don't understand. I did place the CommandBuilder before the fill as you requested. I don't
understand the "Replace the commandbuilder to the place where it has all the information" line. To me it is already there. Can you elaborate more or give me a better example of what I have to do? I am lost.
Thanks,
Gary
"Cor Ligthert" <no**********@planet.nl> wrote in message news:O2*************@TK2MSFTNGP09.phx.gbl... > Hi Gary, > > As forever I do not want to change to much in peoples code. > > This is your code, how can that commandbuilder build commands if he does not > know nothing about what he has to build. Replace the commandbuilder to the > place where it has all information. > (Before the fill) > > This did cost time to see this. > > And others place it direct for the update, which I messaged you
before last > week. > > Cor > > strSQL = "Select * from Contact WHERE sysID = '" & g_sysID &
"'" > objDS.Clear() > > Dim cmb As SqlClient.SqlCommandBuilder = New > SqlClient.SqlCommandBuilder(DA) > Dim selectCommand As New SqlClient.SqlCommand(strSQL) > DA.SelectCommand = selectCommand > DA.SelectCommand.Connection = CN > > DA.Fill(objDS, "Contact") > > >
Some questions:
Where does objDS get defined?
If you add a breakpoint on the Try line of your btnSave_Click and then step
through the code (use F11) then what happens?
If it gets to the line DA.Update(objDS, "Contact") then what does SQL
profiler show?
"Gary" <ra******@yahoo.com> wrote in message
news:uJ**************@TK2MSFTNGP09.phx.gbl... Thanks for giving me an example, but here is my code and it works bringing in the record but I'm not sure it's correct
Private Sub ContactMain_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim strSQL As String
strSQL = "Select * from Contact WHERE sysID = '" & g_sysID & "'" objDS.Clear()
Dim selectCommand As New SqlClient.SqlCommand(strSQL) DA.SelectCommand = selectCommand DA.SelectCommand.Connection = CN
Dim cmb As SqlClient.SqlCommandBuilder = New SqlClient.SqlCommandBuilder(DA)
DA.Fill(objDS, "Contact")
Me.txtFirstName.DataBindings.Add("Text", objDS, "Contact.first_name") Me.txtLastName.DataBindings.Add("Text", objDS,
"Contact.Last_name") Me.txtFullName.DataBindings.Add("Text", objDS,
"Contact.full_name") Me.txtAddress1.DataBindings.Add("Text", objDS,
"Contact.con1_02_03") Me.txtPhone.DataBindings.Add("Text", objDS, "Contact.Phone1") Me.txtCity.DataBindings.Add("Text", objDS, "Contact.con1_02_05") Me.txtState.DataBindings.Add("Text", objDS, "Contact.con1_02_06") Me.txtZip.DataBindings.Add("Text", objDS, "Contact.con1_02_07") Me.txtEMail.DataBindings.Add("Text", objDS, "Contact.con1_03_01")
End Sub
When I want to update, I have the following code:
Private Sub btnSave_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnSave.Click
BindingContext(objDS.Tables("Contact")).EndCurrent Edit()
Try If objDS.HasChanges Then DA.Update(objDS, "Contact") End If
Me.Close()
Catch ex As Exception
MsgBox(ex.Message)
End Try
End Sub
but the above code doesn't work. HELP "Rob Oldfield" <rob@oldfield100_wow_freeserve_yikes_co_incredible !_uk>
wrote in message news:%2******************@TK2MSFTNGP09.phx.gbl... Apologies for butting in, but just trying to clarify one of Cor's
points - The CommandBuilder cannot function correctly unless it knows what the
select command for the adapter is. The help file example looks like this...
Public Function SelectSqlSrvRows(myDataSet As DataSet, myConnection As String, mySelectQuery As String, myTableName As String) As DataSet Dim myConn As New SqlConnection(myConnection) Dim myDataAdapter As New SqlDataAdapter() myDataAdapter.SelectCommand = New SqlCommand(mySelectQuery, myConn) Dim custCB As SqlCommandBuilder = New
SqlCommandBuilder(myDataAdapter) . . . i.e. the select command (and, incidentally, the connection) is set up before using the CommandBuilder. "Gary" <ra******@yahoo.com> wrote in message news:eZ**************@TK2MSFTNGP12.phx.gbl... Hi Cor,
I did go back and look at the messages from the other day and I just don't see what else I need to do. I'm sorry but I don't understand. I did place the CommandBuilder before the fill as you requested. I don't
understand the "Replace the commandbuilder to the place where it has all the information" line. To me it is already there. Can you elaborate more or give me a better example of what I have to do? I am lost.
Thanks,
Gary
"Cor Ligthert" <no**********@planet.nl> wrote in message news:O2*************@TK2MSFTNGP09.phx.gbl... > Hi Gary, > > As forever I do not want to change to much in peoples code. > > This is your code, how can that commandbuilder build commands if he does not > know nothing about what he has to build. Replace the commandbuilder to the > place where it has all information. > (Before the fill) > > This did cost time to see this. > > And others place it direct for the update, which I messaged you
before last > week. > > Cor > > strSQL = "Select * from Contact WHERE sysID = '" & g_sysID &
"'" > objDS.Clear() > > Dim cmb As SqlClient.SqlCommandBuilder = New > SqlClient.SqlCommandBuilder(DA) > Dim selectCommand As New SqlClient.SqlCommand(strSQL) > DA.SelectCommand = selectCommand > DA.SelectCommand.Connection = CN > > DA.Fill(objDS, "Contact") > > >
I made two changes. One was removing the line If objDS.HasChanges
Then
and the other was had to do with the SQL statement. In the table, there was
a field called [trigger]. That was the definition so I changed the name to
trigger1. That seemed to solve the problem. Now everything works and I can
go back to work again.
I was pulling out the remaining hairs on my head over this.
Thanks loads,
Gary
"Rob Oldfield" <rob@oldfield100_wow_freeserve_yikes_co_incredible !_uk> wrote
in message news:uk*************@tk2msftngp13.phx.gbl... Some questions:
Where does objDS get defined? If you add a breakpoint on the Try line of your btnSave_Click and then
step through the code (use F11) then what happens? If it gets to the line DA.Update(objDS, "Contact") then what does SQL profiler show? "Gary" <ra******@yahoo.com> wrote in message news:uJ**************@TK2MSFTNGP09.phx.gbl... Thanks for giving me an example, but here is my code and it works
bringing in the record but I'm not sure it's correct
Private Sub ContactMain_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim strSQL As String
strSQL = "Select * from Contact WHERE sysID = '" & g_sysID & "'" objDS.Clear()
Dim selectCommand As New SqlClient.SqlCommand(strSQL) DA.SelectCommand = selectCommand DA.SelectCommand.Connection = CN
Dim cmb As SqlClient.SqlCommandBuilder = New SqlClient.SqlCommandBuilder(DA)
DA.Fill(objDS, "Contact")
Me.txtFirstName.DataBindings.Add("Text", objDS, "Contact.first_name") Me.txtLastName.DataBindings.Add("Text", objDS, "Contact.Last_name") Me.txtFullName.DataBindings.Add("Text", objDS, "Contact.full_name") Me.txtAddress1.DataBindings.Add("Text", objDS, "Contact.con1_02_03") Me.txtPhone.DataBindings.Add("Text", objDS, "Contact.Phone1") Me.txtCity.DataBindings.Add("Text", objDS, "Contact.con1_02_05") Me.txtState.DataBindings.Add("Text", objDS,
"Contact.con1_02_06") Me.txtZip.DataBindings.Add("Text", objDS, "Contact.con1_02_07") Me.txtEMail.DataBindings.Add("Text", objDS,
"Contact.con1_03_01") End Sub
When I want to update, I have the following code:
Private Sub btnSave_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnSave.Click
BindingContext(objDS.Tables("Contact")).EndCurrent Edit()
Try If objDS.HasChanges Then DA.Update(objDS, "Contact") End If
Me.Close()
Catch ex As Exception
MsgBox(ex.Message)
End Try
End Sub
but the above code doesn't work. HELP "Rob Oldfield" <rob@oldfield100_wow_freeserve_yikes_co_incredible !_uk> wrote in message news:%2******************@TK2MSFTNGP09.phx.gbl... Apologies for butting in, but just trying to clarify one of Cor's points - The CommandBuilder cannot function correctly unless it knows what the select command for the adapter is. The help file example looks like this...
Public Function SelectSqlSrvRows(myDataSet As DataSet, myConnection As String, mySelectQuery As String, myTableName As String) As DataSet Dim myConn As New SqlConnection(myConnection) Dim myDataAdapter As New SqlDataAdapter() myDataAdapter.SelectCommand = New SqlCommand(mySelectQuery,
myConn) Dim custCB As SqlCommandBuilder = New SqlCommandBuilder(myDataAdapter) . . . i.e. the select command (and, incidentally, the connection) is set up before using the CommandBuilder. "Gary" <ra******@yahoo.com> wrote in message news:eZ**************@TK2MSFTNGP12.phx.gbl... > Hi Cor, > > I did go back and look at the messages from the other day and I just don't > see what else I need to do. I'm sorry but I don't understand. I
did place > the CommandBuilder before the fill as you requested. I don't understand the > "Replace the commandbuilder to the place where it has all the information" > line. To me it is already there. Can you elaborate more or give me
a > better example of what I have to do? I am lost. > > Thanks, > > Gary > > "Cor Ligthert" <no**********@planet.nl> wrote in message > news:O2*************@TK2MSFTNGP09.phx.gbl... > > Hi Gary, > > > > As forever I do not want to change to much in peoples code. > > > > This is your code, how can that commandbuilder build commands if
he does > not > > know nothing about what he has to build. Replace the
commandbuilder to > the > > place where it has all information. > > (Before the fill) > > > > This did cost time to see this. > > > > And others place it direct for the update, which I messaged you before > last > > week. > > > > Cor > > > > strSQL = "Select * from Contact WHERE sysID = '" & g_sysID & "'" > > objDS.Clear() > > > > Dim cmb As SqlClient.SqlCommandBuilder = New > > SqlClient.SqlCommandBuilder(DA) > > Dim selectCommand As New SqlClient.SqlCommand(strSQL) > > DA.SelectCommand = selectCommand > > DA.SelectCommand.Connection = CN > > > > DA.Fill(objDS, "Contact") > > > > > > > >
I made two changes. One was removing the line If objDS.HasChanges
Then
and the other was had to do with the SQL statement. In the table, there was
a field called [trigger]. That was the definition so I changed the name to
trigger1. That seemed to solve the problem. Now everything works and I can
go back to work again.
I was pulling out the remaining hairs on my head over this.
Thanks loads,
Gary
"Rob Oldfield" <rob@oldfield100_wow_freeserve_yikes_co_incredible !_uk> wrote
in message news:uk*************@tk2msftngp13.phx.gbl... Some questions:
Where does objDS get defined? If you add a breakpoint on the Try line of your btnSave_Click and then
step through the code (use F11) then what happens? If it gets to the line DA.Update(objDS, "Contact") then what does SQL profiler show? "Gary" <ra******@yahoo.com> wrote in message news:uJ**************@TK2MSFTNGP09.phx.gbl... Thanks for giving me an example, but here is my code and it works
bringing in the record but I'm not sure it's correct
Private Sub ContactMain_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim strSQL As String
strSQL = "Select * from Contact WHERE sysID = '" & g_sysID & "'" objDS.Clear()
Dim selectCommand As New SqlClient.SqlCommand(strSQL) DA.SelectCommand = selectCommand DA.SelectCommand.Connection = CN
Dim cmb As SqlClient.SqlCommandBuilder = New SqlClient.SqlCommandBuilder(DA)
DA.Fill(objDS, "Contact")
Me.txtFirstName.DataBindings.Add("Text", objDS, "Contact.first_name") Me.txtLastName.DataBindings.Add("Text", objDS, "Contact.Last_name") Me.txtFullName.DataBindings.Add("Text", objDS, "Contact.full_name") Me.txtAddress1.DataBindings.Add("Text", objDS, "Contact.con1_02_03") Me.txtPhone.DataBindings.Add("Text", objDS, "Contact.Phone1") Me.txtCity.DataBindings.Add("Text", objDS, "Contact.con1_02_05") Me.txtState.DataBindings.Add("Text", objDS,
"Contact.con1_02_06") Me.txtZip.DataBindings.Add("Text", objDS, "Contact.con1_02_07") Me.txtEMail.DataBindings.Add("Text", objDS,
"Contact.con1_03_01") End Sub
When I want to update, I have the following code:
Private Sub btnSave_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnSave.Click
BindingContext(objDS.Tables("Contact")).EndCurrent Edit()
Try If objDS.HasChanges Then DA.Update(objDS, "Contact") End If
Me.Close()
Catch ex As Exception
MsgBox(ex.Message)
End Try
End Sub
but the above code doesn't work. HELP "Rob Oldfield" <rob@oldfield100_wow_freeserve_yikes_co_incredible !_uk> wrote in message news:%2******************@TK2MSFTNGP09.phx.gbl... Apologies for butting in, but just trying to clarify one of Cor's points - The CommandBuilder cannot function correctly unless it knows what the select command for the adapter is. The help file example looks like this...
Public Function SelectSqlSrvRows(myDataSet As DataSet, myConnection As String, mySelectQuery As String, myTableName As String) As DataSet Dim myConn As New SqlConnection(myConnection) Dim myDataAdapter As New SqlDataAdapter() myDataAdapter.SelectCommand = New SqlCommand(mySelectQuery,
myConn) Dim custCB As SqlCommandBuilder = New SqlCommandBuilder(myDataAdapter) . . . i.e. the select command (and, incidentally, the connection) is set up before using the CommandBuilder. "Gary" <ra******@yahoo.com> wrote in message news:eZ**************@TK2MSFTNGP12.phx.gbl... > Hi Cor, > > I did go back and look at the messages from the other day and I just don't > see what else I need to do. I'm sorry but I don't understand. I
did place > the CommandBuilder before the fill as you requested. I don't understand the > "Replace the commandbuilder to the place where it has all the information" > line. To me it is already there. Can you elaborate more or give me
a > better example of what I have to do? I am lost. > > Thanks, > > Gary > > "Cor Ligthert" <no**********@planet.nl> wrote in message > news:O2*************@TK2MSFTNGP09.phx.gbl... > > Hi Gary, > > > > As forever I do not want to change to much in peoples code. > > > > This is your code, how can that commandbuilder build commands if
he does > not > > know nothing about what he has to build. Replace the
commandbuilder to > the > > place where it has all information. > > (Before the fill) > > > > This did cost time to see this. > > > > And others place it direct for the update, which I messaged you before > last > > week. > > > > Cor > > > > strSQL = "Select * from Contact WHERE sysID = '" & g_sysID & "'" > > objDS.Clear() > > > > Dim cmb As SqlClient.SqlCommandBuilder = New > > SqlClient.SqlCommandBuilder(DA) > > Dim selectCommand As New SqlClient.SqlCommand(strSQL) > > DA.SelectCommand = selectCommand > > DA.SelectCommand.Connection = CN > > > > DA.Fill(objDS, "Contact") > > > > > > > >
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Jason |
last post by:
Let's say I have an html form with 20 or 30 fields in it. The form
submits the fields via POST to a php page which updates a table in a
database with the $_POST vars. Which makes more sense?
...
|
by: Srinadh |
last post by:
Hi all,
We have files with about 20 to 30 fields per row.
We are trying to update such files with about 60 rows as contiguous
data in a CLOB field.
It passes through.
But when we try...
|
by: Mark |
last post by:
I'm having a problem updating recordsin an Access DB table. I can update
other tables in this db with no problem, and I can dreate new record in all
of the tables (including this one.)> But I can't...
|
by: Luis Esteban Valencia |
last post by:
Hello Everyone,
Iam an intermediate ASP.Net programmer and iam facing a challenging task.
I have a table in MS-SQL server database called 'Members'. The table has
following fields...
...
|
by: jaYPee |
last post by:
does anyone experienced slowness when updating a dataset using
AcceptChanges?
when calling this code it takes many seconds to update the database
SqlDataAdapter1.Update(DsStudentCourse1)...
|
by: Geoff |
last post by:
Hi
I'm hoping somebody can help me with the following problem that has occurred
to me.
Suppose I have two tables in an SQL Server database. Let's call these tables
A and B. Assume that A has...
|
by: Rich |
last post by:
Dim da As New SqlDataAdapter("Select * from tbl1", conn)
dim tblx As New DataTable
da.Fill(tblx) '--works OK up to this point
da.UpdateCommand = New SqlCommand
da.UpdateCommand.Connection =...
|
by: teammcs |
last post by:
Hey all,
I'm new around here but do Admin over @ PHPHelp.com... I've been developing a project for my degree which is basically based around an ATM machine.
Basically my problem is related to...
|
by: bill |
last post by:
In an application I am writing the user can define a series of
steps to be followed. I save them in a sql database using the
field "order" (a smallint) as the primary key.
(there are in the range...
|
by: =?Utf-8?B?VmFuZXNzYQ==?= |
last post by:
Hi All!
I am with a situation where I am not getting the right updating to the
form's fields. The situation is the following one:
I have one combobox and one textbox. I am using the...
|
by: Faith0G |
last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome former...
|
by: ryjfgjl |
last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
|
by: aa123db |
last post by:
Variable and constants
Use var or let for variables and const fror constants.
Var foo ='bar';
Let foo ='bar';const baz ='bar';
Functions
function $name$ ($parameters$) {
}
...
|
by: ryjfgjl |
last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
| |