MLM应用数据库 [英] MLM application database

查看:101
本文介绍了MLM应用数据库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我正在开发一个多层次营销的应用程序,其中一个用户可以有5个底层人员,这5个人可以有5个底层人员,依此类推,直到9级。

在每个级别,每个用户都会得到一些点。

我想向上周显示每个用户点数(周三到周二)以及加入之日的总点数。

请帮我为此设计数据库和查询。

如果有任何团体可以帮我解决这个问题,那就太棒了。



提前致谢。



我的尝试:



我在这一点上陷入困​​境,所以我需要帮助

Hi,
I'm developing an application on Multi level marketing in which an user can have 5 underlying people and those 5 can have 5 underlying people and so on till 9 level.
At each level, there will be some point every user will get.
I wanna show the every user last week points (Wednesday to Tuesday) and total points from the date of joining.
Please help me to design the database for this and query also.
If any body can help me out here with the code, that will be great.

Bunch of thanks in advance.

What I have tried:

I am stuck at this point, so i need help

推荐答案

我会看(谷歌搜索)建模树数据库中的结构 - 有一些方法,SQL的向导,Joe Celko,有这种方法(邻接列表) Adjace树木的ncy列表模型 - 第一部分 [ ^ ]



看看其他方法 SQL中的树:嵌套集和物化路径| BMC社区 [ ^ ]
I would be looking at (googling) modelling tree structures in a database - there are a few approaches, the wizard of SQL, Joe Celko, has this approach (Adjacency lists) The Adjacency List Model for Trees - Part I[^]

Have a look here for other approaches Trees in SQL: Nested Sets and Materialized Path | BMC Communities[^]


这篇关于MLM应用数据库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