Escolar Documentos
Profissional Documentos
Cultura Documentos
ISSN 2250-3153
Dr.A.D.Gawande
HOD (CMPS)
Department of computer science & Engineering
Sipna College of Engineering & Technology, Amravati, India
Prof. A.B.Deshmukh
Professor (CMPS)
Department of computer science & Engineering
Sipna College of Engineering & Technology, Amravati, India
I. INTRODUCTION
1.1 Distributed Database System
A distributed database (DDB) is a collection of data that
logically belongs to the same system but is spread over the sites
www.ijsrp.org
International Journal of Scientific and Research Publications, Volume 2, Issue 5, May 2012
ISSN 2250-3153
Fname
Lname
Site
Pos
Salary
Fragment1
Fragment2
Fragment3
Figure 2: Horizontal fragmentation
3.
4.
Fname
Lname
Fragment1
Site
Eid
Pos
Salary
Fragment2
International Journal of Scientific and Research Publications, Volume 2, Issue 5, May 2012
ISSN 2250-3153
_A1,...,An(_p(R))
Salary
Eid
Fname
Lname
Site
Fragment1
Fragment3
Pos
Fragment2
Fragment4
Allocation
CRUD Matrix
MCRUD Matrix
Fragmented Sub-Relations
ALP Table
Predicate Set
International Journal of Scientific and Research Publications, Volume 2, Issue 5, May 2012
ISSN 2250-3153
(1)
(2)
(3)
(4)
(5)
d. Allocate F to S
Figure 6: Fragmentation Allocation algorithm
Input: MCRUD of a relation that to be fragmented
Output: ALP table for that relation
for ( i =1; i <= TotalAttributes; i++)
{
for ( j =1; j <= TotalPredicates[i]; j++)
{
MAX[i][j] = 0;
for ( k =1; k <= TotalSites; k++)
{
for ( r =1; r <= TotalApplications[k]; r++) /* Calculating
sum of all applications cost of predicate j of attribute i at site k */
{
C[i][j][k][r] = fc*C + fr*R + fu*U + fd*D
S[i][j][k] + = C[i][j][k][r]
}
If S[i][j][k] > MAX[i][j] /*Find out at which site cost of
predicate j is maximum*/
{
MAX[i][j] = S[i][j][k]
POS[i][j] = k
}
SumOther = 0
for ( r =1; r <= A[i][j][k][k]; r++)
{
If (r!=k)
SumOther + = S[i][j][r]
}
}
ALPsingle[i][j] = S[i][j][POS[i][j]] SumOther /* actual
cost for predicate j of attribute i */
}
www.ijsrp.org
International Journal of Scientific and Research Publications, Volume 2, Issue 5, May 2012
ISSN 2250-3153
ALP[i] = 0
for ( j =1; j <= TotalPredicates[i]; j++) /*calculating total cost
for attribute i (locality precedence)*/
{
ALP[i] + = ALPsingle[i][j]
}
}
Application
CustId
101
102
103
104
105
106
107
OpenDate
05/01/12
18/01/12
10/02/12
06/03/12
12/03/12
25/03/12
28/03/12
Balance
30000
48000
15900
37750
50000
25000
45000
Branch
Pune
Pune
Nagpur
Mumbai
Pune
Nagpur
Mumbai
Entity,Attribute.Predica
te
Accounts.AccNo<1000
0
Accounts.AccNo>=100
00
Accounts.Type=Saving
Accounts.Type=Curren
t
.
.
.
Accounts.Balance<500
00
Accounts.Balance>=50
000
Account.Branch=Pune
Account.Branch=Nagp
ur
Account.Branch=Mum
bai
Site1
Ap
1
Ap
2
Site2
Ap
3
Ap
1
Ap
2
Site3
Ap
3
Ap
1
Ap
2
RU
Ap
3
RU
RU
RU
D
R
CR
UD
RU
CR
UD
RU
R
Accounts.Type=Saving
Accounts.Type=Curren
t
.
.
.
Accounts.Balance<500
00
Accounts.Balance>=50
000
Account.Branch=Pune
Account.Branch=Nagp
ur
Account.Branch=Mum
bai
Ap
1
Ap
2
Site2
Ap
3
Ap
1
Ap
2
Site3
Ap
3
Ap
1
Ap
2
RU
Ap3
R
R
CR
D
RU
RU
D
RU
R
CR
UD
RU
CR
UD
CR
CR
UD
RU
CR
UD
R
CR
UD
CR
UD
R
CR
UD
RD
CRU
CR
CR
UD
Entity,Attribute.Predica
te
Accounts.AccNo<1000
0
Accounts.AccNo>=100
00
Site1
R
CR
D
AccNo
01
02
03
04
05
06
07
CR
UD
R
CR
UD
CR
UD
R
CR
UD
RD
CR
U
Attribute Name
AccNo
Type
CustId
OpenDate
Balance
Branch
Precedence
6
22
6
7
10
50
www.ijsrp.org
International Journal of Scientific and Research Publications, Volume 2, Issue 5, May 2012
ISSN 2250-3153
Pune
Site1
Site1
Mumbai
Site1
Nagpur
Figure 10: Distributed banking database system
REFERENCES
Type
CustId
OpenDate
Balance
Branch
Saving
Current
Current
101
102
105
05/01/12
18/01/12
12/03/12
30000
48000
50000
Pune
Pune
Pune
Type
Saving
Current
CustId
OpenDate
Balance
104
107
06/03/12
28/03/12
37750
45000
Branch
Mumbai
Mumbai
Type
Current
Saving
[1]
[2]
[3]
[4]
[5]
[6]
[7]
CustId
OpenDate
Balance
Branch
[8]
103
106
10/02/12
25/03/12
15900
25000
Nagpur
Nagpur
[9]
From the above result, we can see that our technique has
successfully fragmented the Accounts relation and allocated the
fragments among the sites of the distributed system. As we have
only taken highest valued attribute from ALP table, no unwanted
fragments were created. Other relations of the distributed
banking database can be fragmented in the same way like
Accounts.
For simplicity we have considered only four sites of the system
for allocation. It is worth mentioning that our fragmentation
technique will work in the same way for large number of sites of
any distributed system.
IV. CONCLUSION
In this report, we presented an introduction to
distributed database system through a study that targeted two
main parts: in the first part we presented an exploration of
distributed database environment and types of fragmentation. In
the second part, we explore the horizontal fragmentation
technique of a relation according to locality of precedence of its
attributes.
Making proper fragmentation of the relations and
allocation of the fragments is a major research area in distributed
databases. Many techniques have been proposed by the
[10]
[11]
[12]
[13]
[14]
[15]
[16]
AUTHORS
First Author Ms. Priyanka R. Bhuyar, M.E.-I Year (CSE),
Sipna college of Engineering & Technology, Amravati, India,
priyanka.bhuyar@gmail.com
www.ijsrp.org
International Journal of Scientific and Research Publications, Volume 2, Issue 5, May 2012
ISSN 2250-3153
www.ijsrp.org