File tree Expand file tree Collapse file tree 2 files changed +8
-8
lines changed Expand file tree Collapse file tree 2 files changed +8
-8
lines changed Original file line number Diff line number Diff line change 655
655
"outputs" : [],
656
656
"source" : [
657
657
" with hbasecon.connection() as connection:\n " ,
658
- " comments = connection.table('comments')\n " ,
659
- " posts = connection.table('posts')\n " ,
658
+ " comments_table = connection.table('comments')\n " ,
659
+ " posts_table = connection.table('posts')\n " ,
660
660
" \n " ,
661
- " with posts .batch(batch_size=500) as bp:\n " ,
661
+ " with posts_table .batch(batch_size=500) as bp:\n " ,
662
662
" # Hacer un scan de la tabla\n " ,
663
- " for key, data in comments .scan():\n " ,
663
+ " for key, data in comments_table .scan():\n " ,
664
664
" comment = {b'comments:' + d.split(b':')[1] + b\" _\" + key : data[d]\n " ,
665
665
" for d in data.keys()}\n " ,
666
666
" bp.put(data[b'rawdata:PostId'], comment)"
Original file line number Diff line number Diff line change 664
664
"outputs" : [],
665
665
"source" : [
666
666
" with hbasecon.connection() as connection:\n " ,
667
- " comments = connection.table('comments')\n " ,
668
- " posts = connection.table('posts')\n " ,
667
+ " comments_table = connection.table('comments')\n " ,
668
+ " posts_table = connection.table('posts')\n " ,
669
669
" \n " ,
670
- " with posts .batch(batch_size=500) as bp:\n " ,
670
+ " with posts_table .batch(batch_size=500) as bp:\n " ,
671
671
" # Hacer un scan de la tabla\n " ,
672
- " for key, data in comments .scan():\n " ,
672
+ " for key, data in comments_table .scan():\n " ,
673
673
" comment = {b'comments:' + d.split(b':')[1] + b\" _\" + key : data[d]\n " ,
674
674
" for d in data.keys()}\n " ,
675
675
" bp.put(data[b'rawdata:PostId'], comment)"
You can’t perform that action at this time.
0 commit comments