7 kyu

SQL Basics - Trimming the Field

7,819 of 7,820PG1

Description:

You have access to a table of monsters as follows:

monsters schema

  • id
  • name
  • legs
  • arms
  • characteristics

The monsters in the provided table have too many characteristics, they really only need one each. Your job is to trim the characteristics down so that each monster only has one. If there is only one already, provide that. If there are multiple, provide only the first one (don't leave any commas in there).

You must return a table with the format as follows:

output schema

  • id
  • name
  • characteristic

Order by id

Fundamentals
SQL

Stats:

CreatedJun 13, 2017
PublishedJun 13, 2017
Warriors Trained15745
Total Skips1572
Total Code Submissions42555
Total Times Completed7820
SQL Completions7819
Total Stars105
% of votes with a positive feedback rating86% of 862
Total "Very Satisfied" Votes655
Total "Somewhat Satisfied" Votes166
Total "Not Satisfied" Votes41
Total Rank Assessments11
Average Assessed Rank
6 kyu
Highest Assessed Rank
6 kyu
Lowest Assessed Rank
8 kyu
Ad
Contributors
  • PG1 Avatar
  • smile67 Avatar
Ad