Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6875851
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T04:24:21+00:00 2026-05-27T04:24:21+00:00

I got a big Facebook-application coming up. It is programmed in php using mysql

  • 0

I got a “big” Facebook-application coming up. It is programmed in php using mysql (and the mysql_-class, not PDO…I know, I know). As I am close to an open beta, I’d like to keep track of any mysql-errors. I have a good host and I know that the script never looses connection to the database, so I thought I could store this in a table.

I’d like to keep track of the query doing failing (not a problem), but I’d also like to know what line and file this happened in. I’ve seen __LINE__ in a few scripts, but I never figured out how to use it.

My base simply looks like this:

$query = 'SELECT * ...';
$result = mysql_do_query($query);

function mysql_do_query ($q) {
    [...]
}

My real question is; is it possible to log where the function mysql_do_query was called from? What line etc. Or is there another way to do this? Try and exceptions, perhaps?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T04:24:21+00:00Added an answer on May 27, 2026 at 4:24 am

    You can use magic constants, or debug_backtrace, or write your own error handler.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've got a big Windows legacy application composed by many executables interacting with a
I've got one really big .java class file that has a lot of members.
I got a big prob with mathematica(using version 8). Plotting a Voronoi Diagram is
I've got a big project written in PHP and Javascript. The problem is that
I've got a big problem with encoding. The code I'm using should work but
I've got some big C programs, and I would like to know when I'm
sometimes, we got a BIG file, but we don't know its file type. so
Working on a database class that got quite big, and is likely to get
have someone used quercus to translate php into bytecode? if you got a big
I got a Big hierarchic class that i would like to loop all it's

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.