Click here to Skip to main content
15,914,162 members
Home / Discussions / Database
   

Database

 
AnswerRe: SQL Query Pin
andyharman6-Aug-07 7:15
professionalandyharman6-Aug-07 7:15 
GeneralRe: SQL Query Pin
sangramkp6-Aug-07 7:40
sangramkp6-Aug-07 7:40 
GeneralRe: SQL Query Pin
andyharman6-Aug-07 8:17
professionalandyharman6-Aug-07 8:17 
AnswerRe: SQL Query Pin
Pete O'Hanlon6-Aug-07 22:05
mvePete O'Hanlon6-Aug-07 22:05 
QuestionTimeout while reading data from database Pin
Muhammad Ahmed6-Aug-07 6:45
Muhammad Ahmed6-Aug-07 6:45 
AnswerRe: Timeout while reading data from database Pin
vimal_yet6-Aug-07 22:23
vimal_yet6-Aug-07 22:23 
AnswerRe: Timeout while reading data from database Pin
Pete O'Hanlon6-Aug-07 22:38
mvePete O'Hanlon6-Aug-07 22:38 
QuestionDataAdapter.Update Problem Pin
MohammadAmiry6-Aug-07 6:12
MohammadAmiry6-Aug-07 6:12 
Hi I use the following code to add a row to my database using ADO.NET in VB.NET:

Dim strConnstring As String = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=|DataDirectory|\DB.mdb"
        Dim Sql As String = String.Format("INSERT INTO Employee(FName,LName,Salary) VALUES('{0}','{1}',{2})", txtFirstName.Text, txtLastName.Text, txtSalary2.Text)

        Dim Conn As New OleDbConnection(strConnstring)
        Dim Comm As New OleDbCommand(Sql, Conn)
        Dim DA As New OleDbDataAdapter(Comm)
        Dim DS As New DataSet
        Conn.Open()
        Comm.ExecuteNonQuery()
        Conn.Close()


Everything looks fine, the datagrid which shows Employee table, shows that the item is added.

But DataAdapter does not update the dataset! I noticed that when I add a row by this method, the State of the row is not set to Added, like when I use Rows.Add (which works just fine!)

I need to do this using this SQL command, but how to update the database also?
(I again notice that myDataSet.GetChanged is null!)
Questionproblem with pop3 mail box Pin
shaikshavali6-Aug-07 2:17
shaikshavali6-Aug-07 2:17 
AnswerRe: problem with pop3 mail box Pin
Marek Grzenkowicz6-Aug-07 22:30
Marek Grzenkowicz6-Aug-07 22:30 
QuestionDate Range Pin
Brendan Vogt5-Aug-07 20:50
Brendan Vogt5-Aug-07 20:50 
AnswerRe: Date Range Pin
Krish - KP5-Aug-07 21:10
Krish - KP5-Aug-07 21:10 
QuestionReducing the Execution time of the Sql Server 2000 Stored procedure. Pin
tonic_valan5-Aug-07 20:32
tonic_valan5-Aug-07 20:32 
AnswerRe: Reducing the Execution time of the Sql Server 2000 Stored procedure. Pin
Marek Grzenkowicz5-Aug-07 21:02
Marek Grzenkowicz5-Aug-07 21:02 
GeneralRe: Reducing the Execution time of the Sql Server 2000 Stored procedure. Pin
tonic_valan5-Aug-07 22:03
tonic_valan5-Aug-07 22:03 
GeneralRe: Reducing the Execution time of the Sql Server 2000 Stored procedure. Pin
Marek Grzenkowicz5-Aug-07 23:47
Marek Grzenkowicz5-Aug-07 23:47 
GeneralRe: Reducing the Execution time of the Sql Server 2000 Stored procedure. Pin
tonic_valan6-Aug-07 1:50
tonic_valan6-Aug-07 1:50 
GeneralRe: Reducing the Execution time of the Sql Server 2000 Stored procedure. Pin
Marek Grzenkowicz6-Aug-07 21:57
Marek Grzenkowicz6-Aug-07 21:57 
GeneralRe: Reducing the Execution time of the Sql Server 2000 Stored procedure. Pin
tonic_valan7-Aug-07 20:33
tonic_valan7-Aug-07 20:33 
GeneralRe: Reducing the Execution time of the Sql Server 2000 Stored procedure. Pin
Marek Grzenkowicz7-Aug-07 23:12
Marek Grzenkowicz7-Aug-07 23:12 
GeneralRe: Reducing the Execution time of the Sql Server 2000 Stored procedure. Pin
tonic_valan8-Aug-07 23:34
tonic_valan8-Aug-07 23:34 
QuestionSQL 2005 Default Scripts Directory Pin
jareddavies5-Aug-07 14:09
jareddavies5-Aug-07 14:09 
QuestionRestore database using t-sq Pin
WDI4-Aug-07 9:57
WDI4-Aug-07 9:57 
AnswerRe: Restore database using t-sq Pin
Paul Conrad4-Aug-07 18:25
professionalPaul Conrad4-Aug-07 18:25 
GeneralRe: Restore database using t-sq Pin
Stathread5-Aug-07 10:24
Stathread5-Aug-07 10:24 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.