Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Searching in sql server with c#.There are many textbox and many probability.. User not have to populating all fields I will do a search in

image text in transcribed

Searching in sql server with c#.There are many textbox and many probability..

User not have to populating all fields

I will do a search in the database, if there are sections that are empty, should I type a query one by one? If all the pieces are filled in, my code will be:

SELECT * from Thesis AS T INNER JOIN Person AS A ON A.PersonID=T.AuthorID AND A.PersonFullName='Author name' INNER JOIN Person AS S ON S.PersonID=T.SupervisorID AND S.PersonFullName='supervisor' LEFT OUTER JOIN Person AS CS ON CS.PersonID=T.SupervisorID AND CS.PersonFullName='cosupervisor' INNER JOIN Enstitute AS E ON E.EnstituteID=T.EnstituteID AND E.EnstituteName=' enstitutename ' INNER JOIN University AS U ON U.UniversityID=E.UniversityID AND U.UniversityName='universityname ' WHERE Title='title' AND ThesisNo =123 AND [Type]='type' AND [Language]=' Language' AND [SubmitDate] BETWEEN 2000 AND 2021 

But if there are empty fields. What should I do. Should i write code for every probability

o' Search Enstitute Supervisor Name University Author Name Subject Thesis No Thesis Type Thesis Name Language SEARCH Year

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Information Modeling And Relational Databases

Authors: Terry Halpin, Tony Morgan

2nd Edition

0123735688, 978-0123735683

More Books

Students also viewed these Databases questions

Question

How are members held accountable for serving in the assigned roles?

Answered: 1 week ago