Jump to content

How to get stock values into Mysql


phpnewbee10

Recommended Posts

 

I would like to write a program that can scan thru every stock symbol (~5000 symbols) and determine the top 10 stocks by percent gain and the bottom 10 stocks by percent loss, but I am unsure of how to begin.

 

I would assume that I'd have to store every ticker and current price in a mysql table and every x mins or so, get a new price and compare the two, calculating the winners and losers and then outputting the results? Is this how I would go about this?

 

The other problem is that I can export end of day quotes into mysql from yahoo finance using php, but how would I go about getting ALL of the current stock prices (delayed quotes in fine) for ALL ticker symbols into the database to perform the above price comparisons?

 

Thanks in advance.

Link to comment
https://forums.phpfreaks.com/topic/186866-how-to-get-stock-values-into-mysql/
Share on other sites

Correct - you'd need a data source of current stocks and values and store them in your database.

 

then do your manipulation to see which has risen/fallen most.

 

you'll need a good data source and if you find one (especially free - which i doubt will exist) - please send me a personal message letting me know ;)

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.