473,398 Members | 2,343 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,398 software developers and data experts.

Problem with Inserting a record

Hai everybody,

i like to insert some records into database from html form by entering data.my problem is how can i check , whether a record is available in database about a particular employee before inserting. if a employee record is available(for example based on employee num) , then if i try to insert again with that employee id, it should not enter into database(avoid duplicate records with same employee num)

can any one help me please, what should be the query.I am using java for inserting records and IDE is NETBEANS5.5
Jun 5 '07 #1
3 1751
MMcCarthy
14,534 Expert Mod 8TB
Hai everybody,

i like to insert some records into database from html form by entering data.my problem is how can i check , whether a record is available in database about a particular employee before inserting. if a employee record is available(for example based on employee num) , then if i try to insert again with that employee id, it should not enter into database(avoid duplicate records with same employee num)

can any one help me please, what should be the query.I am using java for inserting records and IDE is NETBEANS5.5
If you set the indexed property of the employee num field in the access database to Yes (No Duplicates) then Access will not allow the duplicate record to be added.
Jun 6 '07 #2
If you set the indexed property of the employee num field in the access database to Yes (No Duplicates) then Access will not allow the duplicate record to be added.
Hai mmccarthy

Thanks for your answer, even i tried with access, i got the solution as u said. now its working perfectly. thanks for ur valuable time
Jun 6 '07 #3
MMcCarthy
14,534 Expert Mod 8TB
Hai mmccarthy

Thanks for your answer, even i tried with access, i got the solution as u said. now its working perfectly. thanks for ur valuable time
You're welcome.
Jun 6 '07 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

8
by: Alban Hertroys | last post by:
Hello, I'm using psycopg to insert records in a number of threads. After the threads finish, another thread runs to collect the inserted data. Now, my problem is that psycopg let's my threads...
6
by: bhavik | last post by:
hi i have one aspx page on which i have one button in code behind i wrote a code for inserting a record. if i clicik on button it inserts a record ok ite fine but the problem is that if i...
4
by: thebison | last post by:
Hi all, I hope someone can help with this relatively simple problem. I am building a timesheet application using ASP.NET C# with Visual Studio 2003.As it is only a protoype application, my...
2
by: clickon | last post by:
I have set up a GridView control bound to an SQLDataSource control. Depending on which option a user selects in a DropDownList Each datasource is a sethe select command retrieves a list of...
12
by: Light | last post by:
Hi all, I posted this question in the sqlserver.newusers group but I am not getting any response there so I am going to try it on the fine folks here:). I inherited some legacy ASP codes in my...
3
by: Surya | last post by:
Dear All, I have problem on inserting a record to database..Although it looked easy.. i have caught up with following issue .. please go ahead and help me to find solution I Need to insert...
20
by: dav3 | last post by:
Alright folks I am in need of a lil guidance/assistance here. I have a program which reads in a txt file. This txt file contains lines of the form January 3, 2007, 85.8 Now each line of the txt...
2
by: Question123 | last post by:
Hi i have one database table Table1.which contains almost 20000000 recordes. record to this table are inserted through storedprocedure. storedprocedure takes parameter as "value", Beginningdate,...
2
by: AlexanderDeLarge | last post by:
Hi! I got a problem that's driving me crazy and I'm desperately in need of help. I'll explain my scenario: I'm doing a database driven site for a band, I got these tables for their discography...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
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
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
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
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.