Home Forums The XBRL API Converting text to values and sorting data

Viewing 2 reply threads
  • Author
    Posts
    • #201133
      Asif Saberi
      Participant

      Hi David: Thanks for your pointers. I am able to download data into excel, but the downloaded data formatting must be text since I cannot do mathematical operations on returned values. I am also not able to force format the cells into which these values are returned or point to these cells from another pre-formatted cell. Appreciate any pointers.

    • #201170
      Asif Saberi
      Participant

      Nevermind, I used the excel function VALUE… and it works.

      • This reply was modified 3 weeks, 2 days ago by Asif Saberi.
      • #201243
        David Tauriello
        Keymaster

        Asif – On the Excel version of XBRL Filed Data, if you choose the ‘Data’ option above the ‘Get’ button on XBRL Filed Data, you’ll get the values for fields. I believe the Function + Data (default) setting returns query results in a ‘Dynamic Array’ (this is a Microsoft feature).

    • #201172
      Asif Saberi
      Participant

      Hi David (and others): Working in excel, when I pull several years of a ‘concept’ for one entity, how do I ensure it is sorted in a certain order. Return seems random…Here is my call and its result
      =VALUE(XBRL.showData(CONCATENATE(B8,B10,B11,”&period.fiscal-period=Y&concept.local-name=”,$B17,”&fact.ha”,”s-dimensions=false&fact.ultimus=true&fields=fact.value,period.fisc”,”al-year, fact.limit(),fact.sort(), fact.offset()&”),””, “”, “0”))

      $20,289,000,000 2017
      $38,016,000,000 2020
      $25,913,000,000 2018
      $48,844,000,000 2019
      $34,940,000,000 2021

      • #201236
        David Tauriello
        Keymaster

        Hi Asif – you can use .sort(ASC|DESC) on fields that are being returned to design a sort order – see ‘sort’ in the documentation for details – https://xbrlus.github.io/xbrl-api

        This functionality exists on the query tool in the side panel of XBRL Filed Data – use the arrow keys on the selected fields (which can also be re-ordered by dragging and dropping them) to sort fields.

Viewing 2 reply threads
  • You must be logged in to reply to this topic.

Comment

Upcoming XBRL US Events

Center for Data Quality Committee Meeting
Wednesday, June 29, 2022

Domain Steering Committee Meeting
Tuesday, July 19, 2022

Communications & Services Steering Committee Meeting
Tuesday, July 19, 2022

Dive into Debt Securities – Illustrations of the FASB Implementation Guide
Wednesday, July 20, 2022

Public Review: Annual Comprehensive Financial Report Taxonomy
Monday, August 15, 2022