D
D
Dilik Pulatov2018-12-18 13:55:11
Oracle
Dilik Pulatov, 2018-12-18 13:55:11

How to get resource from Oracle Sql in Yii2?

Hello! For the first time I work with a DB .
I get a message list in the form of an array ... and there are text fields, but it comes with such a line
Resource id #148
found out that this is some kind of resource ... and it can be obtained from the stream_get_contents function,
but the problem is that stream_get_contents is somehow strange works...for example

foreach ($messages as $mes) {
    echo stream_get_contents($mes['text']);
}

but as a result I get only single values.
for example, there are several letters "Hello", "How are you?", "here?"
and i get like this
"тут?"
"тут?"
"тут?"

what am I doing wrong?

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question