About Updating a Record in adodb

Reply

Join Date: Aug 2008
Posts: 304
Reputation: aktharshaik is an unknown quantity at this point 
Solved Threads: 37
aktharshaik's Avatar
aktharshaik aktharshaik is offline Offline
Posting Whiz

Re: About Updating a Record in adodb

 
0
  #11
Dec 1st, 2008
ur code is
Visual Basic 4 / 5 / 6 Syntax (Toggle Plain Text)
  1. "Insert Into Deliver (scode, pcode, quantity, unit, amount, pcarrier, pterms, drnumber, date) Values ('" + Combo1.Text + "','" + Combo2.Text + "'," + Text1.Text + "," + Text2.Text + "," + Text3.Text + "," + Text4.Text + "," + Text5.Text + "," + Text6.Text + "," + Text7.Text + ")"

I assume scode, pcode, unit, pcarrier, pterms, drnumber, date are Text fields
and quantity, amount are Numeric fields
hence
Visual Basic 4 / 5 / 6 Syntax (Toggle Plain Text)
  1. "Insert Into Deliver (scode, pcode, quantity, unit, amount, pcarrier, pterms, drnumber, date) Values ('" + Combo1.Text + "','" + Combo2.Text + "'," + Text1.Text + ",'" + Text2.Text + "'," + Text3.Text + ",'" + Text4.Text + "','" + Text5.Text + "','" + Text6.Text + "','" + Text7.Text + "')"

also remove the
, cn, adOpenKeyset, adLockPessimistic
in the insert statement.

Regards
Shaik Akthar
Reply With Quote Quick reply to this message  
Join Date: Jul 2008
Posts: 161
Reputation: ryan311 has a little shameless behaviour in the past 
Solved Threads: 1
ryan311 ryan311 is offline Offline
Junior Poster

Re: About Updating a Record in adodb

 
0
  #12
Dec 1st, 2008
syntax error in inert into
Reply With Quote Quick reply to this message  
Join Date: Aug 2008
Posts: 304
Reputation: aktharshaik is an unknown quantity at this point 
Solved Threads: 37
aktharshaik's Avatar
aktharshaik aktharshaik is offline Offline
Posting Whiz

Re: About Updating a Record in adodb

 
0
  #13
Dec 1st, 2008
what is the datatype of the field 'date' in your database and is it MS-Access Database?
Reply With Quote Quick reply to this message  
Join Date: Aug 2008
Posts: 304
Reputation: aktharshaik is an unknown quantity at this point 
Solved Threads: 37
aktharshaik's Avatar
aktharshaik aktharshaik is offline Offline
Posting Whiz

Re: About Updating a Record in adodb

 
0
  #14
Dec 1st, 2008
just once give me all the fields with their datatypes with which they exist in the database in the table Deliver
Last edited by aktharshaik; Dec 1st, 2008 at 10:53 am.
Reply With Quote Quick reply to this message  
Join Date: Jul 2008
Posts: 161
Reputation: ryan311 has a little shameless behaviour in the past 
Solved Threads: 1
ryan311 ryan311 is offline Offline
Junior Poster

Re: About Updating a Record in adodb

 
0
  #15
Dec 2nd, 2008
the date is Date/time and the rest is text
Reply With Quote Quick reply to this message  
Join Date: Aug 2008
Posts: 304
Reputation: aktharshaik is an unknown quantity at this point 
Solved Threads: 37
aktharshaik's Avatar
aktharshaik aktharshaik is offline Offline
Posting Whiz

Re: About Updating a Record in adodb

 
0
  #16
Dec 2nd, 2008
If the database is MS-Access u have to use a # for date field.
It goes like this. replace the query with this one.
Visual Basic 4 / 5 / 6 Syntax (Toggle Plain Text)
  1. "Insert Into Deliver (scode, pcode, quantity, unit, amount, pcarrier, pterms, drnumber, date) Values ('" + Combo1.Text + "','" + Combo2.Text + "'," + Text1.Text + ",'" + Text2.Text + "'," + Text3.Text + ",'" + Text4.Text + "','" + Text5.Text + "','" + Text6.Text + "',#" + Text7.Text + "#)"
Regards
Shaik Akthar
Reply With Quote Quick reply to this message  
Join Date: Jul 2008
Posts: 161
Reputation: ryan311 has a little shameless behaviour in the past 
Solved Threads: 1
ryan311 ryan311 is offline Offline
Junior Poster

Re: About Updating a Record in adodb

 
0
  #17
Dec 2nd, 2008
still having a error

synthax error in insert into, how can i upload my files here? can u fix it?
Reply With Quote Quick reply to this message  
Join Date: Aug 2008
Posts: 304
Reputation: aktharshaik is an unknown quantity at this point 
Solved Threads: 37
aktharshaik's Avatar
aktharshaik aktharshaik is offline Offline
Posting Whiz

Re: About Updating a Record in adodb

 
0
  #18
Dec 2nd, 2008
just zip the access database file and the vbform.

Click on Reply to Thread button. do not post in quick reply.
below the reply box u can find the button for attachments. there u select the zip file and upload it.
Regards
Shaik Akthar
Reply With Quote Quick reply to this message  
Join Date: Aug 2008
Posts: 304
Reputation: aktharshaik is an unknown quantity at this point 
Solved Threads: 37
aktharshaik's Avatar
aktharshaik aktharshaik is offline Offline
Posting Whiz

Re: About Updating a Record in adodb

 
0
  #19
Dec 2nd, 2008
i have enclosed a screenshot of the reply screen
Attached Images
File Type: bmp abc1.bmp (338.0 KB, 2 views)
Regards
Shaik Akthar
Reply With Quote Quick reply to this message  
Join Date: Jul 2008
Posts: 161
Reputation: ryan311 has a little shameless behaviour in the past 
Solved Threads: 1
ryan311 ryan311 is offline Offline
Junior Poster

Re: About Updating a Record in adodb

 
0
  #20
Dec 2nd, 2008
here it is!
Attached Files
File Type: zip Inventory System.zip (46.4 KB, 2 views)
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the Visual Basic 4 / 5 / 6 Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC