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


SuperbHosting.net have generously sponsored dedicated servers to ensure a reliable and scalable dedicated hosting solution for BigResource.com.





What Is A Command For Displaying Mysql Users? Command Prompt Console


What is a command for displaying mysql users? command prompt console?




View Complete Forum Thread with Replies

Related Forum Messages:
Windows Command From Within The MySQL Console
Is it possible to execute an MS-DOS command from within the MySQL console? I know that the Linux version of MySQL contains the SYSTEM command to execute shell commands, but there doesn't seem to be anything similar in the Windows version.

Futhermore, is it possible to run mysqldump from the MySQL console?

View Replies !
C# Console (exe) Application Crashes On Open Command (MySql)
I have problem opening an MySql connection from an win console application. I am using SharpDevelop as IDE. Previously I've been working with MySql through C# aspx and am new to writing exe programs in C#, so I assume that I might be missing something in the IDE / project configuration.

I am successfully opening a connection and reading data from the table using adapter (window panel application binding to a grid), but when trying the code below in an console application the program crashes when calling the MyConn.Open(); function.

The error message being: Exception MySql.Data.MySqlClient.MySqlException was thrown in debuggee:

Unable to connect to any of the specified MySQL hosts.

Open()


If I break before the MyConn.Open(); function is called, the MyConn variable is filled with lot's of info looking ok to me, though I am not capable of knowing if any of it can tell me what leads to the crash in the next function call.

Ive added the MySql.Data.dll to the project from the GAC list in the add reference panel. Further, in addition to the references, I only have an AssemblyInfo.cs file and the Main.cs file with the code below in the project

I've reinstalled the MySql database trying different configurations etc, but whatever I have tried does not work.

Has anybody else encountered this problem and or know the solution?

View Replies !
MySQL Command Line Prompt
In DOS mode, we can use for example dir/w-p to break the whole page to sub-page.
In MySQL prompt window, when I type "show variables", it blooms about 190 rows, but I can't scroll BACK to first 1-50 rows, by resizing the prompt windows it won't help.
So, I think is there any additional keys for pause the page like DOS mode?

View Replies !
Accessing Mysql From Command Prompt
The path to my mysql installation is "C:Program Filesxamppmysqlin".

I want to run myisamchk - to do this I think I have to access it via the command prompt.

A stupid question - I kmow - but how do I get to the directory in a DOS window??

View Replies !
Login To Mysql Using Command Prompt In Winxp
I have installed wamp server on my computer. Now i want to connect to mysql using command prompt.

When I try it on command prompt . I receive following message.

C:Documents and SettingsIbm>mysql -h localhost -u root -p
'mysql' is not recognized as an internal or external command,
operable program or batch file.

View Replies !
Can't Connect To MySQL Server From Command Prompt
I have installed MySQL on WinXP Pro

When attempting to access various commands from the command prompt (eg help, set password etc) I get the following error.

ERROR 2003: Can't connect to MySQL server on 'localhost' (10061)

When trying to access the MySQL server via a local web page I am also unable to connect to the database.

I have successfully installed Apache 2.0.35-win32-x8 and PHP.

View Replies !
Cant Connect To Mysql At Command Prompt Error
please see attached file for error.

im a beginner. im following php/mysql book from site point. ive searched the forums already but couldnt find the solution.

i just installed IIS on windows xp, mysql and php.

im at command line and i get these (profanity removed) darn error messages. after 1 hour of re-reading chapters of the book i decided to bother you with this problem

in the book it says to check mysql is running by pressing ctrl +alt + del. then in "tasks" you should see "it" running. a) there is no tab called tasks when you press ctrl + alt + del. b) what is "it"

so i assume it (mysql) is running, since i dont really know because the instructions arent that clear for complete (profanity removed) silly billies like me

in another thread someone said "turn off your firewall then try again" - did that, didnt work

then from the command prompt i keep being told it cant connect (see screenshot)

View Replies !
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?

View Replies !
How Can I Import Sql Through Command Console?
I found that I can import sql through command console

mysql -u username --default_character_set utf8 -p password -h localhost databasename < C:/data.sql

mysql -u username --default_character_set=utf8 -p password -h localhost databasename < C:/data.sql

However, it shows only the mysql version and variables and did not import.



View Replies !
How To Use The Command Prompt?
I am using openSUSE 11.0. I am a student in 3rd year of my computer science course. We have the database labratory this year and the college uses oracle. However I think that the queries that we use are pretty common to be used on any databse. I do not want to install another PIRATED copy of the Oracle DB and slowdown my Windows installation as I already have a Linux system running it.

My question is:

