Die Frau oder Der Frau
Which one of these is correct? Der Frau gefällt das Hotel. Die Frau gefällt das Hotel.
Please help in understanding it better
That's right. Because of the declination, we can pretty much play around with the order of the constituents of a sentence.
For example: der Mann liebt den Hund or den Hund liebt der Mann. Both sentences mean that the one who is being loved is the dog, and the one who loves is the man.
Den Mann liebt der Hund or der Hund liebt den Mann. In this case, the one who loves is the dog and the one who is being loved is the man.
So, it depends on what you want to emphasize in the speech act.
Dem Mann gibt der Junge den Hund
Den Hund gibt der Junge dem Mann
Der Junge gibt dem Mann den Hund.
It doesn't always work because some cases have the same article (particularly nominative = accusative for nouns except for masculine singular, so die Frau sieht die Katze could have either the cat being seen by the woman or the woman being seen by the cat), but often does.
It is "Der Frau gefällt das Hotel" (you could also write "Das Hotel gefällt der Frau").
"Der Frau" is in the dative case, it is correct.
In a sentence as "X gefällt Y", either X or Y must be in the dative case. In our example, "der Frau" is dative (and "das Hotel" is not dative).
German has case inflexion, which is mostly present in the articles.
It is true that Frau is feminine and uses the article die, but die is only the nominative and accusative of the feminine article, while the verb gefallen requires the dative case (as in "Mir gefällt das Hotel"), so the genitive/dative form of die, which is "der", is necessary here.
Note that this der is not the same as the masculine article der, they simply happen to be written and pronounced the same way.
Here is the full declension of German articles:
Case - Masc. Fem. Neut. Plur.
Nom. der die das die
Acc. den die das die
Gen. des der des der
Dat. dem der dem den
It's a matter of cases. You could say "Die" is the default feminine article (nominative) meaning "the" that is attached to the noun "Frau", BUT "der" is the inflected form of "Die" that is in the "dative case", used to indicate grammatical agreement with an indirect object. (Sounds complicated, but trust me, it gets easier). "Der" is also, of course, the "default masculine article" (again, nominative) that is used for masculine nouns, which is a coincidence. Its "dative" case is "dem".
Think of it as "Die" meaning "The", while "der" meaning "to the" in its dative form. The sentence you're asking about would be: "Der Frau gefällt das Hotel", which we know would mean "The woman likes the hotel", BUT it would rather literally mean something like (this will sound strange): "To the woman appeals the hotel" (OR in proper English: "The hotel appeals 'to the' woman").
This image should be useful, although I recommend visiting this link below: