Forum Discussion

shong's avatar
shong
Adept
8 years ago

undefined collection: solutions_data

Hello 

I am using API browser to execute this LiQL:

select * from solutions_data

 

But it returns the following error:

{
"status" : "error",
"message" : "undefined collection: solutions_data",
"data" : {
"type" : "error_data",
"code" : 602,
"developer_message" : "",
"more_info" : ""
},
"metadata" : { }
}

 

According to the API V2,

https://community.lithium.com/t5/Developer-Documentation/bd-p/dev-doc-portal?section=commv2&collection=solutions_data

I can see the description of solutions_data collection, what's wrong?

 

Regards

Mike

  • Worked perfect for me. Added a where so I only get accepted solutions back.

    SELECT solution_data,is_solution FROM messages WHERE is_solution = true

     

    Thanks!

  • shong

    According to the document that you have mentioned it states that we can fetch attribute "solution_data" from messages. The query will be as below.

    select solution_data from messages

    Which will return the "solution_data" value for all the messages.

    Please give KUDOS and mark as solution if this was helpful

    • shong's avatar
      shong
      Adept
      Hi him_varma
      Thanks for your reply. I execute the LiQL as you said, it returns the result like this;
      {
      "status" : "success",
      "message" : "",
      "http_code" : 200,
      "data" : {
      "type" : "messages",
      "list_item_type" : "message",
      "size" : 3,
      "items" : [ {
      "type" : "message",
      "solution_data" : { }
      }, {
      "type" : "message",
      "solution_data" : { }
      }, {
      "type" : "message",
      "solution_data" : { }
      } ]
      },
      "metadata" : { }
      }

      No detailed information about solution_data, what's wrong?

      Regards
      Shong
      • VikasB's avatar
        VikasB
        Boss

        Hi shong

        It's empty means they did not get accepted as a solution yet.  

        Try below query you will get false.

        select solution_data,is_solution from messages