I have weird problem. I don’t have a domain name for my remote mysql database, so on my development machine I usually just connect to a remote mysql using the ip address. On my development machine the ip address connection works for both mysql and mysqli connections. However, when I upload to my live server (CentOS) (also connecting to the
Tag: mysqli
What the different between MySQL Native Driver and MySQL Client Library
I want to know the different between MySQL Native Driver and MySQL Client Library and when to use both of them
How to set a collation with mysqli?
My database uses utf8_czech_ci collation and I want to set it to my database connection too. Mysqli_set_charset won’t let me set collation, if I don’t happen to want the default one, utf8_general_ci. Here was suggested first to set the charset through mysqli_set_charset and then to set collation by SET NAMES. So I did it and connection collation is still utf8_general_ci.
How to output mysqli_fetch_field_direct?
I’m trying to convert this code from mysql to mysqli. But when I print it and open in excel file I got an error. Catchable fatal error: Object of class stdClass could not be converted to string in C:xampplitehtdocsapptext2.php on line 139 Can someone Teach me how to convert this code in mysqli correctly? And this the error line Answer
Moving from mysql to mysqli – problems
I have the following code: $query3 = “SELECT Office, COUNT(Office) As Tot_Part, (SELECT COUNT(Office) FROM trespondent WHERE completion_status= ‘Started’ OR completion_status = ‘Complete’) As …
How to fix Error while reading greeting packet?
I am trying to connect to server in NetBeans. I write the code as below: Running of this code return this erreurs: Answer MySQL can be configured to not accept external connections, for security reasons. By saying the full domain name, you are using the public IP and therefore you are an external connection. If MySQL is running on the
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ”
Using a form, I was trying to insert data into my database. The initial SQL query had variables for values, but it didn’t work. After trying a few things and using mysqli_error I wasn’t able to find the problem. I then replaced all the variables with strings, still, my data does not insert. I’ve tried the below code nested amongst
how to bind multiple parameters to MySQLi query [closed]
This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, visit the help center. Closed 8 years ago. I have a mysql
MYSQLi query not producing expected results
I am having a problem getting results I can use from my query. Code: //Create query $stmt = $con->stmt_init(); $query = “SELECT * FROM `users` WHERE `userlogin` = ‘$username’ AND `user_passwrd`…
Bind Param with array of parameters
I have a function that does this: Which sends off to my database class, which does this: The problem is this doesn’t work. What I was hoping to do, was to take the $params list and have it list them after the $type, so that the query would resemble: But obviously I’m going about it the wrong way. is there