How to add columns to a table without neither re-creating it nor using the alter table command

  • jose_anisha (5/6/2009)


    The table currently has 538 columns.....it needs to b updated every week almost .....each time 5- 10 columns needs to b added to the table

    Alright, NOW I am going to go back to what everyone else has been saying: this seems very non-relational. I would guess that this design is missing at least one level of abstraction that it ought to have. Continuously adding columns to a table is not proper relational design.

    [font="Times New Roman"]-- RBarryYoung[/font], [font="Times New Roman"] (302)375-0451[/font] blog: MovingSQL.com, Twitter: @RBarryYoung[font="Arial Black"]
    Proactive Performance Solutions, Inc.
    [/font]
    [font="Verdana"] "Performance is our middle name."[/font]

  • jose_anisha (5/6/2009)


    The table currently has 538 columns.....it needs to b updated every week almost .....each time 5- 10 columns needs to b added to the table

    Could I ask why you have a table with so many columns and how you are using it?

    ---
    Timothy A Wiseman
    SQL Blog: http://timothyawiseman.wordpress.com/

  • Hi

    Well, I'm completely with Barry and Alvin and Timothy. Let me take Timothy's last question:

    Could I ask why you have a table with so many columns and how you are using it?

    I think the problem is not how to add new columns to a table but the why? Jose, I'm quiet sure you are more an application developer than a database-developer/DBA. Could you please explain a little bit more detailed what your table does and how you use it in your program. There is a huge difference in the usage of arrays in front-end and tables in back-end.

    I think there are many design approaches which can help you to fix your database structure without limit the features in front-end.

    Greets

    Flo

  • I concur with Florian and everyone else!

    I read the 538 cols growing byb 10 a week and upset the IT guys sitting opposite my desk by shouting 'WTF' out suddenly... rofl. (you'd think they would be use to it by now!)

    You need to look at redesign for all the reasons mentioned. It's not a relational design you have there.

    and um you owe kev in IT a replacement latte.....

Viewing 4 posts - 16 through 18 (of 18 total)

You must be logged in to reply to this topic. Login to reply