• Home
  • Map
  • Email: mail@softload.duckdns.org

Mysql error message supplied argument

The argument to mysql_ affected_ rows should be a resource returned by mysql_ connect, not a resource returned by mysql_ query. Or it could be omitted entirely. There a number of ways to fix this, however the best way is to return the mysql resource and then assign that resource to the. As a rule of thumb, 99% of errors are due to given or the immediately previous line or statement. This error means your query failed. mysql_ query( ) returns false if an error occurred, you are then passing false to mysql_ fetch_ array( ) which is triggering the error message. Your query could be failing due to a missing/ wrong. Based on the comments, it sounds like the problem is caused by using require_ once( ) inside a function. One of two thing is happening. Either: You' ve already included Connection. php somewhere else, so when you get to the. When I said use mysql_ error( ), I meant only if there was an apparent error. $ result = mysql_ query( $ query) ; if ( false = = = $ result) { throw new Exception( ' Error in query you have, hmmm: '. mysql_ error( ) ) ; } / / and so on.

  • 爬虫 error 503 service temporarily unavailable
  • Jekyll error 404 page
  • Standard json error format
  • Error 503 apache proxy


  • Video:Error supplied argument

    Supplied mysql error

    I got the error " mysql_ fetch_ array( ) : supplied argument is not a valid MySQL result resource. On the lines that concern this mysql query. $ result = mysql_ query( " select * from chat order by time desc limit 0, 10" ) ; $ messages = array( ) ;. The second argument to mysql_ query should be a link identifier. You are using $ db as the second argument, which is nothing but a boolean value. $ result = mysql_ query( $ query, $ link) ;. or just don' t pass any second argument. up vote 0 down vote. Also mind that mysql_ query( ) dealing with INSERT returns true on success and false on failure. Returns the error text from the last MySQL function, or ' ' ( empty string) if no error occurred.