Serving the Quantitative Finance Community

 
User avatar
EndOfTheWorld
Topic Author
Posts: 4
Joined: September 30th, 2008, 8:35 am

Bloomberg API question

March 17th, 2011, 11:52 am

Good afternoon,I'm using the Bloomberg API with VBA. Is there a way to extract historic data with override? The function BLPSubscribe allow me to extract live data with override but there is no value date as input top extract historic. Is there any other function?Thanks
 
User avatar
Hansi
Posts: 41
Joined: January 25th, 2010, 11:47 am

Bloomberg API question

March 17th, 2011, 12:00 pm

You'll get an answer quicker by hitting <HELP> twice.
 
User avatar
EndOfTheWorld
Topic Author
Posts: 4
Joined: September 30th, 2008, 8:35 am

Bloomberg API question

March 17th, 2011, 3:37 pm

Of course that's an alternative: but it's been two days I'm with them on the chat, and they barely got the fact that I don't want to use excel but VBA.So I thouhgt I could use some help from the willmoters...
Last edited by EndOfTheWorld on March 16th, 2011, 11:00 pm, edited 1 time in total.
 
User avatar
rubsha
Posts: 0
Joined: March 17th, 2011, 12:54 pm

Bloomberg API question

March 18th, 2011, 7:26 am

I am not sure if this would help with the override issue but you could try BDH for historical data and and BDS for bulk.
 
User avatar
EndOfTheWorld
Topic Author
Posts: 4
Joined: September 30th, 2008, 8:35 am

Bloomberg API question

March 18th, 2011, 10:19 am

Right so Bloomberg finally said they do not support this kind of request (related to WAPI).Yes rubsha BDH allows me to extract historical data which I can override: there is an input for the historical date and the override fields.But my goal is to extract the data within vba, so I know currently I can use the following functions:- BLPGetHistoricalData: I can extract historical data but there is no fields for precising the override fields- BLPSusbscribe: I can override fields but no input for historical dataI would like to know if there is a function which combine the two (like in the excel version): at the moment I'm using an object called BLP_DATA_CTRLLib.BlpData, maybe I shoud use something else. I would really appreciate any help.
 
User avatar
MHill
Posts: 21
Joined: February 26th, 2010, 11:32 pm

Bloomberg API question

March 18th, 2011, 10:24 am

What specifically are you trying to do? For bonds, you can often send SETTLE_DT as an override to get historical data (though ther may be extra nuances to using this)
 
User avatar
EndOfTheWorld
Topic Author
Posts: 4
Joined: September 30th, 2008, 8:35 am

Bloomberg API question

March 18th, 2011, 2:07 pm

Spefically, I'm trying to get the BEST EPS field historically, but I want to override BEST_FPERIOD_OVERRIDE with BF, FY1,... I managed to do that with the function BDP, and I'm trying to reproduce it using VBA and BLP_DATA_CTRLLib.BlpData object. But I cannot find the function I should use to achieve this...
 
User avatar
MHill
Posts: 21
Joined: February 26th, 2010, 11:32 pm

Bloomberg API question

March 18th, 2011, 3:35 pm

Have a look at the attachment (if it worked!). It uses the COMv3 API thing. I've adjusted one of the Bloomberg examples to use overrides in a historical request. Sorry, I've left it a bit messy, but you should get the idea.
Attachments
COMv3_HistoryExample.zip
(32.46 KiB) Downloaded 78 times
 
User avatar
EndOfTheWorld
Topic Author
Posts: 4
Joined: September 30th, 2008, 8:35 am

Bloomberg API question

March 21st, 2011, 6:31 am

That's great!!!Thanks for your help - I'm going to look into into it but this function seems the solution.Thanks you for your help
 
User avatar
AndaH
Posts: 1
Joined: May 5th, 2009, 2:26 pm

Bloomberg API question

May 4th, 2011, 8:07 am

Hey everyone!WAPI <Go> has quite some useful examples.I was trying to increase the scale of the historic data request example.In order to speed the thing up, I wanted to make sequential requests for each ticker.I would then use the historic data for some calculations, and loop to the next ticker.The problem I encountered was that the loop would request the Bloomberg data sequentially but then use only the last ticker's data for actually doing the calculations andoutput the results on the Excel sheet.I was not able to figure out exactly why this would happen but then decided to move to VB.Net and tackle the problem there.It works fine now and I am happy to share.The code selects a list of securities from an Excel file and returns historic data to the console.I am going to use it for technical analysis and since this is a personal project I am happy to collaborate.You will probably have to change these declarations:xlsFile = "c:\test1.xls" (location of your Excel file: a list of equity tickers in column A, on sheet "Tabelle1"; cell A1 ="Tickers")xlsSheet = "Tabelle1$" (sheet from which you want to import tickers)Add me on linked-in http://at.linkedin.com/pub/anda-hoschek/a/442/555
Attachments
API VB.Net sequential historic request.zip
(1.67 KiB) Downloaded 79 times
 
User avatar
SlavekR
Posts: 0
Joined: July 26th, 2003, 11:29 pm

Bloomberg API question

June 7th, 2011, 1:53 pm