SitePoint Sponsor

User Tag List

Results 1 to 4 of 4
  1. #1
    SitePoint Zealot
    Join Date
    May 2000
    Location
    Eugene, OR
    Posts
    178
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I'm using MySQL via telnet. I just typed in a 21 line long create table statement and it gave me an error. Is there any way to just edit the statement and then run it again without having to retype it all in again?

    Thanks,

    Adam

  2. #2
    SitePoint Wizard silver trophy Karl's Avatar
    Join Date
    Jul 1999
    Location
    Derbyshire, UK
    Posts
    4,411
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Yep there is one way - Place the SQL into a file, upload it to a directory on your server, telnet in and type:

    mysql -u USER -pPASSWORD < name_of_file_you_uploaded

    then press enter and if it gives you an error message you can edit the file and run it again.

    ------------------
    Karl Austin
    KDA Web Services
    "Everyone has a photographic memory. Some just don't have film."

  3. #3
    SitePoint Wizard TWTCommish's Avatar
    Join Date
    Aug 1999
    Location
    Pittsburgh, PA, USA
    Posts
    3,910
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I might be misunderstanding you, but if you're at a blank prompt hitting the up arrow key will display the last command you entered...although only one line at a time.



    ------------------
    Chris Bowyer
    MyCoding.com: Join our mailing list for launch notification!
    "I'm not an insomniac, I'm a web designer."

  4. #4
    SitePoint Zealot
    Join Date
    May 2000
    Location
    Eugene, OR
    Posts
    178
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Yes, I know how to get the last line to be displayed, but if the command I had an error on was 20 lines long, this is only kind of helpful.

    I guess I'll try doing what Karl suggests.

    Thanks,

    Adam


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •