0

here example INSERT INTO table_name( user_id, user_balance) VALUES( 1, 500)

but in my case I need insert 1000 'user_id' from 1-1000 with same 'user_balace' for all user(500), how make function instead calling 1000 times one code

  • for example I need it do that – Roma Sovach Mar 30 '18 at 14:03
  • 4
    btw; you've many unclosed questions. The ones that were solved would help everyone to know they were solved. – Funk Forty Niner Mar 30 '18 at 14:03
  • Just set the default value for `user_balace` to 500, then every user that gets created will have that value. – chris85 Mar 30 '18 at 14:04
  • aha understand , I will check , anyway thank you – Roma Sovach Mar 30 '18 at 14:05
  • See https://meta.stackexchange.com/questions/5234/how-does-accepting-an-answer-work for how to resolve previous questions. You can see https://stackoverflow.com/questions/11312433/how-to-alter-a-column-and-change-the-default-value for how to set the default. – chris85 Mar 30 '18 at 14:05

0 Answers0