| | 1 | = Нормализација - TradingMK = |
| | 2 | |
| | 3 | === Универзална релација === |
| | 4 | |
| | 5 | Тргнуваме од една единствена универзална релација која ги содржи сите атрибути од целиот домен на апликацијата — сите табели споени во еден единствен запис. Атрибутите се преименувани каде е потребно за да нема дупликати на имиња. |
| | 6 | |
| | 7 | {{{ |
| | 8 | Universal_Relation_TradingMK( |
| | 9 | user_id, username, password, email, role, |
| | 10 | auth_provider, |
| | 11 | portfolio_id, balance, |
| | 12 | holding_id, holding_quantity, avg_price, |
| | 13 | stock_id, stock_symbol, stock_name, current_price, last_price, percentage, turnover, last_updated, |
| | 14 | history_id, history_price, history_timestamp, |
| | 15 | trade_id, trade_type, trade_status, trade_quantity, price_per_unit, trade_timestamp, trade_stock_symbol, |
| | 16 | transaction_id, txn_type, txn_quantity, txn_price, txn_timestamp, txn_origin, |
| | 17 | watchlist_id, price_above, price_below, |
| | 18 | oauth_token, oauth_email, oauth_provider, oauth_expires_at, oauth_created_at |
| | 19 | ) |