Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
raven_ramon
Starting Member
1 Post |
Posted - 2011-02-28 : 14:09:29
|
| Hello good people in sql land, I am new to sql – i know basic of trying to combine 2 tables, but i think i need to create a query to pull data from 6 tables. The tables are listed below with their columns.Essentially, i am trying to get counts of unique players in a day by the gamename and network name and by the type and amount paid, where the refcode is not in 101010 (# is just for illustration). That is to say that a player can play in 1Level tournament and 2Level tournament, but he should be counted only once.I think my issue is that the playing data in is tables 4/5/6 and not sure how to connect all that with the other 3 tables.Can anyone of you please help me on this? I listed below what i think is needed.Table 1: GameCols: Gameid, gamename, networkid(game id is a numeric and the game name is the actual name, networkid is the machine type)Table 2: NetworkCols: Networkid, networkname(network id machine type and its name)Table 3: UserCol: Userid, refcode(general user info)Table 4: 1LevelGameCol: Tournamentid, userid1, userid2Table 5: 2LevelGameCol: Tournamentid, gameid, Table 6: BankFee, feetype, feedate, tournamentid(fee is money player pays, fee date is the day in question) |
|
|
shelbyoh
Starting Member
14 Posts |
Posted - 2011-02-28 : 14:12:18
|
| Are just created a view for reporting.Look at joins or unions |
 |
|
|
|
|
|
|
|