Welcome Guest, Not a member yet? Register   Sign In
Best solution for custom / unplanned fields in database?
#2

[eluser]xzela[/eluser]
No, adding or removing columns on the fly is dangerous. It can lead to corrupted databases. Modifying the structure the database is generally a bad idea unless you are doing controlled maintenance (preferably with no users logged in currently writing to tables).

I have often thought about this idea (adding custom fields) myself. What I think you can do to solve this type issue is to cast the fields based on their data_type. It's easier/safer to do this in strongly-typed language like Java.
http://java.sun.com/docs/books/tutorial/...types.html

PHP is not known for it's strong data types but it can be done. I'm not sure if this helps.

Best of luck on your project.


Messages In This Thread
Best solution for custom / unplanned fields in database? - by El Forum - 05-22-2009, 06:49 PM



Theme © iAndrew 2016 - Forum software by © MyBB