Really? I thought the whole point of the Throw Exception was to see if there was a table and/or connection being made to the database, if not, it should throw an exception error
you can use an exception for that, but you can use it for any other error handling as well. and as the code indicates, it is used for checking a falsy return value of the query (which may be a primitive or an object, depending on the used implementation).
anyways, neither PDO nor mysqli let you handle connection errors like that. PDO always throws its own exception and mysqli always returns a connection object (unless you make mysqli throw its own exception) i.e. you have to explicitly test for connection errors.
Where can I get Java version 8 update 60? I think this is mucking up the script, it’s hard to explain, but ever since I’ve had this installed I’m sure u65 is the cause of the problem
Hi, I’m glad you got it working. But you should never use string concatenation to build queries - you risk SQL injection this way. Please use prepared statements with bound variables as explained here.