I have a table with column entry for every hour (TableA) and I'm converting it to a table with a row for every hour (TableB). I'm creating a stored procedure to help, beacuse every day there will be a new entry in TableA to convert to the TableB. I've chosen to do it with 24 insert statements, one after another, with a cursor reading out of TableA.
Now the problem is that when I exceute the stored procedure, the inserts don't insert. But I don't get any errors either. It does read the data, gets to the right code, completes the code, and go on to any other entries in the cursor, but no inserts. If I run the exact same code in query, it works fine and does all the inserts.
I'm using mssql 2005 express for testing purposes but will eventually move to 2005 Standard.
Now the problem is that when I exceute the stored procedure, the inserts don't insert. But I don't get any errors either. It does read the data, gets to the right code, completes the code, and go on to any other entries in the cursor, but no inserts. If I run the exact same code in query, it works fine and does all the inserts.
I'm using mssql 2005 express for testing purposes but will eventually move to 2005 Standard.