Hadoop – ‘SparkContext’ Object No Properties ‘TextFile’

I tried to load the file using the following code:

textdata = sc.textfile('hdfs://localhost:9000 /file.txt')

Error message:

AttributeError:’SparkContext’ object has no attribute’textfile’

< /blockquote>

It is sc.textFile(…), with a capital letter F.

You can check the API of SparkContext here.

I tried to load the file with the following code:

< pre>textdata = sc.textfile(‘hdfs://localhost:9000/file.txt’)

Error message:

AttributeError :’SparkContext’ object has no attribute’textfile’

It is sc.textFile(…), with a capital letter F.

You can check the API of SparkContext here.

WordPress database error: [Table 'yf99682.wp_s6mz6tyggq_comments' doesn't exist]
SELECT SQL_CALC_FOUND_ROWS wp_s6mz6tyggq_comments.comment_ID FROM wp_s6mz6tyggq_comments WHERE ( comment_approved = '1' ) AND comment_post_ID = 4371 ORDER BY wp_s6mz6tyggq_comments.comment_date_gmt ASC, wp_s6mz6tyggq_comments.comment_ID ASC

Leave a Comment

Your email address will not be published.