We present the architecture of a complete intraday trading management system using a stock selection algorithm for building long/short portfolios. Our approach for stock selection is based on knowledge discovery in large databases technologies; more specifically, we build techniques that allow one to discover hidden price patterns which are capable of predicting the direction of stock prices. The base of the whole system is a novel pattern mining algorithm from time-series data, which involves highly compute-intensive aggregation calculations as complex but efficient distributed SQL queries on the relational databases that store the time-series. This algorithm follows similar path to Association Rule Mining algorithms (such as the Apriori and FP-Growth algorithms) but with major differences. First, it has one step more at initialization which uses a rule-based generator algorithm that transforms relations and data structures in a binary string format. These patterns contain mixed information of small price patterns (3, 4 or 5 candlesticks) and trading signals/filters produced by technical indicators. As output, instead of generating association rules, it produces probabilities (varies between 60% and 95%) about the future stock price direction such as “within next 5 periods, price will increase (or decrease) more than 2%”. Then, the stock selection system exploits all this information and uses it to find those stocks that appear to form patterns which have the highest accuracy in predicting prices. Each time period (finest interval length being 10minutes), the stock selector system, having the support of trading systems, examines and decides which stocks should be replaced in current portfolio by other more profitable stocks. The system testing, which produced interested results, is made of portfolio of 10 stocks having open long position and 5 stocks having open short positions.