Append logic does not follow through - Write data table error / bug

I think this is the solution to my problem. but it still doesn’t explain why it isn’t working.