2022-05-02 23:41:28 +08:00
|
|
|
{
|
|
|
|
"data": {
|
|
|
|
"question": {
|
|
|
|
"questionId": "2381",
|
|
|
|
"questionFrontendId": "2252",
|
|
|
|
"categoryTitle": "Database",
|
|
|
|
"boundTopicId": 1447354,
|
|
|
|
"title": "Dynamic Pivoting of a Table",
|
|
|
|
"titleSlug": "dynamic-pivoting-of-a-table",
|
|
|
|
"content": null,
|
2023-12-09 18:42:21 +08:00
|
|
|
"translatedTitle": "表的动态旋转",
|
2022-05-02 23:41:28 +08:00
|
|
|
"translatedContent": null,
|
|
|
|
"isPaidOnly": true,
|
|
|
|
"difficulty": "Hard",
|
2023-12-09 18:42:21 +08:00
|
|
|
"likes": 6,
|
2022-05-02 23:41:28 +08:00
|
|
|
"dislikes": 0,
|
|
|
|
"isLiked": null,
|
|
|
|
"similarQuestions": "[]",
|
|
|
|
"contributors": [],
|
|
|
|
"langToValidPlayground": null,
|
2023-12-09 18:42:21 +08:00
|
|
|
"topicTags": [
|
|
|
|
{
|
|
|
|
"name": "Database",
|
|
|
|
"slug": "database",
|
|
|
|
"translatedName": "数据库",
|
|
|
|
"__typename": "TopicTagNode"
|
|
|
|
}
|
|
|
|
],
|
2022-05-02 23:41:28 +08:00
|
|
|
"companyTagStats": null,
|
|
|
|
"codeSnippets": null,
|
2023-12-09 18:42:21 +08:00
|
|
|
"stats": "{\"totalAccepted\": \"363\", \"totalSubmission\": \"663\", \"totalAcceptedRaw\": 363, \"totalSubmissionRaw\": 663, \"acRate\": \"54.8%\"}",
|
2022-05-02 23:41:28 +08:00
|
|
|
"hints": [],
|
|
|
|
"solution": null,
|
|
|
|
"status": null,
|
|
|
|
"sampleTestCase": "{\"headers\":{\"Products\":[\"product_id\",\"store\",\"price\"]},\"rows\":{\"Products\":[[1,\"Shop\",110],[1,\"LC_Store\",100],[2,\"Nozama\",200],[2,\"Souq\",190],[3,\"Shop\",1000],[3,\"Souq\",1900]]}}",
|
2023-12-09 18:42:21 +08:00
|
|
|
"metaData": "{\"mysql\":[\"Create table If Not Exists Products (product_id int, store varchar(7), price int)\"],\"mssql\":[\"Create table Products (product_id int, store varchar(7), price int)\"],\"oraclesql\":[\"Create table Products (product_id int, store varchar(7), price int)\"],\"database\":true,\"manual\":true,\"name\":\"dynamic_pivoting_table\",\"pythondata\":[\"Products = pd.DataFrame([], columns=['product_id', 'store', 'price']).astype({'product_id':'Int64', 'store':'object', 'price':'Int64'})\"],\"database_schema\":{\"Products\":{\"product_id\":\"INT\",\"store\":\"VARCHAR(7)\",\"price\":\"INT\"}}}",
|
2022-05-02 23:41:28 +08:00
|
|
|
"judgerAvailable": true,
|
|
|
|
"judgeType": "large",
|
|
|
|
"mysqlSchemas": [
|
|
|
|
"Create table If Not Exists Products (product_id int, store varchar(7), price int)",
|
|
|
|
"Truncate table Products",
|
|
|
|
"insert into Products (product_id, store, price) values ('1', 'Shop', '110')",
|
|
|
|
"insert into Products (product_id, store, price) values ('1', 'LC_Store', '100')",
|
|
|
|
"insert into Products (product_id, store, price) values ('2', 'Nozama', '200')",
|
|
|
|
"insert into Products (product_id, store, price) values ('2', 'Souq', '190')",
|
|
|
|
"insert into Products (product_id, store, price) values ('3', 'Shop', '1000')",
|
|
|
|
"insert into Products (product_id, store, price) values ('3', 'Souq', '1900')"
|
|
|
|
],
|
|
|
|
"enableRunCode": true,
|
2023-12-09 18:42:21 +08:00
|
|
|
"envInfo": "{\"mysql\":[\"MySQL\",\"<p>\\u7248\\u672c\\uff1a<code>MySQL 8.0<\\/code><\\/p>\"],\"mssql\":[\"MS SQL Server\",\"<p>mssql server 2019.<\\/p>\"],\"oraclesql\":[\"Oracle\",\"<p>Oracle Sql 11.2.<\\/p>\"],\"pythondata\":[\"Pandas\",\"<p>Python 3.10 with Pandas 2.0.2 and NumPy 1.25.0<\\/p>\"],\"postgresql\":[\"PostgreSQL\",\"<p>PostgreSQL 16<\\/p>\"]}",
|
2022-05-02 23:41:28 +08:00
|
|
|
"book": null,
|
|
|
|
"isSubscribed": false,
|
|
|
|
"isDailyQuestion": false,
|
|
|
|
"dailyRecordStatus": null,
|
|
|
|
"editorType": "CKEDITOR",
|
|
|
|
"ugcQuestionId": null,
|
|
|
|
"style": "LEETCODE",
|
|
|
|
"exampleTestcases": "{\"headers\":{\"Products\":[\"product_id\",\"store\",\"price\"]},\"rows\":{\"Products\":[[1,\"Shop\",110],[1,\"LC_Store\",100],[2,\"Nozama\",200],[2,\"Souq\",190],[3,\"Shop\",1000],[3,\"Souq\",1900]]}}",
|
|
|
|
"__typename": "QuestionNode"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|