US 2013 0080995A1 (19) United States (12) Patent Application Publication (10) Pub. No.: US 2013/0080995 A1 RAZA (43) Pub. Date: Mar. 28, 2013

(54) METHOD AND AN APPARATUS FOR (52) U.S. Cl. DEVELOPNG SOFTWARE USPC ...... 717/107; 717/120 (57) ABSTRACT (76) Inventor: Ahmad RAZA, Lahore (PK) A Software component, is constructed on the basis of a set of predetermined rules, and by utilizing a source object, a token (21) Appl. No.: 13/242.558 value and a parameter, wherein the Source object is stored in a source object repository, and wherein the source object comprises a component value and/or a token value, wherein (22) Filed: Sep. 23, 2011 the component value may be associated with the token value. For constructing the software component, the token value is processed and a token result, obtained by processing the Publication Classification token value, is utilized for constructing the software compo nent, wherein the parameter may also be utilized for the (51) Int. Cl. processing of the token value and/or constructing the Soft G06F 9/44 (2006.01) ware component.

2O

Create Source object repository 168

Create Software component constructor 170

Construct software component 142 Patent Application Publication Mar. 28, 2013 Sheet 1 of 96 US 2013/0080995 A1

Create source object repository 168

Create Software component constructor 170

Construct software component 142

FIG. 1A Patent Application Publication Mar. 28, 2013 Sheet 2 of 96 US 2013/0080995 A1

108

110a 11 O Software Component 142 Select set of predetermined rules 140 11 Ob 112 Source component 144

Categorize source Component 144 in 11 OC indeterminable source component 148 Component value 146 and determinable source component 150 114a 114 Token value 154 Define data token 152 114b Token Result 156 114C Set of data token rules 158 116 116a Define parameter 16016 Parameter value 162 118 Create data model 164 12O 122a Create source object repository 168 Parameter value resolution 122 module 17Oa Create 122b Software component constructor 170 Data token processing module 17Ob 124 122 Create source object 166 C

Source object resolution 126 module 17OC

Construct software component 142 Yes

ls another

- 134 Source object 166 Utilize again required?

another Software YeS component 1422

NO 132 FIG. 1B End Patent Application Publication Mar. 28, 2013 Sheet 3 of 96 US 2013/0080995 A1

212 Software component COnStructOr 17O StartS 214 Resolve parameter value 162n

Identify desired source objects 166n

218 Resolve component values 146n

220 Construct software COmpOnentS 142n

224

FIG. 2 Patent Application Publication Mar. 28, 2013 Sheet 4 of 96 US 2013/0080995 A1

Computer Input/Output Memory Interface Unit(s) ROM BIOS 312

314

AuxiliaryuXIIIary StStorage BuS 306 Interface ( )

318 Auxiliary Storage

324 Expansion 32O QFP face Video Controller KC 326 {-> Communication Interface

Communication Link 354 Network Auxiliary Storage Remote Computer(s)

356 Remote Auxiliary Storage Patent Application Publication Mar. 28, 2013 Sheet 5 of 96 US 2013/0080995 A1

Exemplary sets of predetermined rules 400

ACCESS SELECT query O ORACLE SELECT query 2

FIG. 4A Patent Application Publication Mar. 28, 2013 Sheet 6 of 96 US 2013/0080995 A1

i

SD O P H O - CO CO CO O O CC

s Patent Application Publication Mar. 28, 2013 Sheet 7 of 96 US 2013/0080995 A1

CIO|#7 Ǻ-r)!ISIFanolfikº-Goedseli?M)

Patent Application Publication Mar. 28, 2013 Sheet 8 of 96 US 2013/0080995 A1

s

s

s

s

s Patent Application Publication Mar. 28, 2013 Sheet 9 of 96 US 2013/0080995 A1

Patent Application Publication Mar. 28, 2013 Sheet 10 of 96 US 2013/0080995 A1

Patent Application Publication Mar. 28, 2013 Sheet 11 of 96 US 2013/0080995 A1

Patent Application Publication Mar. 28, 2013 Sheet 12 of 96 US 2013/0080995 A1

60/37 |Z/760/37 CEID,—K) Patent Application Publication Mar. 28, 2013 Sheet 13 of 96 US 2013/0080995 A1

|07 |07 KlenbLOETESSSEOOV KlenbLOETESSSEOOV

Patent Application Publication Mar. 28, 2013 Sheet 14 of 96 US 2013/0080995 A1

B/|#7 Patent Application Publication Mar. 28, 2013 Sheet 15 of 96 US 2013/0080995 A1

90/17

GEGE?D-GENEEX)(º(º)--GOEIED–GNõD-GŒD-? Patent Application Publication Mar. 28, 2013 Sheet 16 of 96 US 2013/0080995 A1

S

9) O P H O - CO

- O CC O

s Patent Application Publica US 2013/0080995 A1

Patent Application Publication Mar. 28, 2013 Sheet 18 of 96 US 2013/0080995 A1

Patent Application Publication Mar. 28, 2013 Sheet 19 of 96 US 2013/0080995 A1

CD CD a O O CO CD CD (s a O

s Patent Application Publication Mar. 28, 2013 Sheet 20 of 96 US 2013/0080995 A1

UZ/#7

b0/7

90/57

899#7 Patent Application Publication Mar. 28, 2013 Sheet 21 of 96 US 2013/0080995 A1

GEGOOECD Patent Application Publication Mar. 28, 2013 Sheet 22 of 96 US 2013/0080995 A1

20?7 KuanbLOETESETOVHO ÁuenbLOETESETOVHO ZO?7

Patent Application Publication Mar. 28, 2013 Sheet 23 of 96 US 2013/0080995 A1

WHERE 4 71 a. GROUP 4. 7 b UNIONALL 4 7 1 C floAlaGrp 47171 ee. IF 4. 7 1 SUM INNER h LEFT 4 7 1 JOIN 4 OluS Sion 4. m DECODE WhrXOr 77 21 a.n floNam Col 4 7 2 b floAla floXOr 7722 SrCAla 4 7 2 e floNam Cnd 472g7 2 Value 4 7 2 h true-result 4 7 2 falsefalse-result result 472 table-name K floAla 1 SrCAla2 floAla2

FIG. 4S Patent Application Publication Mar. 28, 2013 Sheet 24 of 96 US 2013/0080995 A1

FROM BY Openind parenthesis Closind Oarenthesis

SrCAa1

FIG. 4T Patent Application Publication Mar. 28, 2013 Sheet 25 of 96 US 2013/0080995 A1

Data Token Comprised Data Value OrVGro True, False Or NULL OrVUni i11 s True, False Or NULL SrCUseCnd 5 1 6 A Strind Or NULL COUSeCnd sis1 8 A Strind Or NULL COReuse 5 2 O True, False or NULL tknAliasknAias 522 termonth 524 letkavin, %TknMth,argCOmp, argTrue,ard False% tknCurvErackets

intencodeBegintknitemCOdeBedin 528 inBeg tknitemCode End 5 3 O

FIG. 5A Patent Application Publication Mar. 28, 2013 Sheet 26 of 96 US 2013/0080995 A1

550a Start

550b EmbStr = a target string

Post = Last occurrence ofs: "" N/ from left side

550d 55Oe Slas NO occurrence of "{" Return EmbStr seisOund? Yes - 55of Pos2 = First occurrence of "}" from left side after PoS 1 550g DtaTKn = String between Pos 1 and POS2

TKn Result = Processed DtaTKn result

55Oi POS3 = POS2 + 1

550 55OK ls char at Yes Pos4 - Last occurrence of "" Pos3 = "}"? iust before POS1 from left side

NO 55Ol 550m ls YeS TKn Result a NULL TKnReSult = "1 = 1"

Replace string from Post to POS2 in EmbStr With tknResult

FIG. 5B Patent Application Publication Mar. 28, 2013 Sheet 27 of 96 US 2013/0080995 A1

ls 55OO 550p TKn Result a NULL TKnReSUlt - "1 - 1" alue?

NO 550d 55Or Replace char at Pos3 in Replace string from Pos4 to EmbStr With "" POS3 in EmbStr With tkin Result

Replace char at Pos4 in EmbStr With ""

55Ot Replace string from Post to POS2 in EmbStr With tknReSUlt

FIG. 5C Patent Application Publication Mar. 28, 2013 Sheet 28 of 96 US 2013/0080995 A1

ormOrvld OrmNMthCnt OrmeCMth ormOraQr OrmftJoi OrmuseCnd Ormitm3ed OrmitmEnd

FIG. 6 Patent Application Publication Mar. 28, 2013 Sheet 29 of 96 US 2013/0080995 A1

OrWhr SrCld SrCUOinFlo SrCJoinTOFC SrCJoinTOSrC COAla COXOr COIGroFun

FIG. 7A

Patent Application Publication Mar. 28, 2013 Sheet 31 of 96 US 2013/0080995 A1

OJSKJOIq] Patent Application Publication Mar. 28, 2013 Sheet 32 of 96 US 2013/0080995 A1

81 Oa queryBuilder(primOryld)

