Permalink
Browse files

Wired v2 database up to Android app and limited squad number of curre…

…nt players to under 26
  • Loading branch information...
MikeHook committed Nov 27, 2011
1 parent 1283201 commit f0cd0838c0b39f13db1d1c7c47687c59aaeb4ba2
Binary file not shown.
Binary file not shown.
@@ -37,6 +37,7 @@
public static final String Name = "Name";
public static final String CurrentClub_id = "CurrentClub_id";
public static final String _id = "_id";
+ public static final String SquadNumber = "SquadNumber";
}
private static final String TAG = "DatabaseAdapter";
@@ -90,7 +91,8 @@ public Cursor getPlayerByCurrentClub(int clubId) throws SQLException {
Cursor mCursor =
sqlLiteDatabase.query(true, Tables.Player,
new String[] {PlayerColumns._id, PlayerColumns.Name, PlayerColumns.CurrentClub_id},
- PlayerColumns.CurrentClub_id + "=" + clubId,
+ PlayerColumns.CurrentClub_id + "=" + clubId +
+ " AND " + PlayerColumns.SquadNumber + "< 26" ,
null, null, null, null, null);
if (mCursor != null) {
moveCursorToRandomPosition(mCursor);
File renamed without changes.
View
Binary file not shown.
Binary file not shown.

0 comments on commit f0cd083

Please sign in to comment.