Oracle is buying cloud-based business-to-consumer marketing software company Responsys for about $1.39 billion.

Oracle, which also makes , said that the deal will extend its offerings of cloud businesses. It already offers cloud-based opportunities for sales, commerce, service, social and marketing activities.

Earlier this week, Redwood Shores, California-based Oracle reported that its fiscal second-quarter net income edged down slightly, hurt by flat revenue from new software licenses and cloud subscriptions. The performance still beat Wall Street's view.

Under the deal announced Friday, Oracle will pay $27 per Responsys Inc. share, a 38 percent premium to the company's Thursday closing price of $19.52.

Responsys' board unanimously approved the deal. The acquisition is targeted to close in the first half of next year.

Responsys currently has approximately 51.4 million outstanding shares, according to FactSet. The companies put the transaction's value at about $1.5 billion.

The companies will continue to operate independently until the buyout is complete.

Responsys shares climbed $7.38, or 38 percent, to $26.90 in morning trading Friday. Oracle Corp.'s stock added 3 cents to $36.63.

.