Jump to content

MySQL Problems


Recommended Posts

Hey guys, can you help me with it?

It doesn't say me if connection was succesfull or failed and I tried registration script (mysql_insert_id) but doesn't work too.

This is my code:

  
     connection = mysql_connect("localhost", "root", "", "phis_db") 
        if ( not connection) then -- Connection failed 
            outputDebugString("Unable to connect to MySQL!") 
        else 
            mysql_close(connection) 
  

Link to post

try this:

  
  
     connection = mysql_connect("localhost", "root", "", "phis_db") 
        if not (connection) then -- Connection failed 
            outputDebugString("Unable to connect to MySQL!") 
        else 
            mysql_close(connection) 
  

Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...