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

  • SEARCH
  • Home
  • 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 1076861
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T21:29:32+00:00 2026-05-16T21:29:32+00:00

My json output look like [{id:2,name:AAA},{id:1,name:BBB}]. I want to parse this using Qjson in

  • 0

My json output look like [{“id”:2,”name”:”AAA”},{“id”:1,”name”:”BBB”}]. I want to parse this using Qjson in mac. I am trying to parsing but I could not get any outputs . please help me.

Thanks in advance.

  • 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-05-16T21:29:32+00:00Added an answer on May 16, 2026 at 9:29 pm

    I think that the issue is quite simple, the JSON representation implies an Array of records.
    You are trying to access the record without using an iterator or a loop.

    Use the snippet below to transform the QVariant into a list

    QVariantList result = parser.parse(cityReply->readAll(), &ok).toList();
    

    And then loop against records for example:

    foreach(QVariant record, result) {
        QVariantMap map = record.toMap();
        qDebug() << map.value("name");
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a json output array like this { data: [ { name: Ben
I have a json output that looks like this.. { XXXX: { name: Dalvin
I'm using Json.NET First look at this: using System.Drawing; string json = JsonConvert.SerializeObject(new Rectangle(-3,6,32,32),
My JSON output currently looks like this: description:MUSIC VIDEO - 7:13\n\nCREDITS\n\nLabel: Black Pain Records\nProduction
During a parsing process using scrapy I have found this output [u'TARTARINI AUTO SPA
my current json output is id:3,name:test, and I need the 3 to be 3.
Trying to get a JSON output to work with jqGrid 'userdata' option. The example
I have an json output of the following (ignore the escape characters) {\sEcho\:1,\iTotalRecords\:10,\iTotalDisplayRecords\:10,\aaData\:[{\Job\:\developer\,\Name\:\kurt\},{\Job\:\plumber\,\Name\:\john\}]} which
I am having this rather long json output in my controller, I wish to
I am trying to figure out how to get a json output in python

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.