How do I use the mysql prompt to execute my sql queries? Is there any prompt which will allow me to input the queries directly via keyboard and show me the output there (much as the 'show databases' command does) on the prompt? If yes then how to do that?

View Replies !
Command Prompt And Numerics
I use command prompt with mysql. I use then command

select format(1056.99701245,2);
1,057.00
How can I set the enviroment so I can see
Code:
1,057.00
as
Code:
1.057,00
.
Meaning '.' to covert as ',' and '.' as ',' ?

Can I change it via windows settings?

View Replies !
How To Clear The Screen Like Cls In Windows Command Prompt
what is the command or way to clear the screen in mysql in windows. i tired like ....

View Replies !
Problems Executing .sql File From Command Prompt
I am having problems executing a .sql batch file from the mysql command prompt. I can run this file through SQLYog and i have no errors/problems but if i try and run the batch file through the windows command prompt (after connecting to the mysql database) i get a problem as soon as i try to change the delimiter back to ;

Has anyone else had problems with this?

View Replies !
Command Prompt :: Window Appears And Then Immediately Disappears On Windows XP
I am completely new to MySQL and have recently loaded the 5.0 community version on my desktop PC under windows XP. When I execute MySQL, the MySQL command prompt window appears and then immediately disappears. Can anyone tell me why this is happening and how to resolve?

View Replies !
MySql Command Line Makes Loud Noise After Each Command
My Dell laptop generates a very loud error tone after every command executed in MySQL command line monitor even though I've turned the speakers off.

View Replies !
Command To List Users
Im trying to figure out what the command in mysql monitor is for listing users and their passwords?

View Replies !
Mysql BETWEEN Command
i just want to know on how can i query certain part of data using the date.what i mean is, i want to query for example the data from 2005-04-25 till 2005-04-30.i've try the sql code below,but it does'nt work.can anyone give me an example on how can i query using mysql??plz help.tq

rsLetterDate.Open " select * from letter BETWEEN letter.letterdate = '2005-04-01' AND '2005-05-31'", "DSN=Data", adOpenStatic, adLockOptimistic

View Replies !
Use Command In Mysql
Is there any command in mysql to unselect the database, opposite command of use.

View Replies !
Command In Mysql.exe
I use Windows Xp and i must create automaticly sql base with .bat file. I try to execute sql script in one instruction. there is my instruction in cmd:

mysql.exe -u root --execute=source script.sql --force

I try to execute script.sql and in this file there is the instruction:

CREATE DATABASE test;

But i have a big probleme and when i enter the first instruction it shows:

ERROR 1102 (42000): Incorrect database name 'script.sql'

I have no idea how can i do.

View Replies !
MySQL Command Questing
I dont profess to be a master at SQL statements. Thanks for your help,
if anyone can give it.

I have a database that has a run column. A user can place in that
column a number, such as 1, 2, or 3.

I want to organize me list by this run number. The problem is that when
I call the query it places all the rows that have no number on the top.

For example:

SELECT DISTINCT id, Year, Make, Model, run_num FROM cars WHERE
userID='2' AND auctionID='20051108' ORDER BY run_num;

Will get me this..

+-----+------+--------------+--------------------------------+---------+
| id | Year | Make | Model | run_num |
+-----+------+--------------+--------------------------------+---------+
| 275 | 2004 | Toyota | Camry LE Sedan 4D | |
| 277 | 2004 | Toyota Truck | Sienna XLE Limited Minivan | |
| 279 | 2000 | Chrysler | Concorde LXi Sedan 4D | |
| 281 | 2004 | Nissan | 350Z Coupe 2D | |
| 284 | 2004 | Chevrolet | Cavalier Coupe 2D | |
| 285 | 2002 | Dodge Truck | Durango Sport Utility 4D | |
| 280 | 2003 | Audi | RS6 Sedan 4D | 1 |
| 276 | 2004 | Toyota Truck | Tacoma Xtra Cab | 1A |
| 278 | 1989 | Lincoln | Continental Signature Sedan 4D | 1B |
| 282 | 2004 | Chrysler | Sebring Touring Convertible 2D | 5 |
+-----+------+--------------+--------------------------------+---------+


But I want the run_num's to be on top, followed by the ones with the
blanks in the order of id perhaps.

View Replies !
Mysql SOURCE Command
i am new to mysql.i have a file full of sql statements
like
insert into mysql1.table1 values(4343);
.
.
.
now i want to run these statements and create my mysql table with data in it.
i was told to use a SOURCE command but iam having problems
from the mysql prompt i tried
mysql> source test.sql ( this is the file that has all the sql statements)
and i got "file could not be located" error: 2
my questions:
how can i syntactically specify the location of my file ?
will the SOURCE command serve my purporse?

View Replies !
MySql And The Command Line
I'm trying to write a cron script which backs up a mysql database on my website.
I am using this command

mysqldump --opt -h localhost -u user -p database | gzip > /path/for/backup/file.gz

If I type this in and hit enter, it asks me for a password (like it should) but can I put this in the initial line as a separate argument so that I could execute it from cron?

View Replies !
Mysql Command Line
I'm having issues with how my data displays from the command line mysql interface.

When I do a SELECT * FROM tablename

The return only doesn't show the first few fields? The data is there because if I do "SELECT FIELD1 FROM tablename" the data is there.
Now I just inserted a new record and it is the only record to properly display?

View Replies !
Mysql Via The Command Line
I type "mysql -u user -p=password" on the command line and get an access denied message.

I type "mysql -u user" and then type in "password" when prompted and it works just fine. Unfortunately, doing it this way isn't an option because I want to make a script that'll auto-restore a database everytime I run it.

I've tried surrounding password by double quotes and single quotes and neither work.

View Replies !
MySql Backup Command
I am using the following command to try to backup my database.

Quote:mysqldump -h localhost -u ***** -p --add-drop-table --create-options --skip-add-tables --skip-add-locks -e --set-charset --disable-keys -Q ***** > oldforumtest.sql

View Replies !
MYSQL WHERE For JOIN Command
This statement works:

$query = "SELECT * FROM compare,product WHERE compare.model=product.model ORDER BY '$order' ASC";

Results in reading two rows of my data. Correct.

However, I want to add another factor into that statement LIKE to select only certain "model" out of the whole list that it queries from. So I thought this would work:

$query = "SELECT * FROM compare,product WHERE compare.model=product.model AND product.model='$g_model' ORDER BY '$order' ASC";

But then number of rows is 0.

View Replies !
Backup Mysql With Command
how do I dump mysql data base to file using command in XP?
Found many examples but all apply to linux's superior terminal.

View Replies !
MySQL ''UPDATE'' Command...
I am new to fairly new to MySQL and I would like to have some help...

I use MySQL database to store all of my user accounts and logins. I need to update all of the data in there automatically without having to do all 10,000 entries manually.

My account database has the following tables:

View Replies !
Running A Command From Outside Of MySQL
I'm trying to run the following command outside of MySQL in a bash script.

LOAD DATA INFILE '/home/david/data.txt' INTO TABLE times;

Can someone point me how to do this?

View Replies !
LOAD Command In MySQL
I am ChandraSekhara Rao, new to this group. I would like to know how LOAD command was implemented in MySQL ?
Day before yesterday i tried to load a data file of size 540 MB to a table. It took about only 2 min. But using PERL and PYTHON i tried to parse the same file into Lists at that time it took more than 1 hr. I surprised about this.
My question is why PYTHON and PERL ( this took around 45 min to parse the same file) took lot of time and while MySQL took only 2 min and how the LOAD command in MySQL was implemented

View Replies !
Mysql Command Line With OSX
i think i have installed mysql properly. when i go to the system preferences it is there and it says that it is running. BUT when i am in the terminal window, and type:

Lachlan-Gregors-Computer:~ loc$ cd /usr/local/mysql/bin

it goes to this, so i keep typing to try to login

Lachlan-Gregors-Computer:/usr/local/mysql/bin loc$ mysql -h localhost -u root -p

but it just says :

-bash: mysql: command not found
Lachlan-Gregors-Computer:/usr/local/mysql/bin loc$ .

View Replies !
Ssh Mysql Command Line
We have a remote server with a few gigs worth of sql dump files we need to load into the database.

I logged in to the server via ssh and typed:

mysql -u username -p dbname < file.sql

It worked and started importing. I logged into php myadmin and saw that the db was being filled. Then I closed the terminal window... and it stopped.

I kind of expected it not to because if I start a long running command in phpMyAdmin, it will continue running even if the connection times out. But the mysql proccess doesn't close.

I guess closing the terminal connection stops the mysql proccess.

So I was wondering if I could import the file.sql with a mysql command from inside phpmyadmin. All the instructions I found require sending it directly to the mysql binary.

Though one other problem with that is, if it's anything like load data infile, the file needs to be located in the mysql directory or the tmp directory or it doesn't work, at least not with our server setup.

So the most optimal solution would be, how can I spawn a mysql command in its own proccess without the need to keep the terminal open on our end since all the proccessing is on the server?

The loading will take a few days and our internet connection isn't stable enough I don't believe. So it would be best if we only had to rely on the server itself.

