Announcement

Collapse
No announcement yet.

Looking for JSON Examples

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Looking for JSON Examples

    My first post on this forum was 8 years ago. Just bought my license last month!

    I'd like to download data from a JSON API into an SQLite table.
    I'm having trouble finding an example. Can someone point me in the right direction?
    The data looks like this: https://api.coinmarketcap.com/v2/tic...rt=1&limit=100

  • #2
    With php you can decode the json string into a php array structure. Next you have to form your insert sql statement the regular way. In scriptcase it means that you use the macro's to insert data into your database. You can generate sample code to pick a onrecord event and then select the insert macro.
    Albert Drent
    aducom software netherlands
    scriptcase partner, reseller, support and (turn-key) development
    www.scriptcase.eu / www.scriptcase.nl

    Comment


    • #3
      I'm making progress. But I'm stuck on this date issue.
      The JSON field, last_updated, it's represented as an integer. https://api.coinmarketcap.com/v2/tic...rt=1&limit=100
      Once imported into my table, it displays fine as an integer, but when I change the DataType to Date or Date and Time, the field display is blank.
      Do I need to adjust another parameter besides Edit Fields DataType? Or is some kind of conversion necessary?

      Comment


      • #4
        Please see the email I sent to you today ...
        Gunter Eibl
        email@GunterEibl.de

        asdw.de - Scriptcase & Open Source projects (German/English)
        scriptcase.coach - professional coaching for Scriptcase users (German)
        GunterEibl.de - About me (German)

        Comment

        Working...
        X