I have to create an sql database for work, for my students to work with. I have created a large portion of the program, but i am stuck on the searching of data. So searching for a person or department. Not sure how to do it, here is my code. i anyone can point me in the right direction

http://pastebin.com/S5GDYWiQ - Database class file
http://pastebin.com/91i1N17s - form code

Thank you

Recommended Answers

All 5 Replies

In order to select rows from database, you need to use SELECT with appropriate WHERE clause.

Include necessary code and description of problem in your post.

PS: I'd like to suggest you to learn/use LINQ and Entity Framework.

Hi, its a nice suggestion by _avd and I would like to add to the same that if you wish to select all the person table's records you may use Select * from Persons_Table; in your SQL IDE and moreover for further help in SQL queries you may go through Click Here

Hey mcoliver88, I sent you a message.

I would like to see what you figured out about the SQL link I sent you

this is an example for searching person 'malek' from tabletablePerson:
select (*) from tablePerson where tablePerso=' malek';

I am not getting much from your request but a question related to a SELECT statement in SQL. Canyou maybe provide more information please?

You say that you created a huge portion of the program but stuck on something related to a Select statement? There has to be more to this somehow...

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, learning, and sharing knowledge.