public static Insert ( bool dbconOpened, string uniqueID, string name, string sex, DateTime dateBorn, int race, int countryID, string description, int serverUniqueID ) : int | ||
dbconOpened | bool | |
uniqueID | string | |
name | string | |
sex | string | |
dateBorn | DateTime | |
race | int | |
countryID | int | |
description | string | |
serverUniqueID | int | |
return | int |
public int InsertAtDB(bool dbconOpened, string tableName) { int myID = SqlitePerson.Insert(dbconOpened, uniqueID.ToString(), name, sex, dateBorn, race, countryID, description, future1, serverUniqueID); return(myID); }
//coming from compujump server public Person(bool insertPerson, int uniqueID, string name, string rfid) { this.uniqueID = uniqueID; this.name = name; this.sex = "M"; this.dateBorn = DateTime.Now; this.race = Constants.RaceUndefinedID; this.countryID = Constants.CountryUndefinedID; //1 this.description = ""; this.future1 = rfid; this.serverUniqueID = Constants.ServerUndefinedID; /* * Before insertion check that uniqueID exists locally * can happen when there are rfid changes on server */ if (insertPerson) { SqlitePerson.Insert(false, uniqueID.ToString(), name, sex, dateBorn, race, countryID, description, future1, serverUniqueID); } }