Suppose that
$mycon
is a connection object of type
mysqli
...
$result = mysqli_query($mycon, $query) or die (mysqli_error($mycon));
It seems that you copied the description from the PHP mysqli help site, without understanding what you done!!!
It is very advised to learn before to code!!!