On testing the system on the before described database table structure, I found that the system crashed when duplicate entries were added to the database, as the database would throw an error when duplicate entries would be added to the "group_users" table and the DAO library would thus call the die function, due to error in executing the database query.
For eg.
If groupname1 has already been created by author-1 and user-2 is in this group, then again groupname1 with user-2, should not be created by the same author-1 on pressing the Create Group button.
This step was giving errors due to duplicate entries being entered to the database.
So in order to resolve the issue, the database is now first queried if the row is already present in the database and if the row is already there, and if the entry is missing in that case it's added to the database.
No comments:
Post a Comment