Discover Refinitiv
MyRefinitiv Refinitiv Perspectives Careers
Created with Sketch.
All APIs Questions & Answers  Register |  Login
Ask a question
  • Questions
  • Tags
  • Badges
  • Unanswered
Search:
  • Home /
  • TRTH /
avatar image
Question by Hubert CANEVET · Jul 20, 2017 at 11:54 AM · trth api

Getting an extraction back

Hello everybody,

I launched asynchronous TickHistoryIntradaySummaries requests, with a schedule named

IntraDaySummariesSchedule.

On hosted datascope, the schedule shows a line of the type "

9011311.TH_IntradaySummaries_Schedule.20170720.170535.2000000001279640.tm03n01.csv.gz"

with a drop-down list, that provides to View / Download / Notes.

So, when I launch this

string strScheduleName = "TH IntradaySummaries Schedule";
Schedule schedule = this.FindScheduleByName(extractionsContext, strScheduleName);
if (schedule != null)
{
    Console.WriteLine("Number of completed extractions : {0}", schedule.CompletedExtractions.Count);
}
else
{
    Console.WriteLine("No schedule received.");
}

I should wait for at least 1, no ?

I am answered 0, as the number of completed extractions.

People who like this

0 Show 0
Comment
10 |1500 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

2 Replies

  • Sort: 
avatar image
REFINITIV
Best Answer
Answer by jirapongse.phuriphanvichai · Jul 21, 2017 at 03:37 AM

@Hubert CANEVET

You need to call ExtractionContext::LoadProperty before accessing CompletedExtractions.

extractionsContext.LoadProperty(schedule, "CompletedExtractions");

The full code is:

ExtractionsContext extractionsContext = dssClient.extractionsContext;

var schedule = extractionsContext.ScheduleOperations.GetByName("TH IntradaySummaries Schedule");

if (schedule != null)
{
    extractionsContext.LoadProperty(schedule, "CompletedExtractions");
    Console.WriteLine("Number of completed extractions : {0}", schedule.CompletedExtractions.Count);
    foreach (var extraction in schedule.CompletedExtractions)
    {
        Console.WriteLine("Extraction {0} status = {1}", extraction.ReportExtractionId, extraction.Status);
        var reportExtraction = extractionsContext.ReportExtractionOperations.Get(extraction.ReportExtractionId);
        extractionsContext.LoadProperty(reportExtraction, "Files");
        Console.WriteLine("File Count {0}", reportExtraction.Files.Count);
        foreach (var file in reportExtraction.Files)
        {
            Console.WriteLine("File Name: {0}", file.ExtractedFileName);
        }
    }
}
else
{
    Console.WriteLine("No schedule received.");
}

You can refer to REST API Reference Tree for C# snippet code.

Comment

People who like this

0 Show 0 · Share
10 |1500 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

avatar image
Answer by Hubert CANEVET · Jul 21, 2017 at 03:58 AM

Hello,

Oh, I ignored that.

Thank you very much for your answer.

Comment

People who like this

0 Show 0 · Share
10 |1500 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Watch this question

Add to watch list
Add to your watch list to receive emailed updates for this question. Too many emails? Change your settings >
9 People are following this question.

Related Questions

TRTH VBD data question

Java code for Bulk Import of Fixed Income ISINs to get RICs in TRTH v2 REST API

InstrumentList and InstrumentListItems

futures expiry date in TRTH python

Purging the objects on the server

  • Feedback
  • Copyright
  • Cookie Policy
  • Privacy Statement
  • Terms of Use
  • Careers
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Alpha
  • App Studio
  • Block Chain
  • Bot Platform
  • Calais
  • Connected Risk APIs
  • DSS
  • Data Fusion
  • Data Model Discovery
  • Datastream
  • Eikon COM
  • Eikon Data APIs
  • Electronic Trading
    • Generic FIX
    • Local Bank Node API
    • Trading API
  • Elektron
    • EMA
    • ETA
    • WebSocket API
  • Legal One
  • Messenger Bot
  • Messenger Side by Side
  • ONESOURCE
    • Indirect Tax
  • Open PermID
    • Entity Search
  • Org ID
  • PAM
    • PAM - Logging
  • ProView
  • ProView Internal
  • Product Insight
  • Project Tracking
  • Refinitiv Data Platform
    • Refinitiv Data Platform Libraries
  • Rose's Space
  • Screening
    • Qual-ID API
    • Screening Deployed
    • Screening Online
    • World-Check One
    • World-Check One Zero Footprint
  • Side by Side Integration API
  • TR Knowledge Graph
  • TREP APIs
    • CAT
    • DACS Station
    • Open DACS
    • RFA
    • UPA
  • TREP Infrastructure
  • TRIT
  • TRKD
  • TRTH
  • Thomson One Smart
  • Transactions
    • REDI API
  • Velocity Analytics
  • Wealth Management Web Services
  • World-Check Data File
  • Explore
  • Tags
  • Questions
  • Badges