You are currently looking at Flamebate, our community forums. Players can discuss the game here, strategize, and role play as their characters.
You need to be logged in to post and to see the uncensored versions of these forums.
Viewing a Post
|
volatus Posted:
That string has to be stored in the database right?
So to read it, you need to query. To write it, you need to write a query to do that.
Now, from an efficiency point of view, looking for the occurrence of a letter in a string is slower than querying a database by index. Finding a letter in a string is O(n), finding a row by index in a database is O(n log n)
Not to mention, with the database index you get a guarantee that the same forum can’t be in there twice. With your method there is no guarantee of data integrity.
And many other reasons… |
||||||
Posted On: 11/24/2008 2:17PM | View Evil Trout's Profile | # |