Return-Path: Delivered-To: apmail-couchdb-user-archive@www.apache.org Received: (qmail 85322 invoked from network); 9 Mar 2010 20:11:37 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 9 Mar 2010 20:11:37 -0000 Received: (qmail 77691 invoked by uid 500); 9 Mar 2010 20:11:08 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 77650 invoked by uid 500); 9 Mar 2010 20:11:08 -0000 Mailing-List: contact user-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@couchdb.apache.org Delivered-To: mailing list user@couchdb.apache.org Received: (qmail 77642 invoked by uid 99); 9 Mar 2010 20:11:08 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 09 Mar 2010 20:11:08 +0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests=FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_PASS,T_TO_NO_BRKTS_FREEMAIL X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of wobbet@gmail.com designates 209.85.217.221 as permitted sender) Received: from [209.85.217.221] (HELO mail-gx0-f221.google.com) (209.85.217.221) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 09 Mar 2010 20:11:04 +0000 Received: by gxk21 with SMTP id 21so1479766gxk.12 for ; Tue, 09 Mar 2010 12:10:43 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:content-type :content-transfer-encoding:subject:date:message-id:to:mime-version :x-mailer; bh=n2YgYqwuksOcSL3zFbRyBbrnjt6FhtdnsTq3wIGCigM=; b=jjoWyL0nQz475QbM6VJJHwX9euqKWb7AJSqsWVVPF3tGnzgoGL0LWqVS74ny8ACEw/ 6e8+bQCmhRu6xteOROaInA6JO3VTbFVflT3NIMMfQPdVkVl5bpLXQwF5f9nrDFqY8UWb 5H7+ovDQstcHuus8FNujqhDx5xxFY9Szsj7l8= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:content-type:content-transfer-encoding:subject:date:message-id :to:mime-version:x-mailer; b=RUMmB1QNsXayeHj3L2/JK0z2Lfudrt/SqlC49THg1/qYlOelxIri4o+LNwHmcigOiR EDI9W9GpoVobqB5179llLX2PUB0I66cJp+lIuGWjjskCiouipqplO9GDuSSLN9FYK/1n 7rYpPIziopd375joM5WkHeuNISSfq3g6UIEqc= Received: by 10.150.94.18 with SMTP id r18mr906130ybb.301.1268165443596; Tue, 09 Mar 2010 12:10:43 -0800 (PST) Received: from [10.0.0.4] (adsl-75-59-245-115.dsl.hstntx.sbcglobal.net [75.59.245.115]) by mx.google.com with ESMTPS id 21sm5829497iwn.11.2010.03.09.12.10.41 (version=TLSv1/SSLv3 cipher=RC4-MD5); Tue, 09 Mar 2010 12:10:42 -0800 (PST) From: Robert Sanford Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Subject: Newbie Data Modeling Date: Tue, 9 Mar 2010 14:10:40 -0600 Message-Id: To: user@couchdb.apache.org Mime-Version: 1.0 (Apple Message framework v1077) X-Mailer: Apple Mail (2.1077) I've done this w/ an RDBMS and have it down pretty well. I'm taking what = I already know and trying to learn CouchDB by taking an existing problem = and translating it to the new domain. I'm looking for advice on "The = CouchDB Way" of getting it done... I'm creating a game for one of my kids similar to games like Pokemon or = Magic - The Gathering. You have a collection of items that each have = different properties that result in a "score" depending on what happens = in the game environment. Let's say I have a "Wind Rider" card that is in play and that card will = normally attack at 50pts. But during game play an unexpected event = happens and a "Great Wind" blows through doubling the attack value of = all Wind based cards so it becomes 100pts of attack. Really cool and so = far a straightforward calculation. So now we add in that there are multiple tournaments that can be running = in that any player can participate in and each tournament can have a = different a different scoring system (Great Wind can be 2.0 in one = tournament, 1.25 in another, 3.5 in yet another) as well as a different = likelihood (5% chance in one, 25% in another, etc.). In my RDBMS model a Tournament has a Scoring System column and by = JOINing to that in a SQL VIEW I can can then run my calcs. If = performance is an issue (projected to be an issue at certain numbers = then I will run the calcs offline and denormalize the data modifying the = VIEW to use that so that my application code does not have to know = anything about how the calcs actually happen. So to recap... + A Tournament has some number of players who have a collection of = playable items that have base performance characteristics and then = bonuses + A Tournament will pit players head-to-head in a game where the highest = score wins based on the items played and then random events that occur = during play + A Tournament is associated with a Scoring System that determines the = likelihood and multiplier values of each random event We can talk about different tournament styles and schedules (single = elimination, double elimination, qualifying into a field followed by = single or double elimination) later...=20 Comments, suggestions, hints are welcome. Many thanks! rjsjr=