Long distance pipelines are considered as the vein of the oil and gas industry on land and offshore. A well often produces water along with crude oil. The presence of water as well as dissolved gases such as CO2 and H2S introduces a serious menace of internal corrosion. It is well known that the distribution of water and oil inside the pipeline has a great influence on the corrosion rate. As a matter of fact, internal corrosion occurs when a free layer of water comes in contact with the pipe. Hence, predicting the distribution of water inside the pipe and identifying the continuous phase that directly wet the wall is of foremost importance when dealing with internal corrosion of oil pipelines. The accurate prediction of the distribution of water significantly increases the accuracy of corrosion prediction as well as the confidence regarding the integrity of the pipelines. In spite of all the great efforts toward studying different influential factors associated with the internal corrosion of steel pipelines, a large gap of knowledge is observed in predicting the water wetting. The objective of the present study is to employ a tuned two-fluid model by taking advantage of computational fluid dynamics, that is capable of predicting the distribution of water and the type of wetting (water wetting/oil wetting) at the bottom of the pipe. Furthermore, the effect of different parameters such as pipe diameter, oil density, oil viscosity and interfacial tension on the transition from water wetting to oil wetting is studied