Can someone tell me how to declare a composite primary key in Android 1.6 which includes an autoincrement _id column? I am not sure of the syntax. As a result, I just used it in Java when I try to add values ββ(where dateNumber + date must be unique in the table):
Cursor fuelUpsCursor = getFuelUps(registrationNumber, date); if(!fuelUpsCursor.moveToNext()) { //add registrationNumber and date }
I really donβt need the _id column, but it can make life difficult if the tables do not.
Cheers, Barry
source share