Preheat an oven to 350 degrees F (175 degrees C). Grease a 9x13-inch baking dish.
Beat the pineapple, coconut, sweet potatoes, white sugar, eggs, vanilla extract, milk, and 1/2 cup melted butter together in a large mixing bowl until smooth. Pour mixture into the prepared pan; set aside. Mix the flour, brown sugar, 1/3 cup butter, and pecans in a bowl. Sprinkle pecan mixture over the batter.
Bake in the preheated oven until the casserole is bubbly and the topping is browned, about 30 minutes.