Echo number of records in a database based on multiple criteria

Completed Posted 3 years ago Paid on delivery
Completed Paid on delivery

Hi There,

I have a web form that some fields can be filled like google search suggestions.

Ex If I start typing in a field it will give me suggestions based on the data inside the database, and then I can choose the name I want, that works for First Name , Last Name and Second Last Name.

When this Fields are filled I want to be able to count how many rows are with that name in the database and echo the number of rows that match that criteria.

ex: First Name : Sara Lastname: Underword SecondLastname: Collins

So I want to echo how many Rows containing Sara Underwood Collins there are,

I was thinking of something like this:

$query = "SELECT COUNT(*) c FROM Table WHERE FirstName = 'valueontheform' and LAST Name = 'valueonthefom 'and Second Last Name ='valueontheform' ;

$result = mysql_query($query);

$row = mysql_fetch_assoc($result);

echo $row['c']; //Here is your count

PHP MySQL JavaScript Software Architecture

Project ID: #25765642

About the project

12 proposals Remote project Active 3 years ago

Awarded to:

(28 Reviews)
4.7

12 freelancers are bidding on average $25 for this job

proy89

Hello, I can write the MySQL queries you need with table joining statements and where clause parameters from form. I have long experience of handling MySQL with PHP, I shall produce exactly what you need. Please get in More

$30 USD in 1 day
(155 Reviews)
6.8
shanymathew

Hello Sir am expert In mysql queries I can do it perfectly please message to me wish to work for you Thank You

$30 USD in 1 day
(68 Reviews)
5.4
deepthi2889

Hi, I am a Full stack developer in Microsoft technologies.  My area of expertise is web application development (Web API, ASP.Net web forms, MVC, classic ASP), web services (SOAP & RESTFul), MySql & Sql Server as back More

$30 USD in 1 day
(13 Reviews)
5.3
fugus

Hello, I am a fullstack developer using PHP and bootstrap. I can help you auto search and get the values from the database. Come over the chat we discuss more. Thank you

$30 USD in 1 day
(20 Reviews)
3.8
manuvelsubin

Hi, I hope you doing well. I have 8 year experience in Web and Database Administration. Yes we can get the count based on condition. I have hands off experience in the following * RDBMS * Index * Join * Union * Aggr More

$18 USD in 1 day
(6 Reviews)
2.7
shiveshk05

Dear client, Greeting. I am expert at PHP,MYSQL And also I can start right now I am Software Engineer out of Bangalore.I have 5 years experience in mostly in PHP,several PHP frameworks,Algorithms and data structure, More

$30 USD in 7 days
(3 Reviews)
1.5
tuongnd

- 10 + years of software experience. - Built modern applications with PHP LARAVEL, REACT NATIVE, NOTEJS, FIREBASE. - Database: SQL Server, My SQL, Oracle. - Developed microservices and Web Services (incl. REST/SOAP/WSD More

$20 USD in 7 days
(0 Reviews)
0.0
himmat1005

Hi, I have 4 years experience with PHP, Javascript & MySql. Based on my understanding, you are having issues with database query only. Just to understand it better, I have given thin problem 2 days. Looking forwar More

$12 USD in 2 days
(0 Reviews)
0.0
DeSpense

Hello, I can tell you without any project award that all you need to do is use the mysqli_num_rows() function. If you need help implementing this in your code, let me know. Thanks!

$15 USD in 1 day
(1 Review)
0.0
compadsl

Sure, We have already helped many organizations with in-depth reports and dynamic parameters too. Let's connect and discuss using chat.

$50 USD in 7 days
(0 Reviews)
0.0