Home > Archive > MySQL ODBC Connector > September 2005 > Can we run linux commands from inside the msql client









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Can we run linux commands from inside the msql client
Sujay Koduri

2005-09-28, 7:23 am

------ _=_NextPart_001_01C5
C419.31A22652
Content-Type: text/plain

hi..

I searched the documentation and googled for sometime, but didnt find
anything related to this
can we execute shell commands inside mysql client (like using ! in oracle),
and if possible please tell me how.

sujay

------ _=_NextPart_001_01C5
C419.31A22652--
Wolfram Kraus

2005-09-28, 7:23 am

Sujay Koduri wrote:
> hi..
>
> I searched the documentation and googled for sometime, but didnt find
> anything related to this
> can we execute shell commands inside mysql client (like using ! in oracle),
> and if possible please tell me how.
>
> sujay
>

Use \!
E.g. \! ls
More information :\?

HTH,
Wolfram


--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql? unsub...sie.nctu.edu.tw

David Ziggy Lubowa

2005-09-28, 7:23 am


Yes you can ... e.g mysql>\! vi filename ( you would be able to edit the
file while within mysql.


cheers


On Wednesday 28 September 2005 13:41, Sujay Koduri wrote:
> hi..
>
> I searched the documentation and googled for sometime, but didnt find
> anything related to this
> can we execute shell commands inside mysql client (like using ! in oracle),
> and if possible please tell me how.
>
> sujay


--

--
Fanaticism consists of redoubling your effort when you have forgotten your
aim.
-- George Santayana

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql? unsub...sie.nctu.edu.tw

Sujay Koduri

2005-09-28, 7:23 am


Thanks a ton :)

sujay

-----Original Message-----
From: David Ziggy Lubowa & #91;mailto:dlubowa@b
ushnet.net]
Sent: Wednesday, September 28, 2005 4:37 PM
To: mysql@lists.mysql.com
Cc: Sujay Koduri
Subject: Re: Can we run linux commands from inside the msql client


Yes you can ... e.g mysql>\! vi filename ( you would be able to edit
the
file while within mysql.


cheers


On Wednesday 28 September 2005 13:41, Sujay Koduri wrote:
> hi..
>
> I searched the documentation and googled for sometime, but didnt find
> anything related to this can we execute shell commands inside mysql
> client (like using ! in oracle), and if possible please tell me how.
>
> sujay


--

--
Fanaticism consists of redoubling your effort when you have forgotten your
aim.
-- George Santayana

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql? unsub...sie.nctu.edu.tw

Hirofumi Fujiwara

2005-09-28, 7:23 am

> hi..
>
> I searched the documentation and googled for sometime, but didnt find
> anything related to this
> can we execute shell commands inside mysql client (like using ! in oracle),
> and if possible please tell me how.
>
> sujay


system (\!) Execute a system shell command.

I think \! is what you want.

------------------------------------------------------------
Hirofumi Fujiwara fuji@timedia.co.jp, fuji@fuji.gr.jp
Time Intermedia Corporation http://www.timedia.co.jp/
Corporate Strategy Department & Knowledge Engineering Center
26-27 Saka-machi Shinjuku-ku, Tokyo 160-0002 Japan
------------------------------------------------------------

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql? unsub...sie.nctu.edu.tw

Hassan Schroeder

2005-09-28, 11:23 am

Wolfram Kraus wrote:

[color=darkred]
> Use \!


Whoa. I didn't know that. Is that controlled in any way by GRANT?
Or by conf/startup options?

It seems like something you might (strongly!) want to disallow in
a shared environment :-)

--
Hassan Schroeder ----------------------------- hassan@webtuitive.com
Webtuitive Design === (+1) 408-938-0567 === http://webtuitive.com

dream. code.



--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql? unsub...sie.nctu.edu.tw

SGreen@unimin.com

2005-09-28, 11:23 am

--=_alternative 0057B2118525708A_=
Content-Type: text/plain; charset="US-ASCII"

Hassan Schroeder <hassan@webtuitive.com> wrote on 09/28/2005 11:58:35 AM:

> Wolfram Kraus wrote:
>
>
>
> Whoa. I didn't know that. Is that controlled in any way by GRANT?
> Or by conf/startup options?
>
> It seems like something you might (strongly!) want to disallow in
> a shared environment :-)
>
> --
> Hassan Schroeder ----------------------------- hassan@webtuitive.com
> Webtuitive Design === (+1) 408-938-0567 === http://webtuitive.com
>
> dream. code.
>


The system commands you execute through the MySQL client are not performed
at the server but in the context of the local user using the local MySQL
CLI client on the local machine. Regular OS-level user permissions kick in
here. You would not be able to execute a command from within the MySQL
client that you normally could not execute from any other command line.

Shawn Green
Database Administrator
Unimin Corporation - Spruce Pine

--=_alternative 0057B2118525708A_=--
Hassan Schroeder

2005-09-28, 11:23 am

SGreen@unimin.com wrote:

> The system commands you execute through the MySQL client are not performed
> at the server ...


Ah, OK, got it. Of course. I plead temporary under-caffeination :-)

Thanks for the clarification.
--
Hassan Schroeder ----------------------------- hassan@webtuitive.com
Webtuitive Design === (+1) 408-938-0567 === http://webtuitive.com

dream. code.



--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql? unsub...sie.nctu.edu.tw

Sponsored Links





Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive | Programming forum archive

Copyright 2009 droptable.com