Reputation: 44285
I'm learning the hadoop technology stack and Linux at the same time. I am at hive and started creating an external table.
hive> CREATE ETERNAL TABLE users (
>user_id INT,
>//and so on
Notice the type-o: ETERNAL = *EXTERNAL. Is there a way to recall the history of all the stuff I typed into the shell? Then I can fix the type-o and re-run the command. I tried up arrow, but that only gives me one line.
Upvotes: 0
Views: 121
Reputation: 154
To get the history of all the stuff that you did on the shell type in 'history' in the terminal: $ history
Output looks like as below in the attached image file.
And to search for a particular command in the history file you can use the following commands:
$ history | grep command-name
$ history | egrep -i 'scp|ssh|ftp'
Upvotes: 1