Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8226959
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T15:57:22+00:00 2026-06-07T15:57:22+00:00

I would like to know if Java supports casting and melting of data somehow.

  • 0

I would like to know if Java supports “casting and melting” of data somehow. By “casting and melting” I mean “reshaping” data in the way that the R package reshape ( or reshape2) does.

So I have a SQL query that returns the following ( in a ResultSet ) :

---------------------
|Id | Key    | Value|
---------------------
|1  | Name   | John |
|1  | Gender | Male | 
|1  | Country| U.S  |
|2  | Name   | Tom  |
|2  | Gender | Male |
|2  | Country| Cuba |
---------------------

I want to reshape this data so that I can get this :

------------------------
|Id|Name|Gender|Country|
------------------------
|1 |John|Male  |U.S    |
|2 |Tom |Male  |Cuba   |
------------------------

How do Java programmers achieve this transformation ?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T15:57:24+00:00Added an answer on June 7, 2026 at 3:57 pm

    Not directly. R is more focused on data while Java is more of a general purpose language and lacks some of the various specific functions. You can either program something yourself; or use a “ETL” (Extract, Transform, Load) tool such as Kettle http://kettle.pentaho.com/

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I would like to know if there's a way in java to find out
I would like to know how to efficiently implement filesystem changes in java? Say
I would like to know, in a practical sense, on a large scale (Java
As I'm new to java, I would like to know, 1. How many Default
I wanted to know the existing Augmented Reality Frameworks in Java. I would like
I would like to know the best method of breaking up large Java Swing
I would like to do some stuff in Java that would be clearer if
I'm comming from the java world, and i'd like to know if there's anything
i would like know some reference. I know i can googling it. but prefer
Would like to know what a programmer should know to become a good at

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.