Is the second sentence acceptable? Do the two sentences mean the same and can they be interchangeable? What's the difference between them?
The context is simple:
I entered the room and looked around. On the table (there) was a jug. I came up to the table and ... etc.
If I were a native speaker of English, I would never shut up. :-)
Both are grammatical and identical in meaning. The second is less frequently used.
(Since you just entered the room, the reader doesn't know there is a table. You could say "a table" because it's new information. You could stick with "the table" to show there is one and only one table in this room. Article are tricky. Also, "I went up to the table" sound more natural to me.)
I'm not a teacher, but I write for a living. Please don't ask me about 2nd conditionals, but I'm a safe bet for what reads well in (American) English.