what is the best way to deal with a lot of dataset of different type (case classes)How to define partitioning of DataFrame?Parallelize GZip file processing SparkHow to read a parquet file with lots of columns to a Dataset without a custom case class?Scala 2.11 & Spark 2.0.0 Create dynamically case class to encode DatasetHow to call Spark UDF on Datasets of case classes?Spark SQL - Read csv into Dataset[T] where T is a case class of Option[BigDecimal] fieldAvro Schema vs. Scala Case Class for Spark DatasetsStream files from HDFS using Apache Spark SteamingHow to create merge-sorted partitions in Sparkspark convert dataframe to dataset using case class with option fields

Modified stem cells as a resuscitation serum after death by cyanide poisoning?

RPMs too high on freeway?

Should I tell an editor that I believe an article I'm reviewing is not good enough for the journal?

Why are session states synchronized with high availability?

What is the correct way for pilots to say times?

Is "montäglich" commonly used?

Isn't any conversation with the US president quid-pro-quo?

Beginner Tactics - Why Isn't This Mate?

Why are rain clouds darker?

Buddha Hinduism

Does removing finitely many points from an open set yield an open set?

Translate 主播 in this context

Showing a point on a plot as a circle rather than a disk

Did Ohio pass a law granting students the right to give scientifically wrong answers consistent with their religious beliefs?

Why do we use the particular magnitude of a force to calculate work?

Steampunk book about a bounty hunter teen girl in London

Cage Length (Rear Derallieur) and Total Capacity

Does toddler keep hands around private parts?

Remix compile error: Expected primary expression

TSP with revenue maximization

How can I add an ammeter and/or voltmeter to my home breaker panel?

Twelve Labours #08 - Dark Horse Bookmakers

Which of these will work? HDMI to VGA or HDMI to USB?

Need help reading piano sheet music



what is the best way to deal with a lot of dataset of different type (case classes)


How to define partitioning of DataFrame?Parallelize GZip file processing SparkHow to read a parquet file with lots of columns to a Dataset without a custom case class?Scala 2.11 & Spark 2.0.0 Create dynamically case class to encode DatasetHow to call Spark UDF on Datasets of case classes?Spark SQL - Read csv into Dataset[T] where T is a case class of Option[BigDecimal] fieldAvro Schema vs. Scala Case Class for Spark DatasetsStream files from HDFS using Apache Spark SteamingHow to create merge-sorted partitions in Sparkspark convert dataframe to dataset using case class with option fields






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty
margin-bottom:0;









0


















I have like 50+ different case classes and each one is bound to a different parquet source



val cc1ds = spark.read("/hdfs/input1").as[cc1]
val cc2ds = spark.read("/hdfs/input1").as[cc2]
...
val cc50ds = spark.read("/hdfs/input1").as[cc50]


how to handle them in case of need to process them?
I cannot use



val res:(dataset[cc1], ... dataset[cc50]) = (cc1ds, ... cc50ds)


and I would like to avoid having so many vals defined










share|improve this question






















  • 1





    Are they all different schema ?

    – howie
    Mar 28 at 22:00











  • yes 50 + different parquet with different schema

    – rio
    Apr 4 at 21:34











  • usually when I have a few I use a def and return a tuple ex ``` val (ds1,ds2, ds3) = getDS ```

    – rio
    Apr 4 at 21:35


















0


















I have like 50+ different case classes and each one is bound to a different parquet source



val cc1ds = spark.read("/hdfs/input1").as[cc1]
val cc2ds = spark.read("/hdfs/input1").as[cc2]
...
val cc50ds = spark.read("/hdfs/input1").as[cc50]


how to handle them in case of need to process them?
I cannot use



val res:(dataset[cc1], ... dataset[cc50]) = (cc1ds, ... cc50ds)


and I would like to avoid having so many vals defined










share|improve this question






















  • 1





    Are they all different schema ?

    – howie
    Mar 28 at 22:00











  • yes 50 + different parquet with different schema

    – rio
    Apr 4 at 21:34











  • usually when I have a few I use a def and return a tuple ex ``` val (ds1,ds2, ds3) = getDS ```

    – rio
    Apr 4 at 21:35














0













0









0








I have like 50+ different case classes and each one is bound to a different parquet source



val cc1ds = spark.read("/hdfs/input1").as[cc1]
val cc2ds = spark.read("/hdfs/input1").as[cc2]
...
val cc50ds = spark.read("/hdfs/input1").as[cc50]


how to handle them in case of need to process them?
I cannot use



val res:(dataset[cc1], ... dataset[cc50]) = (cc1ds, ... cc50ds)


and I would like to avoid having so many vals defined










share|improve this question
















I have like 50+ different case classes and each one is bound to a different parquet source



val cc1ds = spark.read("/hdfs/input1").as[cc1]
val cc2ds = spark.read("/hdfs/input1").as[cc2]
...
val cc50ds = spark.read("/hdfs/input1").as[cc50]


how to handle them in case of need to process them?
I cannot use



val res:(dataset[cc1], ... dataset[cc50]) = (cc1ds, ... cc50ds)


and I would like to avoid having so many vals defined







apache-spark apache-spark-sql apache-spark-dataset






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Mar 28 at 22:08









Roberto Congiu

3,8351 gold badge16 silver badges29 bronze badges




3,8351 gold badge16 silver badges29 bronze badges










asked Mar 28 at 21:57









riorio

3303 silver badges13 bronze badges




3303 silver badges13 bronze badges










  • 1





    Are they all different schema ?

    – howie
    Mar 28 at 22:00











  • yes 50 + different parquet with different schema

    – rio
    Apr 4 at 21:34











  • usually when I have a few I use a def and return a tuple ex ``` val (ds1,ds2, ds3) = getDS ```

    – rio
    Apr 4 at 21:35













  • 1





    Are they all different schema ?

    – howie
    Mar 28 at 22:00











  • yes 50 + different parquet with different schema

    – rio
    Apr 4 at 21:34











  • usually when I have a few I use a def and return a tuple ex ``` val (ds1,ds2, ds3) = getDS ```

    – rio
    Apr 4 at 21:35








1




1





Are they all different schema ?

– howie
Mar 28 at 22:00





Are they all different schema ?

– howie
Mar 28 at 22:00













yes 50 + different parquet with different schema

– rio
Apr 4 at 21:34





yes 50 + different parquet with different schema

– rio
Apr 4 at 21:34













usually when I have a few I use a def and return a tuple ex ``` val (ds1,ds2, ds3) = getDS ```

– rio
Apr 4 at 21:35






usually when I have a few I use a def and return a tuple ex ``` val (ds1,ds2, ds3) = getDS ```

– rio
Apr 4 at 21:35













0






active

oldest

votes













Your Answer






StackExchange.ifUsing("editor", function ()
StackExchange.using("externalEditor", function ()
StackExchange.using("snippets", function ()
StackExchange.snippets.init();
);
);
, "code-snippets");

StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "1"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/4.0/"u003ecc by-sa 4.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);














draft saved

draft discarded
















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55407462%2fwhat-is-the-best-way-to-deal-with-a-lot-of-dataset-of-different-type-case-class%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown


























0






active

oldest

votes








0






active

oldest

votes









active

oldest

votes






active

oldest

votes
















draft saved

draft discarded















































Thanks for contributing an answer to Stack Overflow!


  • Please be sure to answer the question. Provide details and share your research!

But avoid


  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.

To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55407462%2fwhat-is-the-best-way-to-deal-with-a-lot-of-dataset-of-different-type-case-class%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown









Popular posts from this blog

Kamusi Yaliyomo Aina za kamusi | Muundo wa kamusi | Faida za kamusi | Dhima ya picha katika kamusi | Marejeo | Tazama pia | Viungo vya nje | UrambazajiKuhusu kamusiGo-SwahiliWiki-KamusiKamusi ya Kiswahili na Kiingerezakuihariri na kuongeza habari

SQL error code 1064 with creating Laravel foreign keysForeign key constraints: When to use ON UPDATE and ON DELETEDropping column with foreign key Laravel error: General error: 1025 Error on renameLaravel SQL Can't create tableLaravel Migration foreign key errorLaravel php artisan migrate:refresh giving a syntax errorSQLSTATE[42S01]: Base table or view already exists or Base table or view already exists: 1050 Tableerror in migrating laravel file to xampp serverSyntax error or access violation: 1064:syntax to use near 'unsigned not null, modelName varchar(191) not null, title varchar(191) not nLaravel cannot create new table field in mysqlLaravel 5.7:Last migration creates table but is not registered in the migration table

은진 송씨 목차 역사 본관 분파 인물 조선 왕실과의 인척 관계 집성촌 항렬자 인구 같이 보기 각주 둘러보기 메뉴은진 송씨세종실록 149권, 지리지 충청도 공주목 은진현