Solved

mysql_db_query is deprecated

Posted on 2001-08-25
3
632 Views
Last Modified: 2006-11-17
Anyone ever see this error before?

Warning: mysql_db_query is deprecated; use mysql_select_db() and mysql_query() instead in c:\inetpub\wwwroot\phpmyadmin\sql.php on line 56

It started after I updated to PHP4.
0
Comment
Question by:steveyoder
3 Comments
 
LVL 4

Accepted Solution

by:
heddesheimer earned 50 total points
ID: 6425185
The error tells you what you should do. Since PHP 4.0.6 you should not use mysql_db_query. You should replace this:

$link = mysql_open(...);
$result = mysql_db_query ($database_name, $query ,$link);

with this:

if ( mysql_select_db ($database_name ,$link);
{
  $result = mysql_query($query);
}

Marian
0
 
LVL 5

Expert Comment

by:LornaJane
ID: 9758244
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:
accept comment from heddesheimer
Please leave any comments here within the next seven days.

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!

LornaJane
EE Cleanup Volunteer
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Consider the following scenario: You are working on a website and make something great - something that lets the server work with information submitted by your users. This could be anything, from a simple guestbook to a e-Money solution. But what…
I imagine that there are some, like me, who require a way of getting currency exchange rates for implementation in web project from time to time, so I thought I would share a solution that I have developed for this purpose. It turns out that Yaho…
The viewer will learn how to count occurrences of each item in an array.
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now