Prepositions usually occur in front of a noun phrase, so the only way there can be more than one in a row is if the noun phrase itself is a prepositional phrase, as in the example He looked up from under the table, where under the table is the location that is the complement of from. Note that up here is not a preposition but a particle belonging to look up.

It might be possible to have contrived sentences where a large number of prepositional phrases are nested that way. However, it has been an old battle in linguistics to distinguish between what is possible from what occurs in reality, the Chomskyan competence vs performance distinction. So it might theoretically be possible to have an unlimited number of prepositions in a row, in reality there will rarely be more than two, and maybe three of four in contrived sentences.

The same reasoning applies to embeddings (The mouse that the cat that the dog that the boar that the man hunted attacked chased killed died.), where you can come up with really difficult and hard to understand sentences, which nobody in their right mind would ever say (apart from the authors of linguistics papers!), but which are nevertheless grammatically correct, as grammars don't usually put numerical limits on the number of relative clauses or prepositional phrases you can string together.

So my answer is: in theory, everything is possible, but it doesn't happen in practice apart from exceptional cases.