S this first Cal Yes 81 OC to queryBuilder in this varCaCnt = 0 executionirrh2 81 OC varMthAry = {"Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Now", y Dec"

81 Oe Initialize varOryRod VarCurMth = 0

81 Of Initialize varSrCRCd 810g Initialize warFlcRCd varColXpr="

81 Oh Initialize varTblAry VarCOAla = "

VarTbildx = 0 varWrkQry = "

VarSrCAV = False VarJoiSrc = "

VarFldAV = False OP B

VarSrCCnt = 0

varFReuCnt = 0

FIG. 8A Patent Application Publication Mar. 28, 2013 Sheet 33 of 96 US 2013/0080995 A1

OP B

NO varCryStr = "

Yes 811 VarjoiAla = " O varAlaCnt = 0

VarFReStr = " 811q Resolve all parameter values

varUniCry = "

VarWrkUni - "

WarCnbWhr = "

varFRetOry =

varGrpLis =

VarFldLiS = "

varLftOpr="

varFgtOpr =

WarCaCnt = varCalCnt + 1

FIG. 8B Patent Application Publication Mar. 28, 2013 Sheet 34 of 96 US 2013/0080995 A1

812b Open recordset varOryRod comprising thiQry, where qryld = primOryld

812C Open recordset varSrcRcd comprising thiQrySrc, where srcQryld = dryld and order is On SrCOrd

SEOF Of VarSrCRCC True?

No

VarSrCAV = CheckAvailablity(SrcUseCnd)

Move to next record of ls varSrCAVI True? VarSrCRCd Yes varSrCCnt = varSrCCnt + 1

812 -s is gruntled- No varCurAla = NewAlias() YeS varTblAry(varSrcCnt, 1) = Srclo

varTblAry(varSrcCnt.2) = varCurAla & 5 FIG. 8C Patent Application Publication Mar. 28, 2013 Sheet 35 of 96 US 2013/0080995 A1

813C NO varSubGry = ls srcReuseld empty. gueryBuilder(srcReuseld)

Yes varSubGry =

varSubQry = "(" + VarSubOry - ")" signed Yes NO 813i

Open recordset varFld Rod comprising th|OryFlc, where colGryld = srcQryld and COISrCld = SrCld, and Order is On ColCrd

SEOF Of YeS VarFCRCd True2 NO 813m VarFldAV = CheckAvailablity (coluseCnd) ey

FIG. 8D Patent Application Publication Mar. 28, 2013 Sheet 36 of 96 US 2013/0080995 A1

NO ls VarFlcAV True?

Yes varFReuCnt = 0

varColXpr = colXpr varColAla = ColAla

NO If COReuse is True?

YeS mMinche NO Yes

DOes NO tknMonth exist in varColXpr?

Yes

DOes tkin Month have

varColXpr= argTrue arguments?

NO

FIG. 8E Patent Application Publication Mar. 28, 2013 Sheet 37 of 96 US 2013/0080995 A1

DOes tknMOnth exist in Replace tknMonth with" in VarCOAla? varColAla

FIG. 8F Patent Application Publication Mar. 28, 2013 Sheet 38 of 96 US 2013/0080995 A1

YeS VarFeuCnt = 0 varCurMth = prmBegMth NO TT

DOes tknMOnth exist in NO varColXpr?

Yes

DOes Replace thcnMonth in tkin Month have varColxpr with arguments? varMthary(varCurMth) Yes varColxpr = "F("+ argComp ls prmOraQry True? + "=" + varCurMth -- "," + argTrue + "," + arg False +")" Yes varColXpr="DECODE(" + argComp + "," + varCurMth + "," + argTrue + "," + argFalse +")"

DOes tknMOnth exist in Yes Replace tknMonth in varColAla varColAla? with varMthary(varCurMth)

NO

FIG. 8G Patent Application Publication Mar. 28, 2013 Sheet 39 of 96 US 2013/0080995 A1

ls varColXprempty? No n var:Space.y " With

Yes varColXpr= varCurAla + "." + varColAla

ls dryGrp True? NO GB)

Yes

Yes

varGrpLis = varGrpLis +", " + ls varGrpLis empty. WarCurAla + "." + varCOIAla

Yes varGrpLis = varCurAla + "." + varColAla

varColXpr= varColxpr + "AS" + varColAla ey

FIG. 8H Patent Application Publication Mar. 28, 2013 Sheet 40 of 96 US 2013/0080995 A1 ey

No

Yes

Yes -5gnincolod- NO

N O Yes Move to next record of (C) VarFORCC

VarFeuCnt = varFeucht + 1

Yes VarFeuCnt = prm MthCn (C) NO varCurMth = varCurMth + 1

Yes varCurMth = 1

NO

FIG. 8 Patent Application Publication Mar. 28, 2013 Sheet 41 of 96 US 2013/0080995 A1

ls srcReuseld empty? varUniGry = varSubQry

Yes varUniGry = srcid

VarWrkUni - VarWrkUni ls varWrkUniempty? "UNIONALL" + varUniQry Yes

VarWrkUni = varUniQry

FIG. 8 Patent Application Publication Mar. 28, 2013 Sheet 42 of 96 US 2013/0080995 A1

NO ls prmCraCry True?

YeS No varWrkQry = ls srcReuseld empty.2 varSubQry + "" + varCurAla Yes varWrkQry = SrCld + " " + varCurAla

ls varJoiSrc emprty? Yes varJoiSrc = varWrkQry ey

NO YeS ls varOryStr empty? varCryStr = varWrkQry

NO varGryStr = varOryStr +", " + varWrkQry

LOCate SrCJoinTOSrC in varTblAry and assign found index to VarTbildx

varJoiAla = varTblAry(varTbildx,2

FIG. 8K Patent Application Publication Mar. 28, 2013 Sheet 43 of 96 US 2013/0080995 A1

NO varLftOpr=" ls prmLftJoi True? varRgtOpr=" Yes varLftOpr = "(+)" varFgtOpr = "

varWrkQry = "(" + varCurAla + "." + SrCJoin Flc + varLftOpr +" = " + VaruOiAla -- "." - SrCUO in TOFld + varFRgtOpr +")"

ls varRelStrempty? varRelStr = varWrkQry

NO VarFReStr = varFReStr + "AND" + varWrkQry

FIG. 8L Patent Application Publication Mar. 28, 2013 Sheet 44 of 96 US 2013/0080995 A1

No varWrkOry = ls srcReuseld empty.t varSubQry + "" + varCurAla Yes varWrkQry = SrCld -- " " + varCurAla

Yes varJoiSrc = varWrkQry ls varJoiSrc emprty.t varCryStr = varWrkQry NO Yes ls prmLftJoi True? varJoiOpr=" LEFT JOIN."

NO

varJoiOpr="INNER JOIN."

varGryStr = "(" + varOryStr + varJoiOpr + varWrkQry + "ON"

Locate SrCJoinTOSrc in varTblAry and assign its found index to varTbildx

VarJOiAla = varTblAry(varTbildx,2

FIG. 8M Patent Application Publication Mar. 28, 2013 Sheet 45 of 96 US 2013/0080995 A1

varWrkQry = "(" + varCurAla + "." + SrCJoin Fld + " = " + varJoiAla + "." + srcJoinToFld +")"

varGryStr = varGryStr + varWrkQry +")"

FIG. 8N Patent Application Publication Mar. 28, 2013 Sheet 46 of 96 US 2013/0080995 A1

varCryStr = ls varOryStr empty? varJoiSrc +", " + varOryStr Yes varOryStr = varJoiSrc

WarCrmbWhr = WhereClause(varCrmbWhr, dryWhr)

VarFelStr = WhereClause(var RelStr, varCmbWhr)

NO VarFReStr = ls varrelStr empty? "WHERE" + VarFReStr YeS varFetGry = "SELECT" + WarFOLiS - "FROM" + varCryStr + VarFReStr

FIG. 8O Patent Application Publication Mar. 28, 2013 Sheet 47 of 96 US 2013/0080995 A1

Yes varFetOry = varWrkUni

NO Yes ls prmOraQry True?

No WarCrmbWhr = WhereClause(varCrmbWhr, dryWhr)

NO VarCrmbWhr = ls varCmbWhr empty.2 "WHERE" + varCnbWhr "" Yes varRetOry = "SELECT" + VarFIdLiS - "FROM " + varOryStr + varCmbWhr

Yes ls varGrpLis empty?

NO varFetGry = varFetOry + "GROUP BY " + varGrpLis

varCaCnt = varCalCnt - 1

Return varretQry

FIG. 8P Patent Application Publication Mar. 28, 2013 Sheet 48 of 96 US 2013/0080995 A1

826a CheckAvailability(prmCndTkn)

Yes

NO 826C Store contents of prm UseCnd as an array in varCndPrm

DOes NO VarCnd Prm Contain Return False any item? YeS Assign lower bound of WarCrnd Prm to VarPrmCnt

varCnd Prm (varPrmCnt) exist in prmCndTkn?

VarPrm Cnt = VarPrm Cnt - 1

S varPrmCnt > upper bound of VarCnd Prm2

YeS

Return False

FIG. 8Q Patent Application Publication Mar. 28, 2013 Sheet 49 of 96 US 2013/0080995 A1

827a New Alias ()

varAlaStr =

varAlaCnt = varAlaCnt + 1

VarWrkCnt = varAlaCnt

827e varCurChr = VarWrkCnt MOD 26

VarWrkCnt = NT((varWrkCnt - 1) / 26

-5 acrocod- Yes VarCurChr = 26 NO

varAlastr = CHR( 96 + varCurChr) + varAlaStr

-5 wood NO 827k Return varAlaStr

FIG. 8R Patent Application Publication Mar. 28, 2013 Sheet 50 of 96 US 2013/0080995 A1

828a WhereClause(prmOrgWhr, prmNewWhr)

Yes is prmNewWhr empty? Return prmCrgWhr

828C

prmNewWhr = WhereToken (prmNewWhr

YeS ls prmOrgWhr empty? Return prmNewWhr

prmOrgWhr = prmOrgWhr +" AND (" + prmNewWhr+")"

Return prmorgWhr

FIG. 8S Patent Application Publication Mar. 28, 2013 Sheet 51 of 96 US 2013/0080995 A1

829a Where Token (prm RawWhr)

varProWhr = prm RawWhr

Find last location of "" in varProWhr and assign it to varBeg LOC

Find first location of "}" in varProWhr after (varEegLoc + 1) and assign it to varEnd Loc

Yes varBegLoc = 0 Return VarPrCWhr NO

VarEndLOC = 0 NO

S character Yes at (varEndLoc + 1) varDel Req = True "y"?

NO varDel Req = False

FIG. 8T Patent Application Publication Mar. 28, 2013 Sheet 52 of 96 US 2013/0080995 A1

Assign to varCurTKn, substring starting at varBegloc and ending at varEndLoc, from VarPrCWhr

Assign to varTknDta, substring from varCurTkn, except for the first and the last character of varCurTKn 83Od Store parameter value Corresponding to data token specified by varTknDta in VarFResult

Yes ls varresult empty?

NO ASSign (varBegLOC - 1) Characters from left side of War PrCWhr to WarftStr

Assign to warrgtStr, substring starting at varBegloc to the end, from varProWhr

Find first WarCurTkn in varFRgtStrand replace it with VarFReSult

VarPrCWhr - varLftStr + varFgtStr

FIG. 8U Patent Application Publication Mar. 28, 2013 Sheet 53 of 96 US 2013/0080995 A1

ls varDelRed True?

Yes

Find last location of "" in varProWhr and assign it to varBegLoc

varBegLoc = 0

NO Assign (varBeg Loc - 1) Characters from left Side of VarPrCWhr to VarLftStr

Assign to VarrgtStr, Substring starting at varBegloc till the end, from varProWhr

Find first "{" in varRgtStrand replace it with ""

VarPrCWhr varLftStr + varFRgtStr

Find first location of "}" in varProWhr starting from (varBegLoc + 1) character and assion it to varEndLOC

FIG. 8V Patent Application Publication Mar. 28, 2013 Sheet 54 of 96 US 2013/0080995 A1

Assign (varEndLoc - 1) Characters from left side of WarrCWhr to VarLftStr

Assign to varrgtStr, Substring starting at varEndLoc till the end, from varProWhr

Find first"}" in varrgtStrand replace it with ""

VarPrCWhr = varLftStr + varRgtStr

FIG. 8W Patent Application Publication Mar. 28, 2013 Sheet 55 of 96 US 2013/0080995 A1

ls varDel Red True?

Yes

Find last location of "" in varProWhr starting from (varBegLOC - 1) and assign it to varBed Loc

VarEndLOC = varEndLOC + 1

Assign (varBegLOC - 1) Characters from left side Of VarPrCWhr to WarftStr

Assign to varrgtStr, substring starting at varBeg Loc till the end, from varProWhr

Replace first (varEndLoc varBegLoc + 1) characters in varFgtStr with "1 = 1"

VarPrCWhr = varLftStr + varFgtStr

FIG. 8X Patent Application Publication Mar. 28, 2013 Sheet 56 of 96 US 2013/0080995 A1

|06

Patent Application Publication Mar. 28, 2013 Sheet 57 of 96 US 2013/0080995 A1

øsnæHIoolun-Idaeoloo

loe-- FTG ?unÃub puO3snous 357

"ill - - - - Patent Application Publication Mar. 28, 2013 Sheet 58 of 96 US 2013/0080995 A1 Patent Application Publication Mar. 28, 2013 Sheet 59 of 96 US 2013/0080995 A1

|06

Patent Application Publication Mar. 28, 2013 Sheet 60 of 96 US 2013/0080995 A1

OZO6 p206 9206

979/

Patent Application Publication Mar. 28, 2013 Sheet 61 of 96 US 2013/0080995 A1 C1806 0906 ?906 øsnæHIoolun-IduÐIoo enu|

906

J98/

|

?· ?· Patent Application Publication Mar. 28, 2013 Sheet 62 of 96 US 2013/0080995 A1

Patent Application Publication Mar. 28, 2013 Sheet 63 of 96 US 2013/0080995 A1 0906 [DG06 9906

EG06

Patent Application Publication Mar 28, 2013 Sheet 64 of 96 US 2013/0080995 A1

B906 O906 9906 9906

ouSoLu?opous 906 |•

Patent Application Publication Mar. 28, 2013 Sheet 65 of 96 US 2013/0080995 A1

[78/

|(28/

Patent Application Publication Mar. 28, 2013 Sheet 66 of 96 US 2013/0080995 A1 Patent Application Publication Mar. 28, 2013 Sheet 67 of 96 US 2013/0080995 A1

Patent Application Publication Mar. 28, 2013 Sheet 68 of 96 US 2013/0080995 A1

Patent Application Publication Mar. 28, 2013 Sheet 69 of 96 US 2013/0080995 A1

3906

557

U98/

udXIoo

557 5777||?77Õ?7 plOIOOplousloo|p?ÁuÐIoo |||~~~ Patent Application Publication Mar. 28, 2013 Sheet 70 of 96 US 2013/0080995 A1

| | O ||| O O

O O k 8/06 (D

k fe

/06

O99/

0||

Patent Application Publication Mar. 28, 2013 Sheet 71 of 96 US 2013/0080995 A1

Parameter Parameter Value ormOrvld OrmMthCnt Ormed Mith OrmCraGr OrmftJoi OrmuseCnd Ormitm3eC Ormtmnd Resultant query SELECT a.itemCOde AS itemCOde, a.item Name AS itemName, a brandCode AS brandCode, a.originCode AS originCode, b.brand.Name AS brand Name, c.originName AS originName FROM (tblitems a INNER JOIN th|Brands b ON (b.brandCode = a brandCode)) INNER JOIN thIOrigins CON (c.originCode = a.originCode)) 1012a

FIG. 10A Patent Application Publication Mar. 28, 2013 Sheet 72 of 96 US 2013/0080995 A1

Parameter Parameter Value OrmCrVld OrVA OrmMthCnt ormEed Mth OrmoraOr OrmftJoi OrmuseCnd Ormitm3ed Ormtmnd Resultant query SELECT a.itemCode AS item Code, a.item Name AS itemName, a.brandCode AS brandCode, a.originCode AS originCode, b. brand Name AS brand Name, c.originName AS originName FROMtblitems a, th|Brands b, th|Origins c WHERE (b.brandCode = a.brandCode) AND (C.OriginCode = a.originCode) 1 O12b

FIG. 10B Patent Application Publication Mar. 28, 2013 Sheet 73 of 96 US 2013/0080995 A1

Parameter Parameter Value OrmCrVld 612 larva OrmMthCnt 614 OrmeCMth 616 ormOraQr 618 True OrmftJoi 620 True OrmuseCnd 622 Ormitm3eC 624 Ormtmnd 626 Resultant query SELECT a.itemCOce AS itemCOce, a.itemName AS itemName, a brandCOce AS brandCode, a.originCode AS originCode, b. brandName AS brand Name, C.OriginName AS originName FROMtblitems a, th|Brands b, thiOrigins c WHERE (b.brandCode(+) = a.brandCode) AND (c.originCode(+) = a.originCode) 1 O12C

FIG. 10C Patent Application Publication Mar. 28, 2013 Sheet 74 of 96 US 2013/0080995 A1

Parameter Parameter Value OrmCRrvld 6 1 2 OrmMthCnt 61 4. ormEed Mth OrmCraGr OrmftJoi 211 O86 orm UseCnd 6 2 2 Ormitm3eC 6 2 4. Ormtmnd 6 2 6 Resultant query SELECT a.itemCode AS item Code, a. item Name AS itemName, a.brandCode AS brandCode, a.originCode AS originCode, b.brand.Name AS brand Name, c.originName AS originName FROM (tblitems a LEFT JOIN th|Brands b ON (b.brandCode=a.brandCode)) LEFT JOINtblOrigins c ON (c.originCode = a.originCode)) 1 O12d

FIG. 1 OD Patent Application Publication Mar. 28, 2013 Sheet 75 of 96 US 2013/0080995 A1

OrmftJoi 2O OrmuseCnd 22 TknZon.TKnPur,TknSal Ormitm3eC 24 Ormtmnd 26 Resultant query SELECT a.itemCode AS item Code, a.ZOneCode AS ZOneCode, a.Amount AS Pur, OAS Sal FROM th|Purchases a 1 O12e

FIG. 1 OE Patent Application Publication Mar. 28, 2013 Sheet 76 of 96 US 2013/0080995 A1

Parameter Parameter Value OrmCrVld OrmMthCnt OrmeCMth OrmCraGr OrmftJOi OrmuseCnd Ormitm3eC Ormtmnd Resultant query SELECT a.itemCode AS item Code, a.Amount AS Pur FROMtblPurchases a

FIG. 1 OF Patent Application Publication Mar. 28, 2013 Sheet 77 of 96 US 2013/0080995 A1

Parameter OrmCrVld 612 OrmMthCnt 614 OrmeOMth 616 OrmCraOr 618 OrmlftJoi 62O OrmuseCnd 622 OrmitmeC 624 Ormtmnd 626 Resultant query SELECT a.itemCode AS itemCode, a.Amount AS Pur FROMtblPurchases a 1012g

FIG. 1 OG Patent Application Publication Mar. 28, 2013 Sheet 78 of 96 US 2013/0080995 A1

Parameter Parameter Value OrWFinal

Ormed Mith 616 OrmCraGr 618 OrmLftJoi orm UseCnd Ormitm3eC 666 4.2O OrmitmEnd 6 2 6 Resultant query SELECT a.itemCode AS itemCode, a.itemName AS item Name FROMtbitems a 1012h

FIG. 1 OH Patent Application Publication Mar. 28, 2013 Sheet 79 of 96 US 2013/0080995 A1

Parameter Parameter Value OrWFinal

OrmCraOr 618 OrmftJoi 62O

OrmuseCnd TK n B r n pmunBegOrmitm3ed 624266 Ormtmnd 6 2 6 Resultant query SELECT a.itemCOce AS itemCOce, a.itemName AS itemName, a brandCOce AS brandCode, b. brand Name AS brandName FROM (tblitems a INNER JOIN tblBrands b ON (b.brandCode = a brandCode)) 1012

FIG. 10 Patent Application Publication Mar. 28, 2013 Sheet 80 of 96 US 2013/0080995 A1

Parameter Parameter Value ormOrvld OrVFinal OrmMthCnt OrmseCMth Ormora.Or OrmLftJoi OrmuseCnd Ormitm3eC Ormtmnd Resultant query SELECT a.item Code AS itemCode, a.item Name AS itemName, a.brandCode AS brandCode, a.originCode AS originCode, b.brand Name AS brand Name, c.originName AS originName FROM (tblitems a INNER JOINtblBrands b ON (b.brandCode = a.brandCode)) INNER JOIN th|Origins c ON (c.originCode = a.originCode)) 1 O12

FIG. 10 Patent Application Publication Mar. 28, 2013 Sheet 81 of 96 US 2013/0080995 A1

Parameter Parameter Value Orm(rVld OrWFinal OrmNMthCnt OrmeCMth OrmoraOr OrmftJOi orm Use Cnd 22 TknBrn,TknOrg,TknZon.TknPur,TknSal Ormitm3eC Ormtmnd Resultant query SELECT a.item Code AS itemCode, a.itemName AS item Name, a.brandCode AS brandCode, a.originCode AS originCode, b. brand Name AS brand Name, c.originName AS originName, d. ZoneCode AS zoneCode, d.TotPur AS TotPur, d.TotSal AS TotSal, hizOneName AS zoneName FROM ((((tblitems a INNER JOIN tblBrands b ON (b.brandCode=a.brandCode)) INNER JOINtblOrigins CON (c.originCode = a.originCode)) INNER JOIN (SELECT e.itemCode AS itemCode, e.ZoneCode AS ZoneCode, SUM(Pur) AS TotPur, SUM(Sal) AS TotSal FROM (SELECT fitemCode AS itemCode, fizOneCode AS zoneCode, O AS Pur, f. Amount AS Sal FROMtb|Sales f UNIONALL SELECT gitemCode AS itemCode, g.zoneCode AS zoneCode, g.Amount AS Pur, OAS Sal FROM tblPurchases g) e GROUP BYe.itemCode, e.ZoneCode) d ON (d. itemCode = a.itemCode)) INNER JOIN thZones h ON (h.ZoneCode = d.ZoneCode))

FIG. 10K Patent Application Publication Mar. 28, 2013 Sheet 82 of 96 US 2013/0080995 A1

Parameter Parameter Value Orm(Rryd OrWFinal OrmNMthCnt Ormed Mith OrmCraGr OrmftJoi orm UseCnd 22 TknPur.TknSal Ormitm3eC Ormtmnd Resultant query SELECT a.itemCode AS itemCode, a.item Name AS itemName, b. TotPur AS TotPur, b.TotSal AS TotSal FROM (tblitems a INNER JOIN (SELECT citemCode AS itemCode, SUM(Pur) AS TotPur, SUM(Sal) AS TotSal FROM (SELECT d.item Code AS itemCode, OAS Pur, d. Amount AS Sal FROM th|Sales d UNION ALL SELECT e.itemCode AS itemCode, e.Amount AS Pur, OAS Sal FROM tb|Purchases e) c GROUP BY citemCode) b ON (b.itemCode = a itemCode))

1 O12

FIG. 1 OL Patent Application Publication Mar. 28, 2013 Sheet 83 of 96 US 2013/0080995 A1

Parameter Value OrVFinal 12 Ormed Mth 616 1 OrmoraGr 618 orm LiftJoi orm UseCnd 22 TknPur,TknSal Ormitm3eC 4O Ormtmnd 6 2 6 Resultant query Illustrated in FiO. 1 ON

FIG. 1 OM Patent Application Publication Mar. 28, 2013 Sheet 84 of 96 US 2013/0080995 A1

SELECT a. itemCode AS itemCode, a.item Name AS itemName, b. TotJan Pur AS TotJan Pur, b. TotFebPur AS TotFebPur, b. TotMarPur AS TotMarPur, b. TotAprPur AS TotAprPur, b. TotMayPur AS TotMayPur, b. TotJun Pur AS TotJunPur, b. TotJulPur AS TotJulPur, b. TotAugPur AS TotAugPur, b. TotSepPur AS TotSepPur, b. TotOctPur AS TotOctPur, b. TotNowPur AS TotNowPur, b. TotDecPur AS TotDecPur, b. TotJanSal AS TotJanSal, b. TotFebSal AS TotFebSal, b. TotMarSal AS TotMarSal, b. TotAprSal AS TotAprSal, b. TotMaySal AS TotMaySal, b. TotJunSal AS TotJunSal, b. TotJulSal AS TotJulSal, b. TotAugSal AS TotAugSal, b. TotSepSal AS TotSepSal, b. TotOctSal AS TotOctSal, b. TotNovSal AS TotNovSal, b.TotDecSal AS TotDecSal FROM (tblitems a INNER JOIN (SELECT c.item Code AS itemCode, SUM(Jan Pur) AS TotJanPur, SUM(FebPur) AS TotFebPur, SUM(MarPur) AS TotMarPur, SUM(AprPur) AS TotAprPur, SUM(MayPur) AS TotMayPur, SUM (JunPur) AS TotJunPur, SUM(JulPur) AS TotJulPur, SUM (AugPur) AS TotAugPur, SUM(SepPur) AS TotSepPur, SUM(OctPur) AS TotOctPur, SUM (NovPur) AS TotNovPur, SUM(DecPur) AS TotDecPur, SUM(JanSal) AS TotJanSal, SUM(FebSal) AS TotFebSal, SUM(MarSal) AS TotMarSal, SUM(AprSal) AS TotAprSal, SUM(MaySal) AS TotMaySal, SUM(JunSal) AS TotJunSal, SUM (JulSal) AS TotJulSal, SUM (AugSal) AS TotAugSal, SUM(SepSal) AS TotSepSal, SUM(OctSal) AS TotOctSal, SUM(NovSal) AS TotNovSal, SUM(DecSal) AS TotDecSal FROM (SELECT d.itemCode AS itemCode, O AS Jan Pur, OAS FebPur, OAS MarPur, OAS AprPur, OAS MayPur, OAS JunPur, O AS JulPur, OAS AugPur, OAS SepPur, OAS OctPur, OAS NovPur, OAS DecPur, IIF(d.saleMonth=1,.d. Amount,0) AS JanSal, IIF(d.saleMonth=2.d.Amount,0) AS FebSal, IIF(d.saleMonth=3,.d. Amount,0) AS MarSal, IIF(d.saleMonth=4.d. Amount,0) AS AprSal, IIF(d.saleMonth=5,d. Amount,0) AS MaySal, IIF(d.saleMonth=6,d. Amount,0) AS JunSal, IIF(d.saleMonth=7,d. Amount,0) ASJulSal, IIF(d.saleMonth=8.d. Amount,0) AS AugSal, IIF(d.saleMonth=9,d. Amount,0) AS SepSal, IIF(d.saleMonth=10,d. Amount,0) AS OctSal, IIF(d.saleMonth=11,d.Amount,0) AS NovSal, IIF(d.saleMonth=12,d. Amount,0) AS DecSal FROM thSales d UNIONALL SELECT e. item Code AS item.Code, |IF(e.purchaseMonth=1,.e.Amount,0) AS JanPur, IIF(e.purchaseMonth=2,e.Amount,0) AS FebPur, IIF(e.purchaseMonth=3,.e.Amount,0) AS MarPur, IIF(e.purchaseMonth=4,e.Amount,0) AS AprPur, IIF(e.purchaseMonth=5,e.Amount,0) AS MayPur, IIF(e.purchaseMonth=6.e.Amount,0) ASJunPur, IIF(e.purchaseMonth=7,e.Amount,0) ASJulPur, IIF(e.purchaseMonth=8,e.Amount,0) AS AugPur, IIF(e.purchaseMonth=9,e.Amount,0) AS SepPur, IIF(e.purchaseMonth=10,e.Amount,0) AS OctPur, IIF(e.purchaseMonth=11,e.Amount,0) AS NovPur, IIF(e.purchaseMonth=12,e.Amount,0) AS DecPur, OAS JanSal, OAS FebSal, OAS MarSal, O AS AprSal, O AS MaySal, OAS JunSal, O AS JulSal, O AS AugSal, OAS SepSal, O AS OctSal, O AS NovSal, OAS DecSal FROM th|Purchases e) c GROUP BY c.itemCode) b ON (b.itemCode = a itemCode)) 1012m

FIG. 1 ON Patent Application Publication Mar. 28, 2013 Sheet 85 of 96 US 2013/0080995 A1

Parameter Parameter Value OrmCrVld OrVFinal OrmN/thCnt 12 orm3ed Mth OrmCraGr orm LiftJoi OrmuseCnd 22 TknPur.TknSal Ormitm3ed Ormtmnd Resultant query Illustrated in Fid. 1 OP

FIG. 1 OO Patent Application Publication Mar. 28, 2013 Sheet 86 of 96 US 2013/0080995 A1

SELECT a.item Code AS itemCode, a.item Name AS item Name, b. TotJan Pur AS TotJanPur, b. TotFebPur AS TotFebPur, b. TotMarPur AS TotMarPur, b. TotAprPur AS TotAprPur, b. TotMay Pur AS TotMayPur, b.TotJunPur AS TotJunPur, b.TotJulPur AS Tot JulPur, b. TotAugPur AS TotAugPur, b. TotSepPur AS TotSepPur, b. TotOctPur AS TotOctPur, b. TotNovPur AS TotNovPur, b. TotDecPur AS TotDecPur, b. TotJanSal AS TotJanSal, b. TotFebSal AS TotFebSal, b.TotMarSal AS TotMarSal, b.TotAprSal AS TotAprSal, b.TotMaySal AS TotMaySal, b. TotJunSal AS TotJunSal, b.TotJulSal AS TotJulSal, b. TotAugSal AS TotAugSal, b. TotSepSal AS TotSepSal, b. TotOctSal AS TotOctSal, b.TotNovSal AS TotNovSal, b. TotDecSal AS TotDecSal FROM th|tems a, (SELECT citemCode AS itemCode, SUM (Jan Pur) AS TotJanPur, SUM (FebPur) AS TotFebPur, SUM(MarPur) AS TotMarPur, SUM(AprPur) AS TotAprPur, SUM(MayPur) AS TotMayPur, SUM (Jun Pur) AS TotJunPur, SUM (JulPur) AS TotJulPur, SUM (AugPur) AS TotAugPur, SUM(SepPur) AS TotSepPur, SUM(OctPur) AS TotOctPur, SUM(NovPur) AS TotNovPur, SUM(DecPur) AS TotDecPur, SUM (JanSal) AS TotJanSal, SUM(FebSal) AS TotFebSal, SUM(MarSal) AS TotMarSal, SUM(AprSal) AS TotAprSal, SUM(MaySal) AS TotMaySal, SUM (JunSal) AS TotJunSal, SUM(JulSal) AS TotJulSal, SUM(AugSal) AS TotAugSal, SUM(SepSal) AS TotSepSal, SUM(OctSal) AS TotOctSal, SUM(NovSal) AS TotNovSal, SUM(DecSal) AS TotDecSal FROM (SELECT d.itemCode AS itemCode, OAS Jan Pur, OAS FebPur, OAS MarPur, OAS AprPur, OAS May Pur, OAS JunPur, OAS JulPur, OAS AugPur, OAS SepPur, OAS OctPur, OAS NovPur, OAS DecPur, DECODE(d.saleMonth, 1.d. Amount,0) AS JanSal, DECODE(d.saleMonth,2,d.Amount,0) AS FebSal, DECODE(d.saleMonth,3,d.Amount,0) AS MarSal, DECODE(d.saleMonth,4,d. Amount,0) AS AprSal, DECODE(d.saleMonth,5,d. Amount,0) AS MaySal, DECODE(d.saleMonth,6,d. Amount,0) AS JunSal, DECODE(d.saleMonth,7,d. Amount,0) AS JulSal, DECODE(d.saleMonth,8,d.Amount,0) AS AugSal, DECODE(d.saleMonth,9.d.Amount,0) AS SepSal, DECODE(d.saleMonth, 10,0.Amount,0) AS OctSal, DECODE(d.saleMonth, 11,d. Amount,0) AS NovSal, DECODE(d.saleMonth, 12,0.Amount,0) AS DecSal FROM thisales d UNION ALL SELECT e.itemCode AS itemCode, DECODE(e.purchaseMonth, 1.e.Amount,0) AS Jan Pur, DECODE(e.purchaseMonth,2,e.Amount,0) AS FebPur, DECODE(e.purchaseMonth,3,e.Amount,0) AS MarPur, DECODE(e.purchaseMonth,4,e.Amount,0) AS AprPur, DECODE(e.purchaseMonth,5, e.Amount,0) AS MayPur, DECODE(e.purchaseMonth,6,e.Amount,0) AS JunPur, DECODE(e.purchaseMonth,7,e.Amount,0) AS JulPur, DECODE(e.purchaseMonth,8,e.Amount,0) AS AugPur, DECODE(e.purchaseMonth,9,e.Amount,0) AS SepPur, DECODE(e.purchaseMonth, 10,e.Amount,0) AS OctPur, DECODE(e.purchaseMonth, 11.e.Amount,0) AS NovPur, DECODE(e.purchaseMonth, 12,e.Amount,0) AS DecPur, OAS JanSal, OAS FebSal, O AS MarSal, OAS AprSal, OAS MaySal, OAS JunSal, OAS JulSal, OAS AugSal, OAS SepSal, OAS OctSal, O AS NovSal, OAS DecSal FROM th|Purchases e) c GROUP BY c.itemCode) b WHERE (b.itemCode=a.item Code) 1012O FIG. 1 OP Patent Application Publication Mar. 28, 2013 Sheet 87 of 96 US 2013/0080995 A1

Parameter Parameter Value OrmCrVld 612 orvModi OrmMthCnt 614

pmuseCnd 622 intm Ormitm3eC 624 Ormtmnd 626 Resultant query SELECT a.itemCode AS itemCode, a.itemName AS itemName FROM (SELECT b.itemCode AS itemCode, b.itemName AS itemName FROM thiitems b) a WHERE (1 = 1) AND (1 = 1) GROUP BYaitemCode, a.itemName 1012Q

FIG. 1 OG Patent Application Publication Mar. 28, 2013 Sheet 88 of 96 US 2013/0080995 A1

Parameter Parameter Value OrmChryid OrmMthCnt Ormed Mith OrmCraGr OrmlftJoi OrmuseCnd Ormitm3eC Ormtmnd Resultant query SELECT a.itemCOde AS itemCode, a.itemName AS itemName FROM (SELECT b.itemCode AS itemCode, b.itemName AS itemName FROM thiitems b) a WHERE (itemCode a="001") AND (itemCode <='009') GROUP BY a.itemCOce, a.itemName

FIG. 10R Patent Application Publication Mar. 28, 2013 Sheet 89 of 96 US 2013/0080995 A1

Parameter Parameter Value ormOrvld OrmN/thCnt OrmeCMth Ormora.Or OrmftJoi OrmuseCnd 22 TknBrn,TknPur,TknSal Ormitm3eO Ormtmnd Resultant query SELECT a brandCOce AS brandCOce, a.brand Name AS brand Name, SUM(a.TotPur) AS TotPur, SUM(a.TotSal) AS TotSal FROM (SELECT b.itemCOde AS item Code, b.itemName AS itemName, b. brandCOce AS brandCode, C.brand Name AS brand Name, d.TotPur AS TotPur, d.TotSal AS TotSal FROM (tblitems b INNER JOINtb|Brands CON (c.brandCode = b.brandCode)) INNER JOIN (SELECT e.itemCode AS itemCode, SUM(Pur) AS TotPur, SUM(Sal) AS TotSal FROM (SELECT fitemCode AS itemCode, OAS Pur, f. Amount AS Sal FROMtb|Sales f UNIONALL SELECT gitemCode AS itemCode, g.Amount AS Pur, OAS Sal FROM th|Purchases g) e GROUP BY e.itemCode) d ON (d. itemCode = b.itemCode))) a WHERE (1 = 1) AND (1 = 1) GROUP BYa.brand COde, a.brand Name

FIG. 1 OS Patent Application Publication Mar. 28, 2013 Sheet 90 of 96 US 2013/0080995 A1

Parameter Parameter Value ormOrwid 6 layMody pmMinchOrmMthCnt G14 pmBegMihormEed Mth 616 OrmCraGr pmOrmftJoi to 620 OrmuseCnd 6 22 TknBntinPuTinsalTknBrn,TknPur, TKnSal Ormitm3eC se6 4 Ormtmnd 6 2 6 Resultant query SELECT a.brandCOce AS brandCode, a.brand Name AS brand Name, SUM(a.TotPur) AS TotPur, SUM(a.TotSal) AS TotSal FROM (SELECT b.itemCOce AS itemCOce, b.item Name AS itemName, b.brandCOce AS brandCode, C.brand Name AS brand Name, d.TotPur AS TotPur, d.TotSal AS TotSal FROM thlitems b, th|Brands C, (SELECT e.itemCode AS itemCode, SUM(Pur) AS TotPur, SUM(Sal) AS TotSal FROM (SELECT fitemCode AS itemCode, O AS Pur, f.Amount AS Sal FROM th|Sales f UNIONALL SELECT g.itemCode AS itemCode, g.Amount AS Pur, OAS Sal FROM th|Purchases g) e GROUP BYe.itemCode) d WHERE (c.brandCode = b.brandCode) AND (d.itemCode = bitemCode)) a WHERE (1 = 1) AND (1 = 1) GROUP BY a.brandCode, a.brand Name

FIG. 10T Patent Application Publication Mar. 28, 2013 Sheet 91 of 96 US 2013/0080995 A1

Parameter Value OrmCrVld 612 OrmNMthCnt 14 OrmseCMth 61

Ormtmnd 62 Resultant query SELECT a.brandCode AS brandCOce, a brand Name AS brand Name, SUM(a.TotPur) AS TotPur, SUM(a.TotSal) AS TotSal FROM (SELECT b.itemCOce AS itemCOce, b.item Name AS itemName, b. brandCOce AS brandCOce, C. brand Name AS brandName, d.TotPur AS TotPur, d.TotSal AS TotSal FROMtblitems b, th|Brands C, (SELECT e.itemCode AS itemCode, SUM(Pur) AS TotPur, SUM(Sal) AS TotSal FROM (SELECT fitemCode AS item Code, OAS Pur, f.Amount AS Sal FROM to Sales f UNIONALL SELECT g.itemCode AS itemCode, g.Amount AS Pur, OAS Sal FROM thIPurchases g) e GROUP BYe.itemCode) d WHERE (c.brandCode(+) = b.brandCode) AND (d.itemCode(+) = b.itemCode)) a WHERE (1 = 1) AND (1 = 1) GROUP BY a.brandCOce, a.brand Name 1012U

FIG. 1 OU Patent Application Publication Mar. 28, 2013 Sheet 92 of 96 US 2013/0080995 A1

Parameter Parameter Value OrmCrVld 612 larvModi OrmMthCnt 614 OrmeOMth OrmCraO H11 86 OrmftJoi 6 2 O : rr ee OrmuseCnd 622 Tknitm,TknBrn,TknOrg, TknZon.TknSal,TknPur Ormitm3eC 624 Ormtmnd 626 Resultant query SELECT a. itemCOde AS itemCOde, a.itemName AS item Name, a.brandCode AS brandCode, a.originCode AS originCode, a.brand Name AS brand Name, a.originName AS originName, a.ZoneCode AS ZoneCode, SUM(a.TotPur) AS TotPur, SUM(a.TotSal) AS TotSal, a zoneName AS zoneName FROM (SELECT b.itemCOde AS itemCode, b.itemName AS itemName, b. brandCode AS brandCode, b.originCode AS originCode, C.brand Name AS brand Name, d.originName AS originName, e.ZoneCode AS ZoneCode, e.TotPur AS TotPur, e.TotSal AS TotSal, i.ZOneName AS zoneName FROM thlitems b, thirands C, tblOrigins d, (SELECT fitemCode AS itemCode, fizOneCode AS zoneCode, SUM (Pur) AS TotPur, SUM(Sal) AS TotSal FROM (SELECT gitemCode AS item.Code, g.zoneCode AS zoneCode, OAS Pur, g.Amount AS Sal FROM tblSales g UNIONALL SELECT hitemCode AS itemCode, h.zoneCode AS zoneCode, h.Amount AS Pur, OAS Sal FROM thIPurchases h) f GROUP BY fitemCode, fizOneCode) e, thZones i WHERE (c.brandCode(+) = b.brandCode) AND (d.originCode(+) = b.originCode) AND (e.itemCode(+) = b.itemCode) AND (i.ZoneCode (+) = e.ZoneCode)) a WHERE (1 = 1) AND (1 = 1) GROUP BY a.itemCode, a.itemName, a.brandCode, a.originCode, a.brand Name, a.originName, a.ZoneCode, a.zoneName

FIG. 1 OV Patent Application Publication Mar. 28, 2013 Sheet 93 of 96 US 2013/0080995 A1

Parameter Parameter Value ormOrwid OrmMthCnt OrmseOMth ormCraGr OrmftJoi OrmuseCnd 22 Tknitm,TknBrn,Tknorg,TknZon.TknSalTknPur Ormitm3eC 'OO1" Ormtmnd 26 'OO4' Resultant query Illustrated in Fid. 1 OX

FIG. 1 OW Patent Application Publication Mar. 28, 2013 Sheet 94 of 96 US 2013/0080995 A1

SELECT a.itemCOce AS itemCode, a. item Name AS item Name, a brandCode AS brandCode, a.originCode AS originCode, a.brand.Name AS brand Name, a.originName AS originName, a.zoneCode AS zoneCode, SUM (a.TotNovPur) AS TotNovPur, SUM(a.TotDecPur) AS TotDecPur, SUM(a.TotJan Pur) AS TotJan Pur, SUM(a.TotFebPur) AS TotFebPur, SUM(a.TotMarPur) AS TotMarPur, SUM(a.TotNovSal) AS TotNovSal, SUM(a.TotDecSal) AS TotDecSal, SUM(a.TotJanSal) AS TotJanSal, SUM(a.TotFebSal) AS TotFebSal, SUM(a.TotMarSal) AS TotMarSal, a.zoneName AS zoneName FROM (SELECT b.item Code AS item Code, b.item Name AS item Name, b. brandCode AS brandCode, b.originCode AS originCode, c.brandName AS brand Name, d.originName AS originName, e.zoneCode AS zoneCode, e.TotNovPur AS TotNovPur, e.TotDecPur AS TotDecPur, e.TotJan Pur AS Tot, JanPur, e.TotFebPur AS TotFebPur, e.TotMarPur AS TotMarPur, e.TotNowSal AS TotNowSal, e.TotDecSal AS TotDecSal, e.TotJanSa AS TotJanSal, e.TotFebSal AS TotFebSal, e.TotMarSal AS TotMarSal, i.ZOneName AS zoneName FROM thlitems b, thlBrands c, th|Origins d, (SELECT f.itemCode AS itemCode, f. ZoneCode AS zoneCode, SUM(NovPur) AS TotNovPur, SUM(DecPur) AS TotDecPur, SUM(Jan Pur) AS TotJanPur, SUM(FebPur) AS TotFebPur, SUM(MarPur) AS TotMarPur, SUM (NovSal) AS TotNovSal, SUM(DecSal) AS TotDecSal, SUM (JanSal) AS TotJanSal, SUM (FebSal) AS TotFebSal, SUM(MarSal) AS TotMarSal FROM (SELECT g. item.Code AS itemCode, g.zoneCode AS zoneCode, O AS NovPur, OAS DecPur, OAS JanPur, OAS FebPur, OAS MarPur, DECODE(g.saleMonth, 11.g.Amount,0) AS NovSal, DECODE(g.saleMonth, 12.g.Amount,0) AS DecSal, DECODE(g.saleMonth, 1.g.Amount,0) AS JanSal, DECODE(g.saleMonth,2,.g.Amount,0) AS FebSal, DECODE(g.saleMonth,3,.g.Amount,0) AS MarSal FROM thisales g UNION ALL SELECT h.itemCOce AS itemCode, h.ZOneCode AS ZoneCode, DECODE(h.purchaseMonth, 11,h.Amount,0) AS NovPur, DECODE(h.purchaseMonth, 12,h.Amount,0) AS DecPur, DECODE(h.purchaseMonth, 1.h. Amount,0) AS Jan Pur, DECODE(h.purchaseMonth,2,h.Amount,0) AS FebPur, DECODE(h.purchaseMonth,3,h.Amount,0) AS MarPur, O AS NovSal, OAS DecSal, O AS JanSal, OAS FebSal, O AS MarSal FROM th|Purchases h) f GROUP BY fitemCode, f.zoneCode) e, th|Zones i WHERE (c.brandCode(+) = b.brandCode) AND (d. originCode(+) = b.originCode) AND (e.itemCode(+) = b.itemCode) AND (i.ZoneCode(+) = e.zoneCode)) a WHERE ( itemCode a='001') AND (item Code <= '004") GROUP BY a.itemCode, a. itemName, a.brandCode, a.originCode, a.brand Name, a.origin Name, a.zoneCode, a.zoneName

FIG. 10X Patent Application Publication Mar. 28, 2013 Sheet 95 of 96 US 2013/0080995 A1

Parameter Parameter Value OrmCrVld laymodity OrmMthCnt OrmeCMth 1 OrmCraGr 1111 8642 OrmftJoi 6 2 O OrmuseCnd 22 TinimitinentinoatenzonTasaltknpurTknitm,TknBrn.TknOrg,TknZon.TknSal,TknPur pmimbegOrmitm3eC 6242 loor'OO1 Ormtmnd 6 2 6 loos'OO4' Resultant query Illustrated in Fig. 10Z

FIG. 1 OY Patent Application Publication Mar. 28, 2013 Sheet 96 of 96 US 2013/0080995 A1

SELECT a.item Code AS itemCode, a.item Name AS item Name, a brandCode AS brandCode, a.originCode AS originCode, a.brand.Name AS brand Name, a.originName AS originName, a.zoneCode AS zoneCode, SUM(a.TotNovPur) AS TotNovPur, SUM(a.TotDecPur) AS TotDecPur, SUM(a.TotJan Pur) AS TotJan Pur, SUM(a.TotFebPur) AS TotFebPur, SUM(a.TotMarPur) AS TotMarPur, SUM(a.TotNovSal) AS TotNovSal, SUM(a.TotDecSal) AS TotDecSal, SUM(a.TotJanSal) AS TotJanSal, SUM(a.TotFebSal) AS TotFebSal, SUM(a.TotMarSal) AS TotMarSal, a.zoneName AS zoneName FROM (SELECT b.item Code AS itemCode, b.item Name AS item Name, b. brandCode AS brandCode, b.originCode AS originCode, c.brandName AS brandName, d.originName AS origin Name, e.zoneCode AS zoneCode, e.TotNovPur AS TotNovPur, e.TotDecPur AS TotDecPur, e.TotJan Pur AS TotJan Pur, e.TotFebPur AS TotFebPur, e.TotMarPur AS TotMarPur, e.TotNovSal AS TotNowSal, e.TotDecSal AS TotDecSal, e.TotJanSal AS TotJanSal, e.TotFebSal AS TotFebSal, e.TotMarSal AS TotMarSal, i.ZOneName AS zoneName FROM ((((tbitems b INNER JOIN thlBrands CON (c.brandCode = b.brandCode)) INNER JOIN th|Origins d ON (d.originCode = b.originCode)) INNER JOIN (SELECT f.itemCode AS itemCode, f.zoneCode AS zoneCode, SUM(NovPur) AS TotNovPur, SUM(DecPur) AS TotDecPur, SUM (Jan Pur) AS TotJan Pur, SUM (FebPur) AS TotFebPur, SUM (MarPur) AS TotMarPur, SUM(NovSal) AS TotNovSal, SUM(DecSal) AS TotDecSal, SUM (JanSal) AS TotJanSal, SUM(FebSal) AS TotFebSal, SUM(MarSal) AS TotMarSal FROM (SELECT g. itemCode AS itemCode, gzoneCode AS zoneCode, O AS NovPur, OAS DecPur, OAS Jan Pur, OAS FebPur, 0 AS MarPur, IIF(g.saleMonth=11.g.Amount,0) AS NovSal, IIF(g.saleMonth=12.g.Amount,0) AS DecSal, IIF(g.saleMonth=1,.g.Amount,0) AS JanSal, IIF(g.saleMonth=2,9. Amount,0) AS FebSal, IIF(g.saleMonth=3,.g.Amount,0) AS MarSal FROM th|Sales g UNIONALL SELECT hitemCode AS itemCode, h.zoneCode AS zoneCode, IIF(h-purchaseMonth=11,h. Amount,0) AS NovPur, IIF(h.purchaseMonth=12,h. Amount,0) AS DecPur, IIF(h.purchaseMonth=1,h.Amount,0) AS JanPur, IIF(h.purchaseMonth=2,h. Amount,0) AS FebPur, IIF(h.purchaseMonth=3,h. Amount,0) AS MarPur, OAS NovSal, OAS DecSal, OAS JanSal, OAS FebSal, O AS MarSal FROM th|Purchases h) f GROUP BY f.item.Code, f.zoneCode) e ON (e.itemCode = b.itemCode)) INNER JOIN th|Zones iON (i.ZoneCode = e.zoneCode))) a WHERE ( itemCode a="001") AND (itemCode <= '004") GROUP BY a.itemCode, a. itemName, a.brandCode, a.originCode, a.brand.Name, a.origin Name, a.ZoneCode, a.ZOneName 1012y

FIG. OZ US 2013/0080995 A1 Mar. 28, 2013

METHOD AND AN APPARATUS FOR and are specifically designed for DEVELOPNG SOFTWARE ACCESS reporting engine and a letter size paper. In the prior art, each report, along with its required query, would have to BACKGROUND be developed by a software developer. This process may take 0001 1. Field tens of thousands of hours of a skilled computer . 0002. This invention relates to the field of software devel If the same reports are required to be ported to an ORACLE opment. platform and CRYSTAL REPORTS with report layouts foran 0003 2. Description of the Related Art A4 size paper, the resource expenditure might be even greater 0004 Software development includes development of than what was required for the original development. new software, maintenance of developed software, and qual 0010. The humongous and unmanageable resource ity assurance of developed software, wherein the mainte requirement for software development is not only related to nance includes a change and/or a modification in developed reports and queries, but also to every stage and aspect of Software, and wherein the quality assurance includes testing software development. However, despite the availability of so and/or debugging of developed software. many technologies, environments and applications, the prior 0005. In software development, one of the biggest impedi art has been unable to meet the challenge of minimizing the ments is the large, many times prohibitive, amount of required resources for Software development to a desired, and resources required for developing and maintaining even a an effective level. Small computer program. Moreover, the resources required 0011 Software development should, ideally, achieve three for software development increase exponentially in propor objectives simultaneously: maximizing features, ensuring tion to the number of features required in a computer pro highest quality, and minimizing software development gram. Also, the required resources can further grow astro resources. However, the prior art has failed to achieve all three nomically for computer programs that must exclude any objectives in conjunction; in every software development, chance of an error and/or a malfunctioning. one or more of these objectives have to be compromised. 0006. At the same time, the expectations and requirements from software are increasing rapidly because of the swiftly SUMMARY increasing processing power and capabilities of computers. 0012. The major challenge in the prior art, that of mini However, because of the limitations of available resources, mizing resources, (man, technology, money, and time) Such as, human resource, financial resource, time resource, required for software development, as well as in the mainte technical resource, and the like, the art is still unable to nance and quality assurance of developed software, has been develop, and utilize software to its full potential. effectively met by the embodiments of the present invention. 0007 To address the above serious impediment, various 0013. According to an embodiment of the present inven technologies have been developed over time, but none has tion, a new method for developing software is provided which been able to effectively solve this problem so far. Such tech empowers a machine (e.g. a computer) to function like a nologies include CASE tools, data driven programming, table human software developer. A data token is defined, created driven programming, object oriented programming, CORBA and associated with a source code to enable the machine (e.g. (Common Object Request Broker Architecture), MDA a computer) to perform software development (enable the (Model-Driven Architecture), RAD (Rapid Application machine to generate or construct further source code, object Development), software factories, and the like. All these tech code, and/or an object). nologies have reduced, to Some extent, the resource require 0014. According to another embodiment of the present ments for software development. These technologies have invention, a method is provided to streamline and simplify a also enabled, somewhat, efficient utilization of the resources Source code which is required to develop software. A source required for software development. Simultaneously, though, object is created and utilized as the source code by the ever-increasing complexities, as well as exponential rises in machine (e.g. a computer) to perform Software development. functional requirements from Software have meant that what 0015. According to another embodiment of the present ever benefits emanated from such technologies have not been invention, a method is provided for creating a source object enough to meet the growing demands from Software. repository to store a source object. The Source object reposi 0008. In addition to the above mentioned technologies, tory enables easy creation, manageability, and reusability of a many computer programs and development environments Source object. have been developed for reducing the resource requirement 0016. According to another embodiment of the invention, for the Software development process. Such computer pro a method is provided for associating a data token to a source grams and development environments include, but are not object in a manner that enables a computer to generate a limited to, MS-VISUAL STUDIO, GNAT PROGRAM complete source code by utilizing the source object and the MING STUDIO, IBM RATIONAL APPLICATION associated data token. DEVELOPER, POWERBUILDER, C++BUILDER, 0017 Embodiments of the present invention provide , NETBEANS, , , CRYSTAL numerous technical and commercial advantages. For REPORTS, MICROSOFT ACCESS, ORACLE DATA example, according to an embodiment of the present inven BASE, and MICROSOFTSQL SERVER. While these com tion, the time and resources required for Software develop puter programs and development environments have man ment are reduced Substantially. According to another embodi aged to automate a small number of mechanical tasks, they ment of the present invention, the available features and have not been effective in reducing the excessive resource options in developed software are increased substantially. requirements for Software development. 0018. The extraordinary benefits of applying the prin 0009 Consider, for instance, a computer application ciples of the present invention will change the way Software which is required to comprise a couple of hundred reports development is conceived and carried out. The inventive con which are desired to be based on MICROSOFT SQL Server cepts and principles will create endless new possibilities and US 2013/0080995 A1 Mar. 28, 2013

horizons—far beyond queries, reports, data entry forms, 0034 FIG. 7B illustrates an exemplary data model which menus, business processing rules, help systems, exception is sufficient for creating a source object repository, according handling systems, and the like—that are unknown and to an aspect of an embodiment of the invention. unthinkable in the prior art. 0035 FIG. 7C illustrates an exemplary source object 0019 Many more advantages will be readily apparent to repository which is created on the basis the exemplary data one who is skilled in the art. model, illustrated in FIG. 7B, according to an aspect of an embodiment of the invention. BRIEF DESCRIPTION OF THE DRAWINGS 0036 FIGS. 8A to 8P illustrate an exemplary flowchart of 0020. The concepts, principles, methods, specifications, an exemplary Software component constructor, called query embodiments and salient features of the invention are illus Builder in this document, according to an aspect of an trated by way of examples, and not by way of any limitation, embodiment of the invention. in the below listed figures along with their drawings and 0037 FIG. 8Q illustrates an exemplary flowchart of an detailed descriptions, wherein like reference numerals refer exemplary processing of an exemplary specific data token, to similar elements. according to an aspect of an embodiment of the invention. 0021 FIG. 1A illustrates a flowchart representing an 0038 FIG. 8R illustrates an exemplary flowchart of an aspect of an embodiment of the invention. exemplary processing of another exemplary specific data 0022 FIG. 1B illustrates a flowchart representing an token, according to an aspect of an embodiment of the inven aspect of an embodiment of the invention in more detail. tion. 0023 FIG. 2 illustrates a flowchart representing an exem 0039 FIG. 8S illustrates an exemplary flowchart of an plary construction of an exemplary Software component, exemplary function which is utilized by queryBuilder. according to an aspect of an embodiment of the invention. 0040 FIGS. 8T to 8X illustrate an exemplary flowchart of 0024 FIG. 3 is an exemplary illustration of a schematic the exemplary data token whose processing logic is illustrated diagram of a computing system environment inclusive of an in FIGS. 5B and 5C, according to an aspect of an embodiment exemplary computer and other exemplary components which of the invention. are Suitable for implementing an aspect of an embodiment of 004.1 FIGS. 9A to 90 illustrate a few exemplary source the invention. objects which are stored in the exemplary source object 0025 FIG. 4A illustrates two exemplary sets of predeter repository illustrated in FIG.7C, according to an aspect of an mined rules which are selected according to an aspect of an embodiment of the invention. embodiment of the invention. 0042 FIGS. 10A to 10Zillustrate a few exemplary queries 0026 FIGS. 4B to 4K illustrate an exemplary syntax dia which are constructed by queryBuilder by utilizing the few gram of a set of predetermined rules for ACCESS SELECT exemplary source objects illustrated in FIGS. 9A to 90. QUERY, selected according to an aspect of an embodiment of according to an aspect of an embodiment of the invention. the invention. 0027 FIGS. 4L to 4R illustrate an exemplary syntax dia DETAILED DESCRIPTIONAEMBODIMENTS gram of a set of predetermined rules for ORACLE SELECT QUERY, selected according to an aspect of an embodiment of 1. Definitions the invention. 0043. Some of the terms used herein are not commonly 0028 FIG. 4S illustrates an exemplary block diagram used in the art. The discussion of the present invention utilizes which shows a few source components, illustrated in FIGS. Some terms in a specific sense. Therefore, the following defi 4B to 4R, which are categorized as indeterminable source nitions are provided in order to ensure clarity, as well as to components according to an aspect of an embodiment of the facilitate the understanding of the detailed description that invention. follows. However, the invention, as set forth in the claims, 0029 FIG. 4T illustrates an exemplary block diagram should not necessarily be limited by these definitions. which shows a few source components, illustrated in FIGS. 0044. A "data value' is a unit of data which comprises a 4B to 4R, which are categorized as determinable source com piece of information and which requires at least one bit for a ponents according to an aspect of an embodiment of the representation in a computer readable recording medium. invention. Anything that can be stored in a computer readable recording 0030 FIG. 5A illustrates an exemplary block diagram medium is a data value. Examples of a data value may which shows a few exemplary data tokens which are defined include, but are not limited to, a name, an age, a date, a time, according to an aspect of an embodiment of the invention. a number, a text string, an object, an image, an audio, a video, 0031 FIGS. 5B and 5C illustrate an exemplary flowchart a signal, a formula, a source code, an object code, a variable which shows an exemplary set of data token rules of an name, a variable value, a field name, an alphanumeric char exemplary specific data token, according to an aspect of an acter, binary data, alphanumeric data, a bit, a short integer, a embodiment of the invention. long integer, a NULL value, and an empty value. 0032 FIG. 6 illustrates an exemplary block diagram 0045. A “software component 142 refers to a source code which shows exemplary parameters which are defined of a computer programming language, an object code of a according to an aspect of an embodiment of the invention. processor (real and/or virtual), and/or an object, which is at 0033 FIG. 7A illustrates an exemplary block diagram least one part of a software, wherein the one part of software which shows a few exemplary attributes (may be called col is utilized during execution of the software or a part thereof, umns or fields as well), for a data model, which are to be that is executed either by a processor or by another software included in source object repository to hold component val (computer program) in case of virtualization, wherein the ues for desired indeterminable source components out of all processor is either a real (physical) computer processor oran indeterminable source components illustrated in the FIG. 4S, emulator (virtual computer processor). A Software compo according to an aspect of an embodiment of the invention. nent comprises one or more source components which are put US 2013/0080995 A1 Mar. 28, 2013

together on the basis of “a set of predetermined rules.” 0.066 6. A tax rate is a source component of a tax cal wherein each of the one or more source components is rep culation business rule, which is a Software component. resented by at least one data value. A Software component The tax rate may be represented by a component value of may comprise one or more other Software components. a numeric data type. Examples of a Software component 142 may include, but are 0067 7. A mnemonic is a source component of a source not limited to: code block, which is a software component. ofanassem 0046 1. An SQL query is a software component. bly language. Component values which represent the 0047 2. A WHERE clause of an SQL query is a soft mnemonic may include, but are not limited to, MOV. ware component. XOR, and CMP. 3. A report layout is a software component. 0068 A “set of predetermined rules' 140 comprises one or 0048 more predetermined rules that are sufficient for constructing 0049 4. A software object created on a basis of a class a software component. A set of predetermined rules is speci model is a software component. fied in terms of one or more source components, wherein each 0050 5. A font object is a software component. of the one or more source components is represented by at 0051 6. A data structure is a software component. least one component value in a software component. 0.052 7. A database view is a software component. Examples of a set of predetermined rules 140 may include, 0053 8. A database table is a software component. but are not limited to: 0054) 9. A data entry form is a software component. 0069. 1. A set of predetermined rules for creating an 0055 10. A spreadsheet is a software component. SQL query, which is a Software component, according SQL:2008 standard. 0056. Examples of a software component 142 comprising 0070 2. A set of predetermined rules for creating an another software may include, but are not limited to: SQL query, which is a Software component, which cre 0057 1. An SQL query, which is a software component, ates a table in an ORACLE database. comprising a WHERE clause, which is also a software 0071 3. A set of predetermined rules for creating a component. form, which is a software component, in MICROSOFT 0.058 2. An SQL view, which is a software component, 6. comprising two SQL views, which are also software 0.072 4. A set of predetermined rules for creating a components. report layout, which is a software component, in CRYS 0059) 3. A report layout, which is a software compo TAL REPORTS, nent, comprising a font object, which is also a software 0.073 5. A set of predetermined rules for calculating the component. premium of a specific insurance policy in a Software 0060 A “source component 144 is represented by at least application, which is a Software component. one data value, hereinafter called component value 146, in a 0.074 6. A set of predetermined rules for creating a Software component 142. In other words, a source component formula, which is a software component, in an EXCEL 144 is just like a property of a Software object, whereas a worksheet. component value 142 is just like the value of the property of 0075 A“user is someone who develops, installs, utilizes, the software object. Examples of a source component 144 and/or configures a computer program. A user may include, may include, but are not limited to: but is not limited to, a human being, a machine, and a com 0061 1. Paper size is a source component of a report puter program. It is possible that a user is also a developer of layout, which is a software component. The paper size is the same computer program that the user utilizes. represented by at least one component value in a report 0076. A "data token 152 comprises a set of data token layout. Component values which represent a paper size rules 158 and is represented by a data value, hereinafter called in a report layout may include, but are not limited to, A4. token value 154, wherein the token value is processed on the A3, Letter, and 8.5'x11". basis of the set of data token rules, and then the result of the processed token value, which is also a data value, hereinafter 0062. 2. Background color is a source component of a called token result 156, is utilized for constructing a software data entry form, which is a Software component. The component. The set of data token rules is specified at the time background color may be represented by one or more of defining a data token, wherein the set of data token rules component values in a data entry form object. comprises one or more rules which specify one or more 0063. 3. Inan SQL query, which is software component, manners in which a token value can be associated with a a command is a source component. Component values component value of a source component of a software com which represent the command in an SQL query may ponent, can be processed, and/or can be utilized. The process include, but are not limited to, SELECT UPDATE, ing of a token value may include, but is not limited to, execut DELETE, INSERT INTO, CREATE DATABASE, ing a function, performing a comparison, creating a ALTER DATABASE, and the like. component value, determining a manner in which a software 0064. 4. A whitespace is a source component of a source component is constructed, identifying one or more compo code block, which is a Software component, of a com nent values for utilizing in a software component, or any puter programming language. Component values which combinations thereof. A token value may be determined by represent the whitespace may include, but are not lim utilizing a parameter. A token value can also be associated ited to, a space character, and a tab character. with another token value. A token value can be nested in 0065 5. The width of a textbox is a source component of another token value of the same and/or a different data token. a textbox object, which is a software component. The 0077. Following are a few examples of a data token 152: width of a textbox may be represented by a component 0078 1. thanCompare is a data token 152 which is rep value of a numeric data type. resented by a token value Comp(A,B). When Comp(A,