The porblem isnt the table structure. Its the loop. Ive just quoted MS SQL syntax as that's how to do it in MSSQL. I just want to run a simple insert query multiple times in a loop. Im now sure how to define the loop in a way that My SQL understands.