PHWinfo banniere

Titres
PORTAIL ANNUAIRE ARTICLES COMPARATEUR HÉBERGEURS DEVIS FORUMS RÉDUCTEUR D'URL
Précédent   PHWinfo > Autres forums > Forum Programmation & Conception > comp.databases.mysql > Clear command ('\c') in MySQL v5.0
S'inscrire FAQ Membres Recherche Messages du jour Marquer les forums comme lus
Clear command ('\c') in MySQL v5.0

Réponse
 
LinkBack Outils de la discussion
Vieux 18/10/2007, 12h00   #1
Water Cooler v2
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Clear command ('\c') in MySQL v5.0

I am using it on the command line as such:

mysql>\c;

When I hit the return key, it says:

ERROR:
No query specified


What gives? I expect it clears the console window?

  Réponse avec citation
Vieux 18/10/2007, 12h08   #2
Captain Paralytic
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: Clear command ('\c') in MySQL v5.0

On 18 Oct, 11:00, Water Cooler v2 <wtr_...@yahoo.com> wrote:
> I am using it on the command line as such:
>
> mysql>\c;
>
> When I hit the return key, it says:
>
> ERROR:
> No query specified
>
> What gives? I expect it clears the console window?


It's not all that clear (no pun intended) in the manual, but it is
supposed to display when you enter the command line client:
http://dev.mysql.com/doc/refman/5.0/...n-version.html

You could try
system (\!) Execute a system shell command.
and execute the operating system's clear console command (e.g. cls)

  Réponse avec citation
Vieux 18/10/2007, 12h10   #3
Brian Wakem
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: Clear command ('\c') in MySQL v5.0

Water Cooler v2 wrote:
> I am using it on the command line as such:
>
> mysql>\c;
>
> When I hit the return key, it says:
>
> ERROR:
> No query specified



The no query specified refers to the ;

The \c should not have ; after it. The ; implies another query is present
but is not.


--
Brian Wakem
  Réponse avec citation
Vieux 18/10/2007, 12h17   #4
Water Cooler v2
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: Clear command ('\c') in MySQL v5.0

On Oct 18, 11:08 am, Captain Paralytic <paul_laut...@yahoo.com> wrote:
> On 18 Oct, 11:00, Water Cooler v2 <wtr_...@yahoo.com> wrote:
>
> > I am using it on the command line as such:

>
> > mysql>\c;

>
> > When I hit the return key, it says:

>
> > ERROR:
> > No query specified

>
> > What gives? I expect it clears the console window?

>
> It's not all that clear (no pun intended) in the manual, but it is
> supposed to display when you enter the command line client:http://dev.mysql.com/doc/refman/5.0/...n-version.html
>
> You could try
> system (\!) Execute a system shell command.
> and execute the operating system's clear console command (e.g. cls)




I am sorry I don't get what you mean by "supposed to display when you
enter the command line client",

I *am* running the MySQL Command Line Client on the Windows XP Command
Shell. Earlier, with version 4 as well, I have tried the system("cls")
command but it hasn't worked. Any suggestions?

  Réponse avec citation
Vieux 18/10/2007, 12h31   #5
Water Cooler v2
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: Clear command ('\c') in MySQL v5.0

On Oct 18, 11:10 am, Brian Wakem <n...@email.com> wrote:
> Water Cooler v2 wrote:
> > I am using it on the command line as such:

>
> > mysql>\c;

>
> > When I hit the return key, it says:

>
> > ERROR:
> > No query specified

>
> The no query specified refers to the ;
>
> The \c should not have ; after it. The ; implies another query is present
> but is not.
>
> --
> Brian Wakem




The manual says it should have a ; after the \c if I understand
correctly. Here's the manual verbatim:

<QUOTE topic_name="mysql - The MySQL Command-Line Tool">
mysql>

List of all MySQL commands:
Note that all text commands must be first on line and end with ';'</
QUOTE>

  Réponse avec citation
Vieux 18/10/2007, 14h28   #6
Captain Paralytic
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: Clear command ('\c') in MySQL v5.0

On 18 Oct, 11:17, Water Cooler v2 <wtr_...@yahoo.com> wrote:
> On Oct 18, 11:08 am, Captain Paralytic <paul_laut...@yahoo.com> wrote:
>
>
>
>
>
> > On 18 Oct, 11:00, Water Cooler v2 <wtr_...@yahoo.com> wrote:

>
> > > I am using it on the command line as such:

>
> > > mysql>\c;

>
> > > When I hit the return key, it says:

>
> > > ERROR:
> > > No query specified

>
> > > What gives? I expect it clears the console window?

>
> > It's not all that clear (no pun intended) in the manual, but it is
> > supposed to display when you enter the command line client:http://dev.mysql.com/doc/refman/5.0/...n-version.html

>
> > You could try
> > system (\!) Execute a system shell command.
> > and execute the operating system's clear console command (e.g. cls)

>
> I am sorry I don't get what you mean by "supposed to display when you
> enter the command line client",

The url I posted is to the manual page that shows what you get when
you enter the mysql command line client. According to that page, the
message you get is:
================================================== =================
This is an example of the output from MySQL Enterprise Server on
Windows:

Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 2
Server version: 5.0.28-enterprise-gpl-nt MySQL Enterprise Server (GPL)

Type ';' or '\h' for . Type '\c' to clear the buffer.
================================================== =================

> I *am* running the MySQL Command Line Client on the Windows XP Command
> Shell.

OK, OK, I didn't say you weren't!

> Earlier, with version 4 as well, I have tried the system("cls")
> command but it hasn't worked.

Are you sure that's the correct syntax? From the manual it looks like
it should be
system cls
or
\! cls

  Réponse avec citation
Réponse


Outils de la discussion

Règles de messages
Vous ne pouvez pas créer de nouvelles discussions
Vous ne pouvez pas envoyer des réponses
Vous ne pouvez pas envoyer des pièces jointes
Vous ne pouvez pas modifier vos messages

Les balises BB sont activées : oui
Les smileys sont activés : oui
La balise [IMG] est activée : oui
Le code HTML peut être employé : non
Trackbacks are oui
Pingbacks are oui
Refbacks are oui


Fuseau horaire GMT +1. Il est actuellement 00h57.


Édité par : vBulletin® version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC5 Tous droits réservés.
Version française #16 par l'association vBulletin francophone
PHWinfo est un site Éducation Sans Frontières ©2000-2008
Ad Management by RedTyger
©Tous droits réservés par les parties respectives
Page generated in 0,12734 seconds with 14 queries