Advertisement
Guest User

Untitled

a guest
Dec 20th, 2012
122
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.62 KB | None | 0 0
  1. 12/12/20 08:34:02 WARN conf.Configuration: hadoop.native.lib is deprecated. Instead, use io.native.lib.available
  2. HBase Shell; enter 'help<RETURN>' for list of supported commands.
  3. Type "exit<RETURN>" to leave the HBase Shell
  4. Version 0.92.1-cdh4.1.2, rUnknown, Thu Nov 1 18:03:50 PDT 2012
  5.  
  6. hbase(main):001:0> create 'cftable', {NAME => 'cf1'}, {NAME => 'cf2'}
  7. 0 row(s) in 1.4690 seconds
  8.  
  9. hbase(main):002:0> put 'cftable', 'therow', 'cf1:a', 'value1'
  10. 0 row(s) in 0.0540 seconds
  11.  
  12. hbase(main):003:0> put 'cftable', 'therow', 'cf2:b', 'value2'
  13. 0 row(s) in 0.0050 seconds
  14.  
  15. hbase(main):004:0> scan 'cftable'
  16. ROW COLUMN+CELL
  17. therow column=cf1:a, timestamp=1355988977452, value=value1
  18. therow column=cf2:b, timestamp=1355988986129, value=value2
  19. 1 row(s) in 0.0360 seconds
  20.  
  21. hbase(main):005:0> disable 'cftable'
  22. 0 row(s) in 2.1370 seconds
  23.  
  24. hbase(main):006:0> alter 'cftable', {NAME => 'cf2', METHOD => 'delete'}
  25. Updating all regions with the new schema...
  26. 1/1 regions updated.
  27. Done.
  28. 0 row(s) in 1.4340 seconds
  29.  
  30. hbase(main):007:0> enable 'cftable'
  31. 0 row(s) in 2.1200 seconds
  32.  
  33.  
  34. hbase(main):008:0> flush 'cftable'
  35. 0 row(s) in 0.1130 seconds
  36.  
  37. hbase(main):009:0> major_compact 'cftable'
  38. 0 row(s) in 0.1100 seconds
  39.  
  40. hbase(main):010:0> scan 'cftable'
  41. ROW COLUMN+CELL
  42. therow column=cf1:a, timestamp=1355988977452, value=value1
  43. 1 row(s) in 0.0140 seconds
  44.  
  45. hbase(main):011:0> disable 'cftable'
  46. 0 row(s) in 2.1580 seconds
  47.  
  48. hbase(main):012:0> alter 'cftable', {NAME => 'cf2'}
  49. Updating all regions with the new schema...
  50. 1/1 regions updated.
  51. Done.
  52. 0 row(s) in 1.4380 seconds
  53.  
  54. hbase(main):013:0> enable 'cftable'
  55. 0 row(s) in 2.1230 seconds
  56.  
  57. hbase(main):014:0> scan 'cftable'
  58. ROW COLUMN+CELL
  59. therow column=cf1:a, timestamp=1355988977452, value=value1
  60. therow column=cf2:b, timestamp=1355988986129, value=value2
  61. 1 row(s) in 1.0300 seconds
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement