You can handle this many ways depending how you wish to design your system. Below is a simple concept based on the existing tables to give you an idea. There are other ways to do it just what I came up with quickly.<div>If you didn't want to have to touch any of the core of nibblebill you could add additional fields to accomplish your goal.</div>
<div>You could add a field such as tenantid type int(11).</div><div><br></div><div>Company A = tenantid 1</div><div>Company B = tenantid 2</div><div>....</div><div><br></div><div>id | tenantid | name | cash</div><div>1 | 1 | Bob | 5.00</div>
<div>2 | 1 | Joe | 6.00</div><div>3| 2 | George | 7.00</div><div><br></div><div><br></div><div><br></div><div>As far as varchar vs int perhaps from a user conception varchar might be more straight forward in a single table but should you start doing queries across multiple tables to avoid data duplication numerical identification fields are common.</div>
<div><br></div><div>Like my rough example above I'd need to keep another table store the details on the tenants</div><div><br></div><div>Hope that helps get you started.</div><div><br></div><div>-- W</div>