January 30th, 2013, 09:05 AM
Form submission creates table
I have a odd request, not sure how to do this.
I have a database called customers. I need to create a form whereby the customer fills in their information and when they "submit" it creates a new table using fields from the form.
So, to help me, form has 2 fields (more, but for purposes here).
When they click submit, it creates a table called CompanyName in the customers database and it has 2 fields, CompanyName and EmployeeNumbers
Can someone help me out with that?
January 30th, 2013, 09:39 AM
letting users create their own tables in the database makes no sense. It's just none of their business, and you can easily end up with a total mess of dead tables (typos, nonsense names etc.).
So this is not a good idea. Creating tables and managing the database is your responsibility. So create a generic "company" table and insert a row for each form submission.
Comments on this post