View Replies !
Command Line Mysql
I have seen similar questions to this on the site but haven't yet found the answer for me, I have done a couple of years messing about with access databases on a single computer at work. I know about spliting the data and control into seperate files etc etc. I would now like to know about setting up a database on the web, accessable from home and at work, so have been advised to have a look at MySQL.
OK, so I have now installed Mysql, PHP and Apache onto my computer to try it out.
I have a pretty set of traffic light which are at green, and I have a feather (apache) with a green indicator on it.
I can click on the traffic light and click "show me" and a pretty usefull looking panel with a heading of WinMySQLadmin 1.4 comes onto the screen.

Now, my book (Database driven websites), on page 34 says that whichever method I use to run the MySQL client program I'll end up at a command prompt. HOW? Do I start a command prompt myself?

So, I have tried opening a command prompt and navigating to C:mysqlBin and typing in mysql -u test -p; and then at the prompt for the password have entered test, but it doesnt let me in!!??

I used test as the "control panel" "my.ini.setup" tab includes the following

[mysqld]
basedir=C:/mysql
#bind-address=86.63.19.6
datadir=C:/mysql/data
#language=C:/mysql/share/your language directory
#slow query log#=
#tmpdir#=
#port=3306
#set-variable=key_buffer=16M
[WinMySQLadmin]
Server=C:/mysql/bin/mysqld-nt.exe
user=test
password=test
QueryInterval=10

I've also tried user name root with password test
I've also tried just using mysql by itself, which lets me start it, but I cant do much with it, like CREATE DATABASE isn't allowed but SHOW DATABASES is.

Brett_iow_UK

View Replies !
Set Mysql Variable Using Command
How to set mysql variable permanently using command without making changes in my.ini i cant find the my.ini file in c:/windows or in c:/mysql/mysqlserver/bin/

View Replies !
MySQL Command Issues With An ADO Recordset
I know you will probably say that I should use MS SQL Server DBs with ASP,
but my MySQL and ASP combo works and is affordable for me and up until now
didn't give me any grief until recently.

In essence, the following MySQL query commands cause my ASP to generate a
Type Mismatch error when I try to response.write the result of the query
fields:

Query 1

CONCAT(PICFILEWIDTH,' x ',PICFILEHEIGHT)

I call this query result into a dynamically-created array from a recordset
object, ie arrSQLData (the array) = oRSv.GetRows() (the recordset object),
but when I call say arrSQLData(0,0) it generates the type mismatch.

This used to work fine in the MySQL v4 something that had the crappy
installer, but since they made the new installer (and some other mods) it
causes this problem.

I've checked the MySQL site and it says that the above, which is an int, ' x
', another int is fine, but something in ASP doesn't like the result it
sends back.

Done a straight query from SQLyog and that displays it OK.

Query 2

IFNULL((sp.RRPTAX/sp.RRPNET),'0.00')

same again this generates a type mismatch when it used to work fine.
Obviously the command puts in 0.00 if the tax and net values are null, but
this doesn't work now. It generates a type mismatch.

Has anybody had this problem and fixed it?

View Replies !
Where Is The MySQL Command Line Client?
I have installed the XAMPP package on my computer, which contains appache php and mysql. however I don't know how to create a database with the command line client in mysql or even where to type the code required to set up a new database. Not a very interesting question, but it's vital i get an answer if i am to start learning.

View Replies !
MySQL Command Line Client
I have just installed MySql Server 5 on my Windows XP pc. When I start up the MySql Command Line Client, I type in the password and then the command line comes up.
I create a database and then type use database:
I then run the command source C;jt.sql. This drops tables if they are there and then creates the tables and inserts data. Once this has completed, I can then selet from the tables. For instance there is a table called users.
If I type 'select * from users;' It comes back with the results and 2 row in set. This is fine however as soon as I exit from the MySql Command Client and come back in then I use database and show tables. There are no tables in there.
My question is this, why are the data and tables not staying in the database? I have tried commiting but it makes no difference.

View Replies !
Issue MySql Line Command
do i have to cd to the MySql Server 5.0 folder to execute MySql?
How do i make MySql a 'Universal command',which could be issued at any
directory level?

View Replies !
Mysql Command Line Options
I am executing the following from the command line.

mysql -uroot -t rep_queries_${yearmth} -A <<QUERY_INPUT
SELECT count( distinct source_ip)
from day_${yearmthday}
where query_ip = $numip
QUERY_INPUT

It returns the heading along with the result (see below). Can I suppress things
so that only the result is returned? I need to store the result in a unix variable.

+----------------------------+
| count( distinct source_ip) |
+----------------------------+
| 41 |
+----------------------------+

View Replies !
Mysql Command Line Error
I m using mysql command line tool in my shell script for updating tables but there is no error handling provided in the batch mode
for example i am doing
mysql < sql > out
The out file would only contain the output not the errors which mysql command line throws on the screen. I tried --tee options but wont work. I have been using Sybase for a long time it has a somethign similar to mysql command line tool known as isql in which u can direct ur output to a outfile which also contains errors if any while processing the query.

View Replies !
Opening Command Line MySQL On Win. ME
I have just installed MySQL Server 5 along with the ODBC 5 driver on my home office computer, which has Windows ME as the operating system. The add/remove programmes list shows they are installed, but the command line window simply comes and goes instantly, when I click on the MySQL command line under the programmes list.
I did, initially, install MySQL with the ODBC driver on a computer running Windows XP and had no problem. But, I needed this on my home office computer.

Have I installed the wrong driver for the Windows ME system or is there another reason

View Replies !
MAC OS X : 'mysql -u Root' : Command Not Found!
i know nothing about DB's but i want to learn.; after a few attempts i finally got mysql to run (' starting mysql dtabase server') and the next step i am told is to make a pswd. well, i typed 'mysql -u root' to connect to the server like the manual says to do and all i get is 'command not found'.

View Replies !
The Used Command Is Not Allowed With This MySQL Version
I am trying to insert values into a mysql database from a csv or text file using the LOAD DATA LOCAL command and I get the following error message:

The used command is not allowed with this MySQL version

I read 4.2.4 Security issues with LOAD DATA LOCAL in mysql.com and understand that I have to configure mysql with --local-infile=1

That´s what I don´t understand...where do I do this exactly.

I typed in the following at the prompt:

C:mysqlin: mysqld --local-infile=1

and I get no response (normally another prompt would appear after which I type mysql.exe and I enter into mysql land)

I also have phpmyadmin and winmysqladmin...but cannot find with either of these to configure mysql.

View Replies !
Command Is Not Allowed With This MySQL Version
My host just upgraded to PHP5 and one of my scripts is failing. The error is a MySQL error so I am posting here. This is the

PHP

mysql_query("LOAD DATA LOCAL INFILE '$listingFile1' REPLACE INTO TABLE `Listings_Residential` FIELDS TERMINATED BY ' ' LINES TERMINATED BY '
' ") or print("Couldn't open database: ".mysql_error());


The error I get from MySQL is "The used command is not allowed with this MySQL version"

I don't know if the MySQL version has changed. It is currently 4.1.20. Looking through the MYSQL documentation, I don't see anything in the query that would be affected by the version. The variable $listingFile1 is printing out a file location like /var/www/vhosts/domain.com/httpdocs/deposit/listings-residential.txt which is a valid path.

View Replies !
-bash: Mysql: Command Not Found
Hey everyone, this is my first post and I am excited to get continue my learning of Web Design and Development with this great forum. I was wondering if someone could help me out with something.

I recently finished watching all of Stefan's Mischook's PHP and MySQL tutorials over at killerphp (which were extremely helpful), and I installed XAMPP on my Mac OS X system with no problems after following his instructions.

My question is, by trying to continue my learning of PHP and MySQL I purchased Sitepoint's "Build Your Own Database Driven Website using PHP and MySQL." Then I ran into this paragraph in it.

While Web-based MySQL administration systems provide a convenient, graphical interface for working with your MySQL databases, it is still import- want to learn the basics of MySQL’s command-line interface. The commands you use in this interface are the very same commands you’ll have to include
in your PHP code later in this book. I therefore recommend going back to Chapter 1 and installing MySQL on your own computer so you can complete the exercises in this chapter before you get comfortable with your Web-based administration interface.

Whichever method and operating system you use, you’ll end up at a command prompt, ready to run the MySQL client program and connect to your MySQL server. Here’s what you should type:

mysql -h hostname –u username -p

You need to replace hostname with the host name or IP address of the computer on which the MySQL server is running. If the client program is run on the same computer as the server, you would use -h localhost or –h 127.0.0.1, but in this special case you can actually leave off this part of the command entirely. username should be your MySQL user name. If you installed the MySQL server yourself, this will just be root. If you’re using your Web host’s MySQL server, this should be the MySQL user name the host assigned you.

Well I tried to open up a terminal window and type that command but everytime I do I get this :

-bash: mysql: command not found

XAMMP was running at the time. What should I do? The graphical interface of the phpMyAdmin was something that I was picking pretty easy. Should I still learn to use a command line to access my MySQL database? If so, how do I do it from the Terminal Window.

View Replies !

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