473,396 Members | 1,785 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Database

I study the manual of W3Schools, And couldn't find enough
explanation for Databases.
I managed to understand how to pull out data from table, But don't
know yet how to update and insert data.

This code pulls data from a table. I would like you to show me how
should I update and insert data to the same table, if you too busy,
then link for a good manual that explain this stuff would be nice too.
(sorry for my english)
thanks

dim dbconn,sql,dbcomm,dbread
dbconn=New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0; data
source=" & server.mappath("/a/northwind.mdb"))
dbconn.Open()
sql="SELECT * FROM customers"
dbcomm=New OleDbCommand(sql,dbconn)
dbread=dbcomm.ExecuteReader()
customers.DataSource=dbread
customers.DataBind()
dbread.Close()
dbconn.Close()

Jul 16 '07 #1
3 1343
Here are some samples:
http://www.asp101.com/samples/

make sure you get the "DotNet" versions.

"Gandalf" <go******@gmail.comwrote in message
news:11*********************@o61g2000hsh.googlegro ups.com...
>I study the manual of W3Schools, And couldn't find enough
explanation for Databases.
I managed to understand how to pull out data from table, But don't
know yet how to update and insert data.

This code pulls data from a table. I would like you to show me how
should I update and insert data to the same table, if you too busy,
then link for a good manual that explain this stuff would be nice too.
(sorry for my english)
thanks

dim dbconn,sql,dbcomm,dbread
dbconn=New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0; data
source=" & server.mappath("/a/northwind.mdb"))
dbconn.Open()
sql="SELECT * FROM customers"
dbcomm=New OleDbCommand(sql,dbconn)
dbread=dbcomm.ExecuteReader()
customers.DataSource=dbread
customers.DataBind()
dbread.Close()
dbconn.Close()

Jul 16 '07 #2
Will you be using a combination of textboxes, dropdownlists, etc for the
insert form, or one of the built in controls, like a DetailsView?

(All the items containing 'insert', at ASPNet101.com:
http://www.aspnet101.com/aspnet101/s...px?item=insert)
--
David Wier
MVP/ASPInsider
http://aspnet101.com
http://iWritePro.com

"Gandalf" <go******@gmail.comwrote in message
news:11*********************@o61g2000hsh.googlegro ups.com...
>I study the manual of W3Schools, And couldn't find enough
explanation for Databases.
I managed to understand how to pull out data from table, But don't
know yet how to update and insert data.

This code pulls data from a table. I would like you to show me how
should I update and insert data to the same table, if you too busy,
then link for a good manual that explain this stuff would be nice too.
(sorry for my english)
thanks

dim dbconn,sql,dbcomm,dbread
dbconn=New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0; data
source=" & server.mappath("/a/northwind.mdb"))
dbconn.Open()
sql="SELECT * FROM customers"
dbcomm=New OleDbCommand(sql,dbconn)
dbread=dbcomm.ExecuteReader()
customers.DataSource=dbread
customers.DataBind()
dbread.Close()
dbconn.Close()

Jul 16 '07 #3
On Jul 16, 4:56 pm, "David Wier" <davidw...@davidwier.nospam.com>
wrote:
Will you be using a combination of textboxes, dropdownlists, etc for the
insert form, or one of the built in controls, like a DetailsView?

(All the items containing 'insert', at ASPNet101.com:http://www.aspnet101.com/aspnet101/s...px?item=insert)
--
David Wier
MVP/ASPInsiderhttp://aspnet101.comhttp://iWritePro.com

"Gandalf" <goldn...@gmail.comwrote in message

news:11*********************@o61g2000hsh.googlegro ups.com...
I study the manual of W3Schools, And couldn't find enough
explanation for Databases.
I managed to understand how to pull out data from table, But don't
know yet how to update and insert data.
This code pulls data from a table. I would like you to show me how
should I update and insert data to the same table, if you too busy,
then link for a good manual that explain this stuff would be nice too.
(sorry for my english)
thanks
dim dbconn,sql,dbcomm,dbread
dbconn=New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0; data
source=" & server.mappath("/a/northwind.mdb"))
dbconn.Open()
sql="SELECT * FROM customers"
dbcomm=New OleDbCommand(sql,dbconn)
dbread=dbcomm.ExecuteReader()
customers.DataSource=dbread
customers.DataBind()
dbread.Close()
dbconn.Close()
thanks guys!

Jul 16 '07 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Cherrish Vaidiyan | last post by:
sir, The following are the steps that i followed in setting up standby database on Red hat Linux 9. i am using Oracle 9i. i have followed the steps in this site : ...
6
by: Marvin Libson | last post by:
Hi All: I am running DB2 UDB V7.2 with FP11. Platform is Windows 2000. I have created a java UDF and trigger. When I update my database I get the following error: SQL1224N A database...
8
by: Kamlesh | last post by:
Hi, How do I know the physical database path of a database. When I goto the DB2INSTANCE users's directory (/home/db2inst1), I see following folders: /db2inst1/NODE0000/SQL00001...
1
by: pintur | last post by:
The message is: SQL1036C Errore di I/O durante l' accesso al database. SQLSTATE=58030 what is the proble? what for restore tables? thanks
3
by: josh.kuo | last post by:
Sorry about the subject, I can't think of a better one. I recently wrote some PHP classes that I think might be of interest to this group. Since I have been reaping the benefits of reading news...
8
by: morleyc | last post by:
Hi, until recently i was quite happy to add data sources from mssql database in visual studio and drag the datasets directly onto the form this creating a directly editable form which worked well....
0
by: Jack | last post by:
Training Classes for Oracle10g, 9i, 8i Certification training in Oracle10g and 9i: DBA, Developer, Discoverer. training conducted at your location worldwide. Courseware licensing also available....
0
by: Winder | last post by:
Training Classes for Oracle10g, 9i, 8i Certification training in Oracle10g and 9i: DBA, Developer, Discoverer. training conducted at your location worldwide. Courseware licensing also available....
0
by: Laurynn | last post by:
# (ebook - pdf) - programming - mysql - php database applicati # (Ebook - Pdf)Learnkey How To Design A Database - Sql And Crystal Report # (ebook-pdf) E F Codd - Extending the Database Relational...
9
by: Peter Duniho | last post by:
Is there a straightfoward API in .NET that allows for inspection of a database? That is, to look at the structure of the database, without knowing anything in advance about it? For example,...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
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...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
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...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.