Commit e9127cd5 authored by Dr.李's avatar Dr.李

update sql engine to get data both from full factor and experimental table

parent f4a0c339
...@@ -79,7 +79,7 @@ macro_styles = ['COUNTRY'] ...@@ -79,7 +79,7 @@ macro_styles = ['COUNTRY']
total_risk_factors = risk_styles + industry_styles + macro_styles total_risk_factors = risk_styles + industry_styles + macro_styles
factor_tables = [FullFactor] factor_tables = [FullFactor, Experimental]
DEFAULT_URL = 'postgresql+psycopg2://postgres:A12345678!@10.63.6.220/alpha' DEFAULT_URL = 'postgresql+psycopg2://postgres:A12345678!@10.63.6.220/alpha'
...@@ -479,7 +479,10 @@ class SqlEngine(object): ...@@ -479,7 +479,10 @@ class SqlEngine(object):
total_data = {} total_data = {}
transformer = Transformer(factors) transformer = Transformer(factors)
factor_data = self.fetch_factor(ref_date, transformer, codes) factor_data = self.fetch_factor(ref_date,
transformer,
codes,
used_factor_tables=[FullFactor, Experimental])
if benchmark: if benchmark:
benchmark_data = self.fetch_benchmark(ref_date, benchmark) benchmark_data = self.fetch_benchmark(ref_date, benchmark)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment