Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
 
  HOME    TRACKER    MYSQL




Running Mysql Code Within A Php File?


I have been given a some mysql code that I have to run within a website - I am familiar with mysql in terms of insert info and querying a database but I at a loss as to how to make this work.

the mysql code works in mysqladmin, but how do I call it into my php code?

BTW the mysql code creates a new record in the database .......

Also, I need to tweak the code so it runs in a loop for different variables - in php I would run a FOREACH query, how do I do it in mysql?




View Complete Forum Thread with Replies

See Related Forum Messages: Follow the Links Below to View Complete Thread
Ever Thought About Running Mysql Without My.cnf File ?
I installed from source mysql on Fedora3 and started mysql demon without my.cnf by chance and it was running . I m wondering did it happen with somebody else too?

Running MySQL Using A Dos Batch File
I am used to use MySQL on Unix, now I have to do some development for MySQL running on Windows machine. The following script works well in Unix but I am unable to run it on Windows. "MY_FLAG" is the one which is causing issue. Due to certain restriction in my framework, I can use the normal batch by supplying the .sql file while opening the mysql connection ( infact i need to run multiple source files) Code:

Running Mysql Commands In A Batch File
I am trying to automate a mysql command to upload data everymorning on a windows server. I have created a .bat file and entered the commands to login to mysql but when it gets to the mysql prompt it fails to complete the rest of the commands.

cd
c:
cdmysqlin
mysql
TRUNCATE TABLE blah
LOAD DATA INFILE 'blah.txt' INTO blah
QUIT
exit

Is this possible?

Running Existing .sql File In Mysql Command Prompt?
I've seen "examples" of this in my book on MySQL, but it just shows the file on the prompt. It says that I can run an existing sql file - for creating a table - right from the prompt.

However, it doesn't really explain how to do this in detail. I've tried :

-h host - u user -D database -p < myfile.sql

but it gives an error. How do I point it to the right file on my system?

Running An Existing SQL File
I hope this question is not too 'newbie' to answer.. I'm reading a book (PHP and MySQL web development by Luke Welling and Laura Thomson), and am getting an error on an example script.

I'm trying to create tables using an existing SQL file through MySQL. According to the book, it should be done like this:

> mysql -h hostname -u username -D database -p < file.sql
(I've changed the hostname, username, etc.)

However, I get the same error over and over again: ERROR 1064 (42000): ... at line 1. The book didn't even mention where to put the file, I've tried all sorts of things, but can't get it to work..

Running Script File
I want to write mysql code like create table ... and insert into ...
in text file and run the codes in mysql.
I have installed mysql in my machine windows xp. and the help says the mysql> source (filename) will work to run the code file. but it does no work. says could not open the file.
I am not sure where should i put my code file and the extension of the file required.

Sql Code To Import File Locally
I want to import a file to create tables in a database on my machine from command prompt, I have done this beofre but a long time ago, I have put the file in the bin folder of the MySql directory, i thought the code was something like ..file.sql

Can anyone tell me what it should be.

Running Sql File From Shell Script
When i run the command "mysql -h host - u user - p password -D database <file.sql" (the file.sql contains an Update Scrpit) from command prompt

/usr/test> mysql -h host - u user - p password -D database <file.sql

i am able to run the file and i am getting expected results.

When i copy the same string in a shell script (suppose in update.sh) and try running it from the command prompt

/usr/test> . update.sh

i get an error as "No file or directory found"

i tried giving in the full path of file.sql and tried running hte shell script but it gave me the same results "No file or directory found".

Running External .sql Text File
I have a database on a sever that is running some version of MySQL 4. I wan't to put the same database on my local computer.

I ran a MySQL dump from the server and tried to run the resulting text file from the UNIX command line on my computer (Running MySQL 5 on Mac OS 10.4). I always get error 1064:

CODEERROR 1064 (42000) at line 1: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '
CREATE TABLE 'art_type' (
  'art_type_id' tinyint(11) unsigned NOT NULL auto' at line 1

Error Code #1064 Trying To Import SQL File
Im trying to import an SQL query file but get this error:

#1064 - You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'DEFAULT CHARSET=latin1 AUTO_INCREMENT=1' at line 28


Here is the code and the last line is line 28:
-----------------------------------------

CREATE TABLE `carts` (

`id` int( 8 ) NOT NULL AUTO_INCREMENT ,
`visitor_id` varchar( 26 ) NOT NULL default '',
`photo_id` varchar( 7 ) NOT NULL default '',
`added` varchar( 14 ) NOT NULL default '',
`ptype` char( 1 ) NOT NULL default '',
`prid` int( 10 ) NOT NULL default '0',
`quantity` int( 10 ) NOT NULL default '1',
UNIQUE KEY `id` ( `id` )
) ENGINE = MYISAM DEFAULT CHARSET = latin1 AUTO_INCREMENT =1 .

Regular Text File How To Sql 2000 Table Code
i have a text file as follow, line with ¡°|¡±and {LF},

8|-000000186075919.|+000000000387820.|2008-03-31|20010423|
9|-000000000003919.|-000000000123620.|2008-03-31|20010123|
8|-000000018623419.|+000000000381230.|2008-05-30|20010423|

i want to sign char(1)£¬year decimal(18,3) , month decimal(18,3), trandate
smalldatetime£¬update smalldatetime£¬after to sql table is as follow,


sign year month trandate update
8 -186075919.000 387820.000 3/31/2008 4/23/2001
9 -3919.000 -123620.000 3/31/2008 1/1/2001
8 -18623419.000 387820.000 5/30/2008 4/23/2001

Access SQL Code &gt; MySQL Code (INNER JOINs)
I've basically created the following tables / queries as part of my first mySQL project :

Candidates
---------------
Candidate_ID (autonumber)
Name (text)
...

1, Iain
2, Fi
3, Rob


Vacancies
--------------
Vacancy_ID (autonumber)
Vacancy (text)
...

1, Cartographer
2, Gardener
3, Occupational therapist
4, Web designer
5, Recruitment manager


Profiles
-----------
Profile_ID (autonumber)
Profile (text)
...

1, Map making
2, Web design
3, Gardening
4, Hand therapy
5, Recruitment
6, Aviation
7, Sport
8, Travel


VacancyProfiles
----------------------
Vacancy_ID (number)
Profile_ID (number)
...

1,1
1,2
4,2
2,3
3,4
5,5
5,6

CandidateProfiles
--------------------
Candidate_ID (number)
Vacancy_ID (number)
...

1,1
1,2
1,7
1,8
2,3
2,4
2,8
3,5
3,6
3,7

and from there created two queries

CandidatesQuery
--------------------

SELECT Candidates.Candidate_ID, Candidates.Name, Profiles.Profile_ID, Profiles.Profile
FROM Profiles INNER JOIN (Candidates INNER JOIN CandidateProfiles ON Candidates.Candidate_ID = CandidateProfiles.Candidate_ID) ON Profiles.Profile_ID = CandidateProfiles.ProfileID;

1, Iain, 1, Map making
1, Iain, 2, Web design
1, Iain, 7, Sport
1, Iain, 8, Travel
2, Fi, 3, Gardening
2, Fi, 4, Hand therapy
2, Fi, 8, Travel
3, Rob, 5, Recruitment
3, Rob, 6, Aviation
3, Rob, 7, Sport

and

Vacancies_Query
-------------------

SELECT Vacancies.Vacancy_ID, Vacancies.Vacancy, Profiles.Profile_ID, Profiles.Profile
FROM Profiles INNER JOIN (Vacancies INNER JOIN VacancyProfiles ON Vacancies.Vacancy_ID = VacancyProfiles.VacancyID) ON Profiles.Profile_ID = VacancyProfiles.ProfileID;
...

1, Cartographer, 1, Map making
1, Cartographer, 2, Web design
2, Gardener, 3, Gardening
3, Occupational therapist, 4, Hand therapy
4, Web designer, 2, Web design
5, Recruitment manager, 5, Recruitment
5, Recruitment manager, 6, Aviation

Trouble is, I come from an Access background, and I think the syntax of mySQL SQL is different to Access SQL - in the case here for the INNER JOINs - could anyone help out with the syntax for the queries above in mySQL friendly SQL, as I'm a bit unsure of what it should be.

Update Several Columns In A Row - Postal Code Or Zip Code
Ok - I have 125 records. They all have different postal codes. I have a column named "Region". I want to update all postal codes starting with "V" to region "WST".

How can I do this? I know how to update on MASS based on the column, but can I what I need to do?

Java Code Or Pseudo Code For "Outer Join"
I want to implement the "outer join" functionality in Java. Can
somebody explain the pseudo code for the same. OR what needs to be done
to extend the hash-join Java code of equijoin.

MySQL Code
I am scripting In ASP and with a DSN connection to mysql. I need a script which can query the database to see if two fields (username or email address) which are both submitted by a user exist anywhere in the database.I have tried various scripts so far, but none seem to work.

PATH> User submits (joebloggs, joebloggs@hissite.com) > Check DB to see if either of these exist anywhere in the file.

Connection String :

'Init the DB Connection
on error resume next
dim adoConnstep
dim adoRSstep
dim strQuerystep
set adoConnstep = Server.CreateObject("ADODB.Connection")
adoConnstep.Open "DSN=mydsn"

I Cannot Get Php And Mysql To Talk, Help Please! My Code Is Below
Im on windows xp using mysql server 5.0, apache http server 2.0.59 and php 5.2.1.1 When I load the page it appears completely blank with just a white background. My code is below can anyone help please?
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Our List of Jokes</title>
<meta http-equiv="content-type" content="text/html; charset=iso-8859-1" />
</head>
<body>
<?php
// Connect to the database server
$dbcnx = @mysql_connect('localhost', 'root', 'root');
if (!$dbcnx) {
exit('<p>Unable to connect to the ' .
'database server at this time.</p>');
}

// Select the jokes database
if (!@mysql_select_db('ijdb')) {
exit('<p>Unable to locate the joke ' .
'database at this time.</p>');
}

?>
<p>Here are all the jokes in our database/p>
<blockquote>
<?php

// Request the text of all the jokes
$result = @mysql_query('SELECT joketext FROM joke');
if (!$result) {
exit('<p>Error performing query: ' . mysql_error() . '</p>');
}

// Display the text of each joke in a paragraph
while ($row = mysql_fetch_array($result)) {
echo '<p>' . $row['joketext'] . '</p>'
}

?>
</blockquote>
</body>
</html>

Is It Safe To Just Code For MySQL 4.1?
Is it safe to concentrate on just MySQL 4.1 in software that you offer for download / sell? Or should I still support MySQL 3.xx versions?
If 4.1 went into production status in october 2004 then most hosters should have updatet their servers by now, but I cannot be sure about that.

I never really looked at the new features 4.1 introduced up until now like Subqueries which are really useful and I would like to write just one DB driver.

Mysql Zip Code Database
Does anyone know where I can find an open source mysql zip code database

Converting To Code MySQL
DROP TABLE VENDOR
DROP TABLE PRODUCT

CREATE TABLE VENDOR(
VENDOR_CODE CHAR(2) NOT NULL CHECK(VENDOR_CODE IN('AR', 'MS', 'WW')),
VENDOR_NAME VARCHAR(20) NOT NULL,
VENDOR_ADDRESS VARCHAR(15) NOT NULL,
VENDOR_CITY VARCHAR(15) NOT NULL,
VENDOR_STATE CHAR(2) NOT NULL CHECK(VENDOR_STATE IN('WI', 'SD', 'WV')),
VENDOR_ZIP_CODE CHAR(10) NOT NULL CHECK(VENDOR_ZIP_CODE LIKE'[0-9][0-9][0-9][0-9][0-9]-[0-9][0-9][0-9][0-9]'),
VENDOR_PHONE_NUMBER CHAR(12) NOT NULL CHECK(VENDOR_PHONE_NUMBER LIKE '[0-9][0-9][0-9]-[0-9][0-9][0-9]-[0-9][0-9][0-9][0-9]'),
PRIMARY KEY(VENDOR_CODE)
)

CREATE TABLE PRODUCT(
PRODUCT_NO CHAR(4) NOT NULL PRIMARY KEY,
PRODUCT_NAME VARCHAR(30) NOT NULL,
PRODUCT_ON_HAND INTEGER DEFAULT 0,
PRODUCT_COST MONEY DEFAULT 0,
SELLING_PRICE MONEY DEFAULT 0,
PRODUCT_VENDOR_CODE CHAR(2) NOT NULL
CHECK(PRODUCT_VENDOR_CODE IN('AR', 'MS', 'WW')) REFERENCES VENDOR(VENDOR_CODE)
)

INSERT INTO PRODUCT VALUES('CHO4','CHESS SET',11,26.75,28.90,'WW');
INSERT INTO PRODUCT VALUES('DI24','DINOSAURS',14,3.75,4.95,'MS');
INSERT INTO PRODUCT VALUES('GL18','GLOBE',2,27.50,29.95,'MS');
INSERT INTO PRODUCT VA...........

PHP MySQL Code Generators
I'm looking for a PHP code generator that will support forms that access data from lookup tables, sometimes two or three levels deep.

All of the generators I've seen are very simple single table lookups. Which is no use to me. DBDesigner's simple frontend goes to one level but my design goes further.

MySQL Password In PHP Code
I am not sure using md5 is correct in the code below:

[CODE]
<?php
$Host ="localhost";
$User = "root";
$Password =md5("secretl");
$DBName="NewDatabase";
$TableName="Feedback";

$Link = mysql_connect($Host, $User, $Password)
or die("Couldn't make connection: " . mysql_error()); //on failiure, post error message

if($db = mysql_select_db($DBName, $Link))
{
print "connected to NewDatabase";
}
else
{
die("Couldn't select database:" . mysql_error());
}
?>
[/CODE]

The error message is as follows:
Couldn't make connection: Client does not support authentication protocol requested by server; consider upgrading MySQL client.

Separating Mysql From Code
I have an exorbitant amount of data that I would like to put into a MySQL database and eventually put into a LAMP-based CMS (by a professional developer) and eventually uploaded onto a website for all people to access.

Is it possible to load information into MySQL before any coding is performed by a developer, before any parts of the CMS are scripted? Can MySQL operate on its own as a database independent from any coding or do I need a developer to set it up before data can be loaded onto MySQL?

If this is possible, is there any sort of language I would need to be fluent in or can it be done using a graphic interface?

Beginning To Code MySQL
I'm teaching myself php/mysql for a specific purpose and I'm wondering if there's anything special I should look out for in my studies. Basically what I'm trying to accomplish is developing a page that will display a pre-populated list of video games and allow users to sort them by things such as title, release date, genre, ESRB rating, developer, etc; and in addition to those fields there will be another field with a short explanation of the game.As for updating the DB, I'm not sure yet if I'll just do it through phpmyadmin, or if I'd want to develop a front end for that on the site - in a password protected area or some such.

Forum Code Using MySQL/PHP
I am currently working on coding a forum for my website. I am fairly new to this coding stuff so i apologise if if this is something really easy.
The way i have coded the forum so far is that one page will display a list of all the topics within that forum. It also displays the unique ID of that topic. The topic headings are set up as a link which when clicked i want it to search the database for all the replies that link to that topic. I have linked the replies to the topics using simply the topic ID.
The problem i am having is i cant work out how to pass the ID variable along in my link, or how to code the link so it will find the replies for that particular topic.
Maybe i have gone about it all totally wrong and need to start from scratch.

Help Please Running Mysql On Os X
I am very new to mysql. I am using the sitepoint book 'Build your own Database Driven Website using PHP and MYSQL. I have installed mysql mysql-5.0.41-osx10.3-powerpc. Under preferences/mysql it indicates that the mysql server is running. When I try to access mysql through the terminal window I get a message - command not found. Or no permissions. I can go to the bin directory and list the contents - they seem to be there. I can't get past page 21/22 Post-installation setup tasks. I am also new to using the terminal window. I suspect I have missed something really basic - any suggestions on how I can get up and running would be much appreciated!

Need Some Help In Getting MySQL Set Up And Running.
I wasn't sure if someone would be able and willing to help me, but I am new to installing MySQL on a Windows 2003 server (actually .. any server), but I am installing it on a Windows 2003 server right now. I also installed a new version of PHP on the same server. Everything looks fine, but when I go to phpinfo.php I don't see anything saying MySQL. (I saw somewhere that if MySQL is installed properly, it should be displayed on the phpinfo.php page.)

I am currently trying to set up and run Cerberus Help Desk, but it isn't finding the MySQL database that I installed.

So, I would really appreciate it if someone could not just help me via email or postings in here, but actually by using Instant Messenger (AOL, Yahoo! or MSN) to walk me through the set up, testing, etc. so I can get things up and running properly.

I was hoping that someone with more experience than I might be willing to help me in this manner.

Could Not Get MySQL Running
I went to MS-DOS to start the MySQL application by typing mysqld into the bin directory of where I installed MySQL but once I did typed the command and pressed enter this is all I got :

A moment passed before I am shown the path of bin with no indication of MySQL server started. And also I have installed this as a window service.

Running MySQL 5.0
I've just downloaded and installed 5.0 on my Pc/ win 98se.
When I run the program MySQL Command Line Client, it appears to run for a second then disappears. I see the program flash open for a second and then it is gone.Complete newb needs some help.

MySQL 4.1 Running
I've been running mysql 4.1 for sometime and using phpMyAdmin (v2.6.2) to administer the databases.

Using php scripts I can also update/insert etc the databases (maintained on my laptop Mac OS X Tiger).

Suddenly, I can't get phpMyAdmin to load in the browser. I've also tried other MySQL GUI tools like CocoaMySQL and Navicat....they won't run either. I downloaded and installed phpMyAdmin 2.6.3-pl1 as well but no improvement.

Why would mysql run but the admin apps not work?

Running MySQL From A CD-ROM?
I have used PHP and MySQL for a few years now. Just today I can across an application that had a MySQL database running locally off a CD ROM. I did not know this was posible. When the application runs it starts up the MySQL database without the user even knowing they are running it. It is pretty amazing.

So I want to do the same thing. Is there any documentation on how to run MySQL locally. I would like to know how to build the database and create tables under these curcumstances.

Running MySQL
I have installed mysql-3.23.54-win and it all seems to have gone OK .... now i want to run it and setup a database. I dont have an icon on the desktop and there is nothing in Start - Programs ..... start it from DOS prompt via C:> C:mysqlinmysql.exe and i get error 2003 cant connect to MySQL server on localhost <10061>

How Do I Upload A File To MySQL Database And View That File
I do not know how to upload a file to MySQL database and view the posting file on the webpage. I followed the code on-line that show me how to upload, but when I click "browse" to open my file in local drive and click "upload". Nothing happen ! How can I view it on the web page to make sure it was saved in data base.

How To Speed Up Mysql Query/php Code
I have a table in a mysql database. with 5 fields and the field ID as the primary key.

There are about 220 records in the database and the field 'Mediumimage' contains the file paths for the images to be dispalyed on the page.

the PHP code for the query is shown below. Im just wondering why it takes quite a while to process the pictures which are of a small size.

$query_handsets = "SELECT Handsets.Manufacturer, Handsets.Model, Handsets.Mediumimage, Handsets.`Handset Url`
FROM Handsets
WHERE Handsets.Manufacturer LIKE'". mysql_real_escape_string($_GET['manu'])."'";
$hansets = mysql_query($query_hansets, $Mobilecomparsion) or die(mysql_error());
$totalRows_hansets = mysql_num_rows($hansets);

<?php
$i = 0;
while ($row_hansets = mysql_fetch_array($hansets)) {
if ($row_hansets['Manufacturer'] != $lastManufacturer) {
if ($i == 0) {

echo '<img src="images/handsets/logos/'. $row_hansets['Manufacturer'].'.gif" /><br/>'
echo "<table cellspacing=&#3910;'><tr>";
$lastManufacturer = $row_hansets['Manufacturer'];
} else {
echo "</tr></table>";
echo '<img src="images/handsets/logos/'. $row_hansets['Manufacturer'].'.gif" /><br/>'
echo "<table cellspacing=&#3910;'><tr>";
$lastManufacturer = $row_hansets['Manufacturer'];
$i = 0;
}
} elseif ($i % 13 == 0) {
echo "</tr><tr>";
}

echo "<td align='center'><font face='Ariel' size=&#391;'>";
echo "<img src='images/4x4.gif' width=&#3960;' height=&#391;'><br/>";
echo '<img src="images/handsets/'.$row_hansets['Mediumimage'].'" /><br/>'
echo $row_hansets['Model'];
echo '</td>'

$i++;
}
echo '</tr></table>'
?>

MySQL Keeps Going Long After Code Stops
When some queries are executed on a server I have setup MySQL will continue to use up CPU cycles 5-10 minutes after the PHP code that executed the query has long since stopped. The browser page will be loaded and no further PHP code will be active on the entire server that could call MySQL into usage, yet MySQL will continue to use upwards of 80-90% of the available CPU processing power for that 5-10 minutes afterward. In fact, if the PHP page only takes a couple of seconds to load with next to no CPU usage then after it has finished loading MySQL will start utilizing the CPU for all it is worth as if it is trying to complete some task that only it knows about. This is on an isolated server so I know I am the only one using it.

This seems to happen most often when a LEFT JOIN is executed, though the query itself is very quick and returns the data in less than a second.

I am running MySQL 5.0.15 with Apache 2.0.54 and PHP 5.0.4 on Windows XP SP2.

I know this is terribly obscure sounding, but if anyone has any ideas where I could start to look for the source of the problem I would appreciate it. I know it is not in the code because if I run the code on a Linux server this doesn't happen, not to mention the fact that, as I said, the PHP code itself finishes without a hitch.

MySQL Automatically Formatting Code
Is there a way to tell a MySQL server to stop reformatting my code in views? It just drives me crazy that when I create view like that:

mysql> CREATE VIEW SYS_V_ActiveUsers AS
-> SELECT UserID, Login, Email FROM Users
-> WHERE Activate IS NULL;
And what I get in DB is:

select `Users`.`UserID` AS `UserID`,`Users`.`Login` AS `Login`,`Users`.`Email` AS `Email` from `Users` where isnull(`Users`.`Activate`)

And frankly, I hate it. I don't know why it does so, maybe to optimize the code, maybe for other reasons, but I'd like it to stop, at least for my development phase. Is there a switch or something like that to tell MySQL server to stop reformatting my code?

MySQL Error Code 1064:K@N@!:
I suspect that this is some kind of issue with privileges. However, the =
account I am using has been given 'ALL' privileges to the database I am =
trying to insert to. Am I save to assume that ALL includes insert =
privileges? Code:

MySQL Is Running, But I Can't Connect
I really need some help with this. MySQL will not start on boot despite
everything I've done to make sure that it is set to do so.

When I start it as root from a terminal with "/usr/bin/mysqld_safe
--skip-grant-tables &" I show several mysqld procs. and one mysqld_safe,
but I can't connect:

[root@adamsmdk madams]# ps -aux| grep mysql
Warning: bad syntax, perhaps a bogus '-'? See http://procps.sf.net/faq.html
root 3650 0.0 0.1 2276 664 ? S 11:09 0:00
/usr/lib/courier/authlib/authdaemond.mysql start
root 3654 0.0 0.1 2316 792 ? S 11:09 0:00
/usr/lib/courier/authlib/authdaemond.mysql start
root 3655 0.0 0.1 2276 664 ? S 11:09 0:00...............

Gdb Bus Error When Running App With Mysql 5.0
When linking with mysql 5.0 library, I can't no longer use gdb to debug
my app anymore. It cores immediately with a bus error. I've also
noticed that the size of the executable is more than doubled compared
with one linked with mysql 4.0

Running MySQL In RAMDisk
Have a very large database and due to performance requirements it seems that running MySQL in RAMDisk might be a good solution. Access to the database is through PHP. Any suggestions or experiences?

Running Two MySQL Versions
Actually what I want to do is remove 4.1 because I downloaded 5.0 and installed w/o removing the previous version. I now have port 3307 for 5.0. Is this a problem and how can I change it back to 3306 so e.g. when I use Apache/PHP evrything works?

MySQL Running Very Slow
I have the following INSERT SQL, which runs very slow (For 2 full days it had not done anything) on a 2 processor Compaq machine running Suse Linux. Code:

On What Port Is MySQL Running?
I'm running MySQL on my Mac, and I'm trying to figure out on what port MySQL is running. What can I type into Unix terminal to figure this out? Or can I find out some other way?

Slow Running MySQL?
I'm hoping someone may have an idea what could be causing the slow loading pages of my web-site. I'm not positive, but I'm relatively sure that it's related to a problem with MySQL database.

I purchased a program called Sam3 for broadcasting our radio signal over the internet. The software requires the use of MySql in order to set up web pages for our web site.

The problem is, that while everything works GREAT (requests can be made from the site, songs can be searched, the history of what we've played shows up) the pages load PAINFULLY slow. Other users of this software have had no such problems so I'm at a loss.

I know from testing that the PHP script for the web pages is fine, I have plenty of bandwith both upload and download available on my DSL line, and while the computer running MySQL is behind a router I have tried plugging the DSL line DIRECTLY into the host computer and it makes no difference.

For all appearances it seems the problem is that it takes MySQL forever to gather and provide the information needed for these pages. Does anyone have any idea what I should be looking at to solve this problem?

I do not know the MySQL program at all, so I get somewhat lost when people start throwing out technical terms, but this has been really frustrating because no one else seems to have the problem and everyone so far has just told me to check the things I've already checked.

MySQL Config Not Running
i'm trying to set up MySQL with IIS 7.0 on Windows Vista Home Premium. After you install MySQL, there's a check box to launch the config app.

if i leave it checked, the app does not load. if i try to run the app by double-clicking its icon it gives me an error saying, "The application has failed to start because its side-by-side configuration is incorrect. Please see the application event log for more detail." I cannot find the application event log, though.

Running Mysql From Shell
I need to run this sort of querys from shell:

delete from 3dinformatica where preco = " " ;

CREATE TABLE tudotest AS SELECT DISTINCT * FROM 3dinformatica;

DELETE FROM 3dinformatica;

INSERT INTO 3dinformatica (cr_datetime,produto,vendedor,preco,link) SELECT DISTINCT cr_datetime,produto,vendedor,preco,link FROM tudotest;

DROP TABLE tudotest;

i wanted to put the mysql cmd in a file like mysql.sh and run it from crontab.
i have about 100 querys like that i need to run at the same time.

Running Mysql On Old Computers
I´m running mysql on a Pentium 166 Mhz with 16 Mb of RAM. Pretty old, right?

I want to know if there is a way to improve performance. I don´t know, something about reducing the number of queries that it will respond or cutting out some features.

Testing If Mysql Is Running
how can i test if mysql is running on my machine?

Running MySQL In RAMDisk
Have a very large database and due to performance requirements it seems
that running MySQL in RAMDisk might be a good solution. Access to the
database is through PHP.

Running Two MySQL Versions
It seems that my computer is running two different mysql versions. When I'm trying to login to the database it refuse my password and giving me access to the test configuration. This is what i get in the event viewer.

Do you already have another mysqld server running on port: 3306 ?
Event id 100.

The problem occur when I changed my password for the database. I have turned off Mysql in local services but i think that that's the original version. When I start the xampp i think it starts the winmysqladmin version (not sure). How do I reconfigure the hole thing and how can I see what's running on my machine.

I actually have another question to. I'm trying to run and open the shell mysqladmin which doesn't work. It's just a flash, which one of them am I supposed to run?? You have several options like mysqladmin, mysql, mysqld, mysqld-nt....etc. I opened the winmyslqadmin which i think wasn't that good.


Copyright © 2005-08 www.BigResource.com, All rights reserved