Sorry to bring subject to again.
Before i was using mysql_query but because the change the php version i
migrate to query.

I read in de somewhere that GAE not work with mysqli, you managed to make
it work



Victor Alves
Fones:  3892-7580
Celular: 9.4711-7418

A dúvida é o princípio do conhecimento.


AVISO LEGAL: "As informações existentes nesta mensagem e nos arquivos
anexados são para uso restrito. A utilização, divulgação, cópia ou
distribuição dessa mensagem por qualquer pessoa diferente do destinatário é
proibida. Se essa mensagem foi recebida por engano, favor excluí-la e
informar ao remetente pelo endereço eletrônico acima."


2017-10-28 18:14 GMT-02:00 Lendi App <[email protected]>:

> Hi,
>
> I am receiving  mysqli_connect(): (HY000/2002): php_network_getaddresses:
> getaddrinfo failed: Name or service not known
> I have the following
> $socket_prod=":/cloudsql/projectid:europe-west1:databaseinstance";
> $dbuser_prod="root";
> $dbpass_prod="root_pasw";
> $dbname_prod="db_name";
>
> $conn = mysqli_connect($socket_prod,$dbuser_prod,$dbpass_prod,$
> dbname_prod);
>
> I have  an Google Engine App running  a php service trying to connect to a
> Google SQL instance in the same project.
>
> Any help?
>
> On Wednesday, June 7, 2017 at 10:05:23 PM UTC+2, SPED MAKER wrote:
>>
>> i did have the same problem..
>> You no need use a global variable available in app.yaml.
>>
>> the sample suggest to use:
>>  'mysql:unix_socket=/cloudsql/testproject-xxxxxx:us-central1
>> :library;dbname=books',
>>  but like you said, this method works to PDO....
>>
>> to connect with mysql_connect you can use:
>> $server = ":/cloudsql/INSTANCE_CONNECTION_NAME";
>> $user = 'root'
>> $pass = "pass";
>>
>> mysql_connect ($server,$user,$pass);
>>
>> not forget to use :/cloudsql/...
>>
>> if to function to you, talk here please.
>>
>> --
> You received this message because you are subscribed to a topic in the
> Google Groups "Google App Engine" group.
> To unsubscribe from this topic, visit https://groups.google.com/d/
> topic/google-appengine/IZgep9t3LbI/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> [email protected].
> To post to this group, send email to [email protected].
> Visit this group at https://groups.google.com/group/google-appengine.
> To view this discussion on the web visit https://groups.google.com/d/
> msgid/google-appengine/c1544e09-4d77-41ad-a4d3-
> 1c1aa8b0def4%40googlegroups.com
> <https://groups.google.com/d/msgid/google-appengine/c1544e09-4d77-41ad-a4d3-1c1aa8b0def4%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/CAO6%2B3rhFNEtb2h2-eZrHpHdNup3_-cLtoBQfF1MJE2evd%2BFazA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to