File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Android and the fly likes problem comparing 2 arraylist values in android Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Make it so: Java DB Connections & Transactions this week in the JDBC forum!
JavaRanch » Java Forums » Mobile » Android
Bookmark "problem comparing 2 arraylist values in android" Watch "problem comparing 2 arraylist values in android" New topic

problem comparing 2 arraylist values in android

pourush rohila

Joined: May 04, 2012
Posts: 11
i am creating an android application in which i want to access database from mysql for user name, phone no and email address. and i want to compare phone no from android phone contact list and the phone no getting from mysql database. for that purpose i use 2 arraylist 1st for phone contact and 2nd for mysql phone no. my main problem is when i compare both the arraylist then i shows no result. i attach here the code please someone help me to solve this problem.

and this is my php code from which i access details

Steve Luke

Joined: Jan 28, 2003
Posts: 4181

Log all the values from both locations and see that they should match.

Then log what happens in each comparison: which value is being compared to which value.

When you see two things that should be equal and aren't then there is a problem that needs to be addressed. But right now we have no idea if there are no entries in one or the other list, or if they are in a different format, etc... So you need to see exactly what is being compared to narrow the problem down.

I agree. Here's the link:
subject: problem comparing 2 arraylist values in android
It's not a secret anymore!