sql server 2008 - How to make a SQL table bigger -


I have a table with data as 100 rows

  a1 a2 a3 .. --------- 1 2 3 23 55 4 2 3 7 I use the  UNION ALL  to enlarge that table I'm planning to do  
  a1 a2 a3 ... --------- 1 2 3 23 55 4 2 3 7 1 2 3 23 55 4 2 3 7 1 2 3 23 55 4 2 3 7   

This is for testing purposes, so what do you suggest, what would be the most effective way to do this?

This will increase the size of your table faster ... earlier this X record, 2x, 4x, 8x Inserts ... If you want to add the same number of records only if you select different or top n , etc.

  DECLARE @ counts int DECLARE @max int SET @ count int = 1 SET @max = 10 WHILE @ country & lt; Insert in the max @ myTable (a1, a2, a3) select myTable SET @count = @count + 1 END   

Select A1, A2, A3 from BTW - Not sure what you are trying to test, but you can add anything other than the entire numbers in your data set - like, 1.01, .99, 55.7, 60, etc.

Edit

For your comment - if you want actually to use union All then ...

  enter in myTABLE (a1, a2, a3) to choose from a1, a2, a3 (SELECT a1, a2, a3, myTable UNION Select a1, a2, a3 to myTable UNION ALL select a1, a2, a3 to myTable ...) a    

Comments

Popular posts from this blog

mysql - BLOB/TEXT column 'value' used in key specification without a key length -

c# - Using Vici cool Storage with monodroid -

python - referencing a variable in another function? -