Take the following SQL Query:
SELECT Account, Amount AS Deposit, 0.00 AS Withdrawal, Date
FROM Deposits
WHERE Account = @Account
UNION
SELECT Account, 0 AS Expr1, Amount, Date
FROM Withdrawals
WHERE Account = @Account
ORDER BY Date Desc
As opposed to:
SELECT Account, TransactionType, Amount, Date
FROM Transactions
WHERE Account = @Account
ORDER BY Date Desc
In the first query has deposits and withdrawals stored in different tables and whenever they need to be seen together, such as when showing a bank statement, they're UNIONed together. The second query has all transactions, deposits and withdrawals, stored in one table and the transaction type is differentiated via the TransactionType column. The query results prodcued are not exactly the same but let's say the client is happy with either as the final output.
Is there any performance reason why setting up the database using the first schema is better or worse than the second schema?
EDIT: Just for the sake of clarity, I'd like to point out that the reason I was asking this question is to find out whether there's a performance benefit in keeping tables smaller and using a UNION when necessary over having one large table where I would use WHERE clause to find different types of data. I used the above example to better express my question. The advice on which schema is better for other reasons is welcomed, but please try to also answer the question as well.