tripal_core.schema_v1.2.api.inc 344 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911491249134914491549164917491849194920492149224923492449254926492749284929493049314932493349344935493649374938493949404941494249434944494549464947494849494950495149524953495449554956495749584959496049614962496349644965496649674968496949704971497249734974497549764977497849794980498149824983498449854986498749884989499049914992499349944995499649974998499950005001500250035004500550065007500850095010501150125013501450155016501750185019502050215022502350245025502650275028502950305031503250335034503550365037503850395040504150425043504450455046504750485049505050515052505350545055505650575058505950605061506250635064506550665067506850695070507150725073507450755076507750785079508050815082508350845085508650875088508950905091509250935094509550965097509850995100510151025103510451055106510751085109511051115112511351145115511651175118511951205121512251235124512551265127512851295130513151325133513451355136513751385139514051415142514351445145514651475148514951505151515251535154515551565157515851595160516151625163516451655166516751685169517051715172517351745175517651775178517951805181518251835184518551865187518851895190519151925193519451955196519751985199520052015202520352045205520652075208520952105211521252135214521552165217521852195220522152225223522452255226522752285229523052315232523352345235523652375238523952405241524252435244524552465247524852495250525152525253525452555256525752585259526052615262526352645265526652675268526952705271527252735274527552765277527852795280528152825283528452855286528752885289529052915292529352945295529652975298529953005301530253035304530553065307530853095310531153125313531453155316531753185319532053215322532353245325532653275328532953305331533253335334533553365337533853395340534153425343534453455346534753485349535053515352535353545355535653575358535953605361536253635364536553665367536853695370537153725373537453755376537753785379538053815382538353845385538653875388538953905391539253935394539553965397539853995400540154025403540454055406540754085409541054115412541354145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454545554565457545854595460546154625463546454655466546754685469547054715472547354745475547654775478547954805481548254835484548554865487548854895490549154925493549454955496549754985499550055015502550355045505550655075508550955105511551255135514551555165517551855195520552155225523552455255526552755285529553055315532553355345535553655375538553955405541554255435544554555465547554855495550555155525553555455555556555755585559556055615562556355645565556655675568556955705571557255735574557555765577557855795580558155825583558455855586558755885589559055915592559355945595559655975598559956005601560256035604560556065607560856095610561156125613561456155616561756185619562056215622562356245625562656275628562956305631563256335634563556365637563856395640564156425643564456455646564756485649565056515652565356545655565656575658565956605661566256635664566556665667566856695670567156725673567456755676567756785679568056815682568356845685568656875688568956905691569256935694569556965697569856995700570157025703570457055706570757085709571057115712571357145715571657175718571957205721572257235724572557265727572857295730573157325733573457355736573757385739574057415742574357445745574657475748574957505751575257535754575557565757575857595760576157625763576457655766576757685769577057715772577357745775577657775778577957805781578257835784578557865787578857895790579157925793579457955796579757985799580058015802580358045805580658075808580958105811581258135814581558165817581858195820582158225823582458255826582758285829583058315832583358345835583658375838583958405841584258435844584558465847584858495850585158525853585458555856585758585859586058615862586358645865586658675868586958705871587258735874587558765877587858795880588158825883588458855886588758885889589058915892589358945895589658975898589959005901590259035904590559065907590859095910591159125913591459155916591759185919592059215922592359245925592659275928592959305931593259335934593559365937593859395940594159425943594459455946594759485949595059515952595359545955595659575958595959605961596259635964596559665967596859695970597159725973597459755976597759785979598059815982598359845985598659875988598959905991599259935994599559965997599859996000600160026003600460056006600760086009601060116012601360146015601660176018601960206021602260236024602560266027602860296030603160326033603460356036603760386039604060416042604360446045604660476048604960506051605260536054605560566057605860596060606160626063606460656066606760686069607060716072607360746075607660776078607960806081608260836084608560866087608860896090609160926093609460956096609760986099610061016102610361046105610661076108610961106111611261136114611561166117611861196120612161226123612461256126612761286129613061316132613361346135613661376138613961406141614261436144614561466147614861496150615161526153615461556156615761586159616061616162616361646165616661676168616961706171617261736174617561766177617861796180618161826183618461856186618761886189619061916192619361946195619661976198619962006201620262036204620562066207620862096210621162126213621462156216621762186219622062216222622362246225622662276228622962306231623262336234623562366237623862396240624162426243624462456246624762486249625062516252625362546255625662576258625962606261626262636264626562666267626862696270627162726273627462756276627762786279628062816282628362846285628662876288628962906291629262936294629562966297629862996300630163026303630463056306630763086309631063116312631363146315631663176318631963206321632263236324632563266327632863296330633163326333633463356336633763386339634063416342634363446345634663476348634963506351635263536354635563566357635863596360636163626363636463656366636763686369637063716372637363746375637663776378637963806381638263836384638563866387638863896390639163926393639463956396639763986399640064016402640364046405640664076408640964106411641264136414641564166417641864196420642164226423642464256426642764286429643064316432643364346435643664376438643964406441644264436444644564466447644864496450645164526453645464556456645764586459646064616462646364646465646664676468646964706471647264736474647564766477647864796480648164826483648464856486648764886489649064916492649364946495649664976498649965006501650265036504650565066507650865096510651165126513651465156516651765186519652065216522652365246525652665276528652965306531653265336534653565366537653865396540654165426543654465456546654765486549655065516552655365546555655665576558655965606561656265636564656565666567656865696570657165726573657465756576657765786579658065816582658365846585658665876588658965906591659265936594659565966597659865996600660166026603660466056606660766086609661066116612661366146615661666176618661966206621662266236624662566266627662866296630663166326633663466356636663766386639664066416642664366446645664666476648664966506651665266536654665566566657665866596660666166626663666466656666666766686669667066716672667366746675667666776678667966806681668266836684668566866687668866896690669166926693669466956696669766986699670067016702670367046705670667076708670967106711671267136714671567166717671867196720672167226723672467256726672767286729673067316732673367346735673667376738673967406741674267436744674567466747674867496750675167526753675467556756675767586759676067616762676367646765676667676768676967706771677267736774677567766777677867796780678167826783678467856786678767886789679067916792679367946795679667976798679968006801680268036804680568066807680868096810681168126813681468156816681768186819682068216822682368246825682668276828682968306831683268336834683568366837683868396840684168426843684468456846684768486849685068516852685368546855685668576858685968606861686268636864686568666867686868696870687168726873687468756876687768786879688068816882688368846885688668876888688968906891689268936894689568966897689868996900690169026903690469056906690769086909691069116912691369146915691669176918691969206921692269236924692569266927692869296930693169326933693469356936693769386939694069416942694369446945694669476948694969506951695269536954695569566957695869596960696169626963696469656966696769686969697069716972697369746975697669776978697969806981698269836984698569866987698869896990699169926993699469956996699769986999700070017002700370047005700670077008700970107011701270137014701570167017701870197020702170227023702470257026702770287029703070317032703370347035703670377038703970407041704270437044704570467047704870497050705170527053705470557056705770587059706070617062706370647065706670677068706970707071707270737074707570767077707870797080708170827083708470857086708770887089709070917092709370947095709670977098709971007101710271037104710571067107710871097110711171127113711471157116711771187119712071217122712371247125712671277128712971307131713271337134713571367137713871397140714171427143714471457146714771487149715071517152715371547155715671577158715971607161716271637164716571667167716871697170717171727173717471757176717771787179718071817182718371847185718671877188718971907191719271937194719571967197719871997200720172027203720472057206720772087209721072117212721372147215721672177218721972207221722272237224722572267227722872297230723172327233723472357236723772387239724072417242724372447245724672477248724972507251725272537254725572567257725872597260726172627263726472657266726772687269727072717272727372747275727672777278727972807281728272837284728572867287728872897290729172927293729472957296729772987299730073017302730373047305730673077308730973107311731273137314731573167317731873197320732173227323732473257326732773287329733073317332733373347335733673377338733973407341734273437344734573467347734873497350735173527353735473557356735773587359736073617362736373647365736673677368736973707371737273737374737573767377737873797380738173827383738473857386738773887389739073917392739373947395739673977398739974007401740274037404740574067407740874097410741174127413741474157416741774187419742074217422742374247425742674277428742974307431743274337434743574367437743874397440744174427443744474457446744774487449745074517452745374547455745674577458745974607461746274637464746574667467746874697470747174727473747474757476747774787479748074817482748374847485748674877488748974907491749274937494749574967497749874997500750175027503750475057506750775087509751075117512751375147515751675177518751975207521752275237524752575267527752875297530753175327533753475357536753775387539754075417542754375447545754675477548754975507551755275537554755575567557755875597560756175627563756475657566756775687569757075717572757375747575757675777578757975807581758275837584758575867587758875897590759175927593759475957596759775987599760076017602760376047605760676077608760976107611761276137614761576167617761876197620762176227623762476257626762776287629763076317632763376347635763676377638763976407641764276437644764576467647764876497650765176527653765476557656765776587659766076617662766376647665766676677668766976707671767276737674767576767677767876797680768176827683768476857686768776887689769076917692769376947695769676977698769977007701770277037704770577067707770877097710771177127713771477157716771777187719772077217722772377247725772677277728772977307731773277337734773577367737773877397740774177427743774477457746774777487749775077517752775377547755775677577758775977607761776277637764776577667767776877697770777177727773777477757776777777787779778077817782778377847785778677877788778977907791779277937794779577967797779877997800780178027803780478057806780778087809781078117812781378147815781678177818781978207821782278237824782578267827782878297830783178327833783478357836783778387839784078417842784378447845784678477848784978507851785278537854785578567857785878597860786178627863786478657866786778687869787078717872787378747875787678777878787978807881788278837884788578867887788878897890789178927893789478957896789778987899790079017902790379047905790679077908790979107911791279137914791579167917791879197920792179227923792479257926792779287929793079317932793379347935793679377938793979407941794279437944794579467947794879497950795179527953795479557956795779587959796079617962796379647965796679677968796979707971797279737974797579767977797879797980798179827983798479857986798779887989799079917992799379947995799679977998799980008001800280038004800580068007800880098010801180128013801480158016801780188019802080218022802380248025802680278028802980308031803280338034803580368037803880398040804180428043804480458046804780488049805080518052805380548055805680578058805980608061806280638064806580668067806880698070807180728073807480758076807780788079808080818082808380848085808680878088808980908091809280938094809580968097809880998100810181028103810481058106810781088109811081118112811381148115811681178118811981208121812281238124812581268127812881298130813181328133813481358136813781388139814081418142814381448145814681478148814981508151815281538154815581568157815881598160816181628163816481658166816781688169817081718172817381748175817681778178817981808181818281838184818581868187818881898190819181928193819481958196819781988199820082018202820382048205820682078208820982108211821282138214821582168217821882198220822182228223822482258226822782288229823082318232823382348235823682378238823982408241824282438244824582468247824882498250825182528253825482558256825782588259826082618262826382648265826682678268826982708271827282738274827582768277827882798280828182828283828482858286828782888289829082918292829382948295829682978298829983008301830283038304830583068307830883098310831183128313831483158316831783188319832083218322832383248325832683278328832983308331833283338334833583368337833883398340834183428343834483458346834783488349835083518352835383548355835683578358835983608361836283638364836583668367836883698370837183728373837483758376837783788379838083818382838383848385838683878388838983908391839283938394839583968397839883998400840184028403840484058406840784088409841084118412841384148415841684178418841984208421842284238424842584268427842884298430843184328433843484358436843784388439844084418442844384448445844684478448844984508451845284538454845584568457845884598460846184628463846484658466846784688469847084718472847384748475847684778478847984808481848284838484848584868487848884898490849184928493849484958496849784988499850085018502850385048505850685078508850985108511851285138514851585168517851885198520852185228523852485258526852785288529853085318532853385348535853685378538853985408541854285438544854585468547854885498550855185528553855485558556855785588559856085618562856385648565856685678568856985708571857285738574857585768577857885798580858185828583858485858586858785888589859085918592859385948595859685978598859986008601860286038604860586068607860886098610861186128613861486158616861786188619862086218622862386248625862686278628862986308631863286338634863586368637863886398640864186428643864486458646864786488649865086518652865386548655865686578658865986608661866286638664866586668667866886698670867186728673867486758676867786788679868086818682868386848685868686878688868986908691869286938694869586968697869886998700870187028703870487058706870787088709871087118712871387148715871687178718871987208721872287238724872587268727872887298730873187328733873487358736873787388739874087418742874387448745874687478748874987508751875287538754875587568757875887598760876187628763876487658766876787688769877087718772877387748775877687778778877987808781878287838784878587868787878887898790879187928793879487958796879787988799880088018802880388048805880688078808880988108811881288138814881588168817881888198820882188228823882488258826882788288829883088318832883388348835883688378838883988408841884288438844884588468847884888498850885188528853885488558856885788588859886088618862886388648865886688678868886988708871887288738874887588768877887888798880888188828883888488858886888788888889889088918892889388948895889688978898889989008901890289038904890589068907890889098910891189128913891489158916891789188919892089218922892389248925892689278928892989308931893289338934893589368937893889398940894189428943894489458946894789488949895089518952895389548955895689578958895989608961896289638964896589668967896889698970897189728973897489758976897789788979898089818982898389848985898689878988898989908991899289938994899589968997899889999000900190029003900490059006900790089009901090119012901390149015901690179018901990209021902290239024902590269027902890299030903190329033903490359036903790389039904090419042904390449045904690479048904990509051905290539054905590569057905890599060906190629063906490659066906790689069907090719072907390749075907690779078907990809081908290839084908590869087908890899090909190929093909490959096909790989099910091019102910391049105910691079108910991109111911291139114911591169117911891199120912191229123912491259126912791289129913091319132913391349135913691379138913991409141914291439144914591469147914891499150915191529153915491559156915791589159916091619162916391649165916691679168916991709171917291739174917591769177917891799180918191829183918491859186918791889189919091919192919391949195919691979198919992009201920292039204920592069207920892099210921192129213921492159216921792189219922092219222922392249225922692279228922992309231923292339234923592369237923892399240924192429243924492459246924792489249925092519252925392549255925692579258925992609261926292639264926592669267926892699270927192729273927492759276927792789279928092819282928392849285928692879288928992909291929292939294929592969297929892999300930193029303930493059306930793089309931093119312931393149315931693179318931993209321932293239324932593269327932893299330933193329333933493359336933793389339934093419342934393449345934693479348934993509351935293539354935593569357935893599360936193629363936493659366936793689369937093719372937393749375937693779378937993809381938293839384938593869387938893899390939193929393939493959396939793989399940094019402940394049405940694079408940994109411941294139414941594169417941894199420942194229423942494259426942794289429943094319432943394349435943694379438943994409441944294439444944594469447944894499450945194529453945494559456945794589459946094619462946394649465946694679468946994709471947294739474947594769477947894799480948194829483948494859486948794889489949094919492949394949495949694979498949995009501950295039504950595069507950895099510951195129513951495159516951795189519952095219522952395249525952695279528952995309531953295339534953595369537953895399540954195429543954495459546954795489549955095519552955395549555955695579558955995609561956295639564956595669567956895699570957195729573957495759576957795789579958095819582958395849585958695879588958995909591959295939594959595969597959895999600960196029603960496059606960796089609961096119612961396149615961696179618961996209621962296239624962596269627962896299630963196329633963496359636963796389639964096419642964396449645964696479648964996509651965296539654965596569657965896599660966196629663966496659666966796689669967096719672967396749675967696779678967996809681968296839684968596869687968896899690969196929693969496959696969796989699970097019702970397049705970697079708970997109711971297139714971597169717971897199720972197229723972497259726972797289729973097319732973397349735973697379738973997409741974297439744974597469747974897499750975197529753975497559756975797589759976097619762976397649765976697679768976997709771977297739774977597769777977897799780978197829783978497859786978797889789979097919792979397949795979697979798979998009801980298039804980598069807980898099810981198129813981498159816981798189819982098219822982398249825982698279828982998309831983298339834983598369837983898399840984198429843984498459846984798489849985098519852985398549855985698579858985998609861986298639864986598669867986898699870987198729873987498759876987798789879988098819882988398849885988698879888988998909891989298939894989598969897989898999900990199029903990499059906990799089909991099119912991399149915991699179918991999209921992299239924992599269927992899299930993199329933993499359936993799389939994099419942994399449945994699479948994999509951995299539954995599569957995899599960996199629963996499659966996799689969997099719972997399749975997699779978997999809981998299839984998599869987998899899990999199929993999499959996999799989999100001000110002100031000410005100061000710008100091001010011100121001310014100151001610017100181001910020100211002210023100241002510026100271002810029100301003110032100331003410035100361003710038100391004010041100421004310044100451004610047100481004910050100511005210053100541005510056100571005810059100601006110062100631006410065100661006710068100691007010071100721007310074100751007610077100781007910080100811008210083100841008510086100871008810089100901009110092100931009410095100961009710098100991010010101101021010310104101051010610107101081010910110101111011210113101141011510116101171011810119101201012110122101231012410125101261012710128101291013010131101321013310134101351013610137101381013910140101411014210143101441014510146101471014810149101501015110152101531015410155101561015710158101591016010161101621016310164101651016610167101681016910170101711017210173101741017510176101771017810179101801018110182101831018410185101861018710188101891019010191101921019310194101951019610197101981019910200102011020210203102041020510206102071020810209102101021110212102131021410215102161021710218102191022010221102221022310224102251022610227102281022910230102311023210233102341023510236102371023810239102401024110242102431024410245102461024710248102491025010251102521025310254102551025610257102581025910260102611026210263102641026510266102671026810269102701027110272102731027410275102761027710278102791028010281102821028310284102851028610287102881028910290102911029210293102941029510296102971029810299103001030110302103031030410305103061030710308103091031010311103121031310314103151031610317103181031910320103211032210323103241032510326103271032810329103301033110332103331033410335103361033710338103391034010341103421034310344103451034610347103481034910350103511035210353103541035510356103571035810359103601036110362103631036410365103661036710368103691037010371103721037310374103751037610377103781037910380103811038210383103841038510386103871038810389103901039110392103931039410395103961039710398103991040010401104021040310404104051040610407104081040910410104111041210413104141041510416104171041810419104201042110422104231042410425104261042710428104291043010431104321043310434104351043610437104381043910440104411044210443104441044510446104471044810449104501045110452104531045410455104561045710458104591046010461104621046310464104651046610467104681046910470104711047210473104741047510476104771047810479104801048110482104831048410485104861048710488104891049010491104921049310494104951049610497104981049910500105011050210503105041050510506105071050810509105101051110512105131051410515105161051710518105191052010521105221052310524105251052610527105281052910530105311053210533105341053510536105371053810539105401054110542105431054410545105461054710548105491055010551105521055310554105551055610557105581055910560105611056210563105641056510566105671056810569105701057110572105731057410575105761057710578105791058010581105821058310584105851058610587105881058910590105911059210593105941059510596105971059810599106001060110602106031060410605106061060710608106091061010611106121061310614106151061610617106181061910620106211062210623106241062510626106271062810629106301063110632106331063410635106361063710638106391064010641106421064310644106451064610647106481064910650106511065210653106541065510656106571065810659106601066110662106631066410665106661066710668106691067010671106721067310674106751067610677106781067910680106811068210683106841068510686106871068810689106901069110692106931069410695106961069710698106991070010701107021070310704107051070610707107081070910710107111071210713107141071510716107171071810719107201072110722107231072410725107261072710728107291073010731107321073310734107351073610737107381073910740107411074210743107441074510746107471074810749107501075110752107531075410755107561075710758107591076010761107621076310764107651076610767107681076910770107711077210773107741077510776107771077810779107801078110782107831078410785107861078710788107891079010791107921079310794107951079610797107981079910800108011080210803108041080510806108071080810809108101081110812108131081410815108161081710818108191082010821108221082310824108251082610827108281082910830108311083210833108341083510836108371083810839108401084110842108431084410845108461084710848108491085010851108521085310854108551085610857108581085910860108611086210863108641086510866108671086810869108701087110872108731087410875108761087710878108791088010881108821088310884108851088610887108881088910890108911089210893108941089510896108971089810899109001090110902109031090410905109061090710908109091091010911109121091310914109151091610917109181091910920109211092210923109241092510926109271092810929109301093110932109331093410935109361093710938109391094010941109421094310944109451094610947109481094910950109511095210953109541095510956109571095810959109601096110962109631096410965109661096710968109691097010971109721097310974109751097610977109781097910980109811098210983109841098510986109871098810989109901099110992109931099410995109961099710998109991100011001110021100311004110051100611007110081100911010110111101211013110141101511016110171101811019110201102111022110231102411025110261102711028110291103011031110321103311034110351103611037110381103911040110411104211043110441104511046110471104811049110501105111052110531105411055110561105711058110591106011061110621106311064110651106611067110681106911070110711107211073110741107511076110771107811079110801108111082110831108411085110861108711088110891109011091110921109311094110951109611097110981109911100111011110211103111041110511106111071110811109111101111111112111131111411115111161111711118111191112011121111221112311124111251112611127111281112911130111311113211133111341113511136111371113811139111401114111142111431114411145111461114711148111491115011151111521115311154111551115611157111581115911160111611116211163111641116511166111671116811169111701117111172111731117411175111761117711178111791118011181111821118311184111851118611187111881118911190111911119211193111941119511196111971119811199112001120111202112031120411205112061120711208112091121011211112121121311214112151121611217112181121911220112211122211223112241122511226112271122811229112301123111232112331123411235112361123711238112391124011241112421124311244112451124611247112481124911250112511125211253112541125511256112571125811259112601126111262112631126411265112661126711268112691127011271112721127311274112751127611277112781127911280112811128211283112841128511286112871128811289112901129111292112931129411295112961129711298112991130011301113021130311304113051130611307113081130911310113111131211313113141131511316113171131811319113201132111322113231132411325113261132711328113291133011331113321133311334113351133611337113381133911340113411134211343113441134511346113471134811349113501135111352113531135411355113561135711358113591136011361113621136311364113651136611367113681136911370113711137211373113741137511376113771137811379113801138111382113831138411385113861138711388113891139011391113921139311394113951139611397113981139911400114011140211403114041140511406114071140811409114101141111412114131141411415114161141711418114191142011421114221142311424114251142611427114281142911430114311143211433114341143511436114371143811439114401144111442114431144411445114461144711448114491145011451114521145311454114551145611457114581145911460114611146211463114641146511466114671146811469114701147111472114731147411475114761147711478114791148011481114821148311484114851148611487114881148911490114911149211493114941149511496114971149811499115001150111502115031150411505115061150711508115091151011511115121151311514115151151611517115181151911520115211152211523115241152511526115271152811529115301153111532115331153411535115361153711538115391154011541115421154311544115451154611547115481154911550115511155211553115541155511556115571155811559115601156111562115631156411565115661156711568115691157011571115721157311574115751157611577115781157911580115811158211583115841158511586115871158811589115901159111592115931159411595115961159711598115991160011601116021160311604116051160611607116081160911610116111161211613116141161511616116171161811619116201162111622116231162411625116261162711628116291163011631116321163311634116351163611637116381163911640116411164211643116441164511646116471164811649116501165111652116531165411655116561165711658116591166011661116621166311664116651166611667116681166911670116711167211673116741167511676116771167811679116801168111682116831168411685116861168711688116891169011691116921169311694116951169611697116981169911700117011170211703117041170511706117071170811709117101171111712117131171411715117161171711718117191172011721117221172311724117251172611727117281172911730117311173211733117341173511736117371173811739117401174111742117431174411745117461174711748117491175011751117521175311754117551175611757117581175911760117611176211763117641176511766117671176811769117701177111772117731177411775117761177711778117791178011781117821178311784117851178611787117881178911790117911179211793117941179511796117971179811799118001180111802118031180411805118061180711808118091181011811118121181311814118151181611817118181181911820118211182211823118241182511826118271182811829118301183111832118331183411835118361183711838118391184011841118421184311844118451184611847118481184911850118511185211853118541185511856118571185811859118601186111862118631186411865118661186711868118691187011871118721187311874118751187611877118781187911880118811188211883118841188511886118871188811889118901189111892118931189411895118961189711898118991190011901119021190311904119051190611907119081190911910119111191211913119141191511916119171191811919119201192111922119231192411925119261192711928119291193011931119321193311934119351193611937119381193911940119411194211943119441194511946119471194811949119501195111952119531195411955119561195711958119591196011961119621196311964119651196611967119681196911970119711197211973119741197511976119771197811979119801198111982119831198411985119861198711988119891199011991119921199311994119951199611997119981199912000120011200212003120041200512006120071200812009120101201112012120131201412015120161201712018120191202012021120221202312024120251202612027120281202912030120311203212033120341203512036120371203812039120401204112042120431204412045120461204712048120491205012051120521205312054120551205612057120581205912060120611206212063120641206512066120671206812069120701207112072120731207412075120761207712078120791208012081120821208312084120851208612087120881208912090120911209212093120941209512096120971209812099121001210112102121031210412105121061210712108121091211012111121121211312114121151211612117121181211912120121211212212123121241212512126121271212812129121301213112132121331213412135121361213712138121391214012141121421214312144121451214612147121481214912150121511215212153121541215512156121571215812159121601216112162121631216412165121661216712168121691217012171121721217312174121751217612177121781217912180121811218212183121841218512186121871218812189121901219112192121931219412195121961219712198121991220012201122021220312204122051220612207122081220912210122111221212213122141221512216122171221812219122201222112222122231222412225122261222712228122291223012231122321223312234122351223612237122381223912240122411224212243122441224512246122471224812249122501225112252122531225412255122561225712258122591226012261122621226312264122651226612267122681226912270122711227212273122741227512276122771227812279122801228112282122831228412285122861228712288122891229012291122921229312294122951229612297122981229912300123011230212303123041230512306123071230812309123101231112312123131231412315123161231712318123191232012321123221232312324123251232612327123281232912330123311233212333123341233512336123371233812339123401234112342123431234412345123461234712348123491235012351123521235312354123551235612357123581235912360123611236212363123641236512366123671236812369123701237112372123731237412375123761237712378123791238012381123821238312384123851238612387123881238912390123911239212393123941239512396123971239812399124001240112402124031240412405124061240712408124091241012411124121241312414124151241612417124181241912420124211242212423124241242512426124271242812429124301243112432124331243412435124361243712438124391244012441124421244312444124451244612447124481244912450124511245212453124541245512456124571245812459124601246112462124631246412465124661246712468124691247012471124721247312474124751247612477124781247912480124811248212483124841248512486124871248812489124901249112492124931249412495124961249712498124991250012501125021250312504125051250612507125081250912510125111251212513125141251512516125171251812519125201252112522125231252412525125261252712528125291253012531125321253312534125351253612537125381253912540125411254212543125441254512546125471254812549125501255112552125531255412555125561255712558125591256012561125621256312564125651256612567125681256912570125711257212573125741257512576125771257812579125801258112582125831258412585125861258712588125891259012591125921259312594125951259612597125981259912600126011260212603126041260512606126071260812609126101261112612126131261412615126161261712618126191262012621126221262312624126251262612627126281262912630126311263212633126341263512636126371263812639126401264112642126431264412645126461264712648126491265012651126521265312654126551265612657126581265912660126611266212663126641266512666126671266812669126701267112672126731267412675126761267712678126791268012681126821268312684126851268612687126881268912690126911269212693126941269512696126971269812699127001270112702127031270412705127061270712708127091271012711127121271312714127151271612717127181271912720127211272212723127241272512726127271272812729127301273112732127331273412735127361273712738127391274012741127421274312744127451274612747127481274912750127511275212753127541275512756127571275812759127601276112762127631276412765127661276712768127691277012771127721277312774127751277612777127781277912780127811278212783127841278512786127871278812789127901279112792127931279412795127961279712798127991280012801128021280312804128051280612807128081280912810128111281212813128141281512816128171281812819128201282112822128231282412825128261282712828128291283012831128321283312834128351283612837128381283912840128411284212843128441284512846128471284812849128501285112852128531285412855128561285712858128591286012861128621286312864128651286612867128681286912870128711287212873128741287512876128771287812879128801288112882128831288412885128861288712888128891289012891128921289312894128951289612897128981289912900129011290212903129041290512906129071290812909129101291112912129131291412915129161291712918129191292012921129221292312924129251292612927129281292912930129311293212933129341293512936129371293812939129401294112942129431294412945129461294712948129491295012951129521295312954129551295612957129581295912960129611296212963129641296512966129671296812969129701297112972129731297412975129761297712978129791298012981129821298312984129851298612987129881298912990129911299212993129941299512996129971299812999130001300113002130031300413005130061300713008130091301013011130121301313014130151301613017130181301913020130211302213023130241302513026130271302813029130301303113032130331303413035130361303713038130391304013041130421304313044130451304613047130481304913050130511305213053130541305513056130571305813059130601306113062130631306413065130661306713068130691307013071130721307313074130751307613077130781307913080130811308213083130841308513086130871308813089130901309113092130931309413095130961309713098130991310013101131021310313104131051310613107131081310913110131111311213113131141311513116131171311813119131201312113122131231312413125131261312713128131291313013131131321313313134131351313613137131381313913140131411314213143131441314513146131471314813149131501315113152131531315413155131561315713158131591316013161131621316313164131651316613167131681316913170131711317213173131741317513176131771317813179131801318113182131831318413185131861318713188131891319013191131921319313194131951319613197131981319913200132011320213203132041320513206132071320813209132101321113212132131321413215132161321713218132191322013221132221322313224132251322613227132281322913230132311323213233132341323513236132371323813239132401324113242132431324413245132461324713248132491325013251132521325313254132551325613257132581325913260132611326213263132641326513266132671326813269
  1. <?php
  2. /* @file: This file contains default schema definitions for all chado v1.2 tables
  3. * to be used by other function. Specifically these functions are used
  4. * by the tripal_core select/insert/update API functions and by
  5. * the Tripal Views module.
  6. *
  7. * These schema definitions can be augmented by anohter modules
  8. * (specifically to add missing definitions) by implementing
  9. * hook_chado_schema_v1_2_<table name>().
  10. *
  11. * @defgroup tripal_schema_api Core Module Schema API
  12. * @{
  13. * Provides an application programming interface (API) for describing Chado tables.
  14. * This API consists of a set of functions, one for each table in Chado. Each
  15. * function simply returns a Drupal style array that defines the table.
  16. *
  17. * Because Drupal 6 does not handle foreign key (FK) relationships, however FK
  18. * relationships are needed to for Tripal Views. Therefore, FK relationships
  19. * have been added to the schema defintitions below.
  20. *
  21. * The functions provided in this documentation should not be called as is, but if you need
  22. * the Drupal-style array definition for any table, use the following function
  23. * call:
  24. *
  25. * $table_desc = tripal_core_get_chado_table_schema($table)
  26. *
  27. * where the variable $table contains the name of the table you want to
  28. * retireve. The tripal_core_get_chado_table_schema function determines the appropriate version of
  29. * Chado and uses the Drupal hook infrastructure to call the appropriate
  30. * hook function to retrieve the table schema.
  31. *
  32. * @}
  33. * @ingroup tripal_api
  34. */
  35. /**
  36. * Implements hook_chado_schema_v1_2_acquisition()
  37. * Purpose: To describe the structure of 'acquisition' to tripal
  38. * @see tripal_core_chado_insert()
  39. * @see tripal_core_chado_update()
  40. * @see tripal_core_chado_select()
  41. *
  42. * @return
  43. * An array describing the 'acquisition' table
  44. *
  45. * @ingroup tripal_chado_v1.2_schema_api
  46. *
  47. */
  48. function tripal_core_chado_schema_v1_2_acquisition() {
  49. $description = array(
  50. 'description' => 'TODO: please describe this table!',
  51. 'fields' => array(
  52. 'acquisition_id' => array(
  53. 'description' => 'TODO: please describe this field!',
  54. 'type' => 'serial',
  55. 'not null' => TRUE,
  56. ),
  57. 'assay_id' => array(
  58. 'description' => 'TODO: please describe this field!',
  59. 'type' => 'int',
  60. 'not null' => TRUE,
  61. ),
  62. 'protocol_id' => array(
  63. 'description' => 'TODO: please describe this field!',
  64. 'type' => 'int',
  65. 'not null' => FALSE,
  66. ),
  67. 'channel_id' => array(
  68. 'description' => 'TODO: please describe this field!',
  69. 'type' => 'int',
  70. 'not null' => FALSE,
  71. ),
  72. 'acquisitiondate' => array(
  73. 'description' => 'TODO: please describe this field!',
  74. 'type' => 'datetime',
  75. 'not null' => FALSE,
  76. 'default' => 'ow(',
  77. ),
  78. 'name' => array(
  79. 'description' => 'TODO: please describe this field!',
  80. 'type' => 'text',
  81. 'not null' => FALSE,
  82. ),
  83. 'uri' => array(
  84. 'description' => 'TODO: please describe this field!',
  85. 'type' => 'text',
  86. 'not null' => FALSE,
  87. ),
  88. ),
  89. 'primary key' => array(
  90. 0 => 'acquisition_id',
  91. ),
  92. 'unique keys' => array(
  93. 'acquisition_c1' => array(
  94. 0 => 'name',
  95. ),
  96. ),
  97. 'indexes' => array(
  98. 'acquisition_idx1' => array(
  99. 0 => 'assay_id',
  100. ),
  101. 'acquisition_idx2' => array(
  102. 0 => 'protocol_id',
  103. ),
  104. 'acquisition_idx3' => array(
  105. 0 => 'channel_id',
  106. ),
  107. ),
  108. 'foreign keys' => array(
  109. 'protocol' => array(
  110. 'table' => 'protocol',
  111. 'columns' => array(
  112. 'protocol_id' => 'protocol_id',
  113. ),
  114. ),
  115. 'assay' => array(
  116. 'table' => 'assay',
  117. 'columns' => array(
  118. 'assay_id' => 'assay_id',
  119. ),
  120. ),
  121. 'channel' => array(
  122. 'table' => 'channel',
  123. 'columns' => array(
  124. 'channel_id' => 'channel_id',
  125. ),
  126. ),
  127. ),
  128. );
  129. return $description;
  130. }
  131. /**
  132. * Implements hook_chado_schema_v1_2_acquisition_relationship()
  133. * Purpose: To describe the structure of 'acquisition_relationship' to tripal
  134. * @see tripal_core_chado_insert()
  135. * @see tripal_core_chado_update()
  136. * @see tripal_core_chado_select()
  137. *
  138. * @return
  139. * An array describing the 'acquisition_relationship' table
  140. *
  141. * @ingroup tripal_chado_v1.2_schema_api
  142. *
  143. */
  144. function tripal_core_chado_schema_v1_2_acquisition_relationship() {
  145. $description = array(
  146. 'description' => 'TODO: please describe this table!',
  147. 'fields' => array(
  148. 'acquisition_relationship_id' => array(
  149. 'description' => 'TODO: please describe this field!',
  150. 'type' => 'serial',
  151. 'not null' => TRUE,
  152. ),
  153. 'subject_id' => array(
  154. 'description' => 'TODO: please describe this field!',
  155. 'type' => 'int',
  156. 'not null' => TRUE,
  157. ),
  158. 'type_id' => array(
  159. 'description' => 'TODO: please describe this field!',
  160. 'type' => 'int',
  161. 'not null' => TRUE,
  162. ),
  163. 'object_id' => array(
  164. 'description' => 'TODO: please describe this field!',
  165. 'type' => 'int',
  166. 'not null' => TRUE,
  167. ),
  168. 'value' => array(
  169. 'description' => 'TODO: please describe this field!',
  170. 'type' => 'text',
  171. 'not null' => FALSE,
  172. ),
  173. 'rank' => array(
  174. 'description' => 'TODO: please describe this field!',
  175. 'type' => 'int',
  176. 'not null' => TRUE,
  177. 'default' => 0,
  178. ),
  179. ),
  180. 'primary key' => array(
  181. 0 => 'acquisition_relationship_id',
  182. ),
  183. 'unique keys' => array(
  184. 'acquisition_relationship_c1' => array(
  185. 0 => 'subject_id',
  186. 1 => 'object_id',
  187. 2 => 'type_id',
  188. 3 => 'rank',
  189. ),
  190. ),
  191. 'indexes' => array(
  192. 'acquisition_relationship_idx1' => array(
  193. 0 => 'subject_id',
  194. ),
  195. 'acquisition_relationship_idx2' => array(
  196. 0 => 'type_id',
  197. ),
  198. 'acquisition_relationship_idx3' => array(
  199. 0 => 'object_id',
  200. ),
  201. ),
  202. 'foreign keys' => array(
  203. 'cvterm' => array(
  204. 'table' => 'cvterm',
  205. 'columns' => array(
  206. 'type_id' => 'cvterm_id',
  207. ),
  208. ),
  209. 'acquisition' => array(
  210. 'table' => 'acquisition',
  211. 'columns' => array(
  212. 'subject_id' => 'acquisition_id',
  213. 'object_id' => 'acquisition_id',
  214. ),
  215. ),
  216. ),
  217. );
  218. return $description;
  219. }
  220. /**
  221. * Implements hook_chado_schema_v1_2_acquisitionprop()
  222. * Purpose: To describe the structure of 'acquisitionprop' to tripal
  223. * @see tripal_core_chado_insert()
  224. * @see tripal_core_chado_update()
  225. * @see tripal_core_chado_select()
  226. *
  227. * @return
  228. * An array describing the 'acquisitionprop' table
  229. *
  230. * @ingroup tripal_chado_v1.2_schema_api
  231. *
  232. */
  233. function tripal_core_chado_schema_v1_2_acquisitionprop() {
  234. $description = array(
  235. 'description' => 'TODO: please describe this table!',
  236. 'fields' => array(
  237. 'acquisitionprop_id' => array(
  238. 'description' => 'TODO: please describe this field!',
  239. 'type' => 'serial',
  240. 'not null' => TRUE,
  241. ),
  242. 'acquisition_id' => array(
  243. 'description' => 'TODO: please describe this field!',
  244. 'type' => 'int',
  245. 'not null' => TRUE,
  246. ),
  247. 'type_id' => array(
  248. 'description' => 'TODO: please describe this field!',
  249. 'type' => 'int',
  250. 'not null' => TRUE,
  251. ),
  252. 'value' => array(
  253. 'description' => 'TODO: please describe this field!',
  254. 'type' => 'text',
  255. 'not null' => FALSE,
  256. ),
  257. 'rank' => array(
  258. 'description' => 'TODO: please describe this field!',
  259. 'type' => 'int',
  260. 'not null' => TRUE,
  261. 'default' => 0,
  262. ),
  263. ),
  264. 'primary key' => array(
  265. 0 => 'acquisitionprop_id',
  266. ),
  267. 'unique keys' => array(
  268. 'acquisitionprop_c1' => array(
  269. 0 => 'acquisition_id',
  270. 1 => 'type_id',
  271. 2 => 'rank',
  272. ),
  273. ),
  274. 'indexes' => array(
  275. 'acquisitionprop_idx1' => array(
  276. 0 => 'acquisition_id',
  277. ),
  278. 'acquisitionprop_idx2' => array(
  279. 0 => 'type_id',
  280. ),
  281. ),
  282. 'foreign keys' => array(
  283. 'cvterm' => array(
  284. 'table' => 'cvterm',
  285. 'columns' => array(
  286. 'type_id' => 'cvterm_id',
  287. ),
  288. ),
  289. 'acquisition' => array(
  290. 'table' => 'acquisition',
  291. 'columns' => array(
  292. 'acquisition_id' => 'acquisition_id',
  293. ),
  294. ),
  295. ),
  296. );
  297. return $description;
  298. }
  299. /**
  300. * Implements hook_chado_schema_v1_2_analysis()
  301. * Purpose: To describe the structure of 'analysis' to tripal
  302. * @see tripal_core_chado_insert()
  303. * @see tripal_core_chado_update()
  304. * @see tripal_core_chado_select()
  305. *
  306. * @return
  307. * An array describing the 'analysis' table
  308. *
  309. * @ingroup tripal_chado_v1.2_schema_api
  310. *
  311. */
  312. function tripal_core_chado_schema_v1_2_analysis() {
  313. $description = array(
  314. 'description' => 'TODO: please describe this table!',
  315. 'fields' => array(
  316. 'analysis_id' => array(
  317. 'description' => 'TODO: please describe this field!',
  318. 'type' => 'serial',
  319. 'not null' => TRUE,
  320. ),
  321. 'name' => array(
  322. 'description' => 'TODO: please describe this field!',
  323. 'type' => 'varchar',
  324. 'length' => '255',
  325. 'not null' => FALSE,
  326. ),
  327. 'description' => array(
  328. 'description' => 'TODO: please describe this field!',
  329. 'type' => 'text',
  330. 'not null' => FALSE,
  331. ),
  332. 'program' => array(
  333. 'description' => 'TODO: please describe this field!',
  334. 'type' => 'varchar',
  335. 'length' => '255',
  336. 'not null' => TRUE,
  337. ),
  338. 'programversion' => array(
  339. 'description' => 'TODO: please describe this field!',
  340. 'type' => 'varchar',
  341. 'length' => '255',
  342. 'not null' => TRUE,
  343. ),
  344. 'algorithm' => array(
  345. 'description' => 'TODO: please describe this field!',
  346. 'type' => 'varchar',
  347. 'length' => '255',
  348. 'not null' => FALSE,
  349. ),
  350. 'sourcename' => array(
  351. 'description' => 'TODO: please describe this field!',
  352. 'type' => 'varchar',
  353. 'length' => '255',
  354. 'not null' => FALSE,
  355. ),
  356. 'sourceversion' => array(
  357. 'description' => 'TODO: please describe this field!',
  358. 'type' => 'varchar',
  359. 'length' => '255',
  360. 'not null' => FALSE,
  361. ),
  362. 'sourceuri' => array(
  363. 'description' => 'TODO: please describe this field!',
  364. 'type' => 'text',
  365. 'not null' => FALSE,
  366. ),
  367. 'timeexecuted' => array(
  368. 'description' => 'TODO: please describe this field!',
  369. 'type' => 'datetime',
  370. 'not null' => TRUE,
  371. 'default' => 'ow(',
  372. ),
  373. ),
  374. 'primary key' => array(
  375. 0 => 'analysis_id',
  376. ),
  377. 'unique keys' => array(
  378. 'analysis_c1' => array(
  379. 0 => 'program',
  380. 1 => 'programversion',
  381. 2 => 'sourcename',
  382. ),
  383. ),
  384. 'foreign keys' => array(
  385. ),
  386. );
  387. return $description;
  388. }
  389. /**
  390. * Implements hook_chado_schema_v1_2_analysisfeature()
  391. * Purpose: To describe the structure of 'analysisfeature' to tripal
  392. * @see tripal_core_chado_insert()
  393. * @see tripal_core_chado_update()
  394. * @see tripal_core_chado_select()
  395. *
  396. * @return
  397. * An array describing the 'analysisfeature' table
  398. *
  399. * @ingroup tripal_chado_v1.2_schema_api
  400. *
  401. */
  402. function tripal_core_chado_schema_v1_2_analysisfeature() {
  403. $description = array(
  404. 'description' => 'TODO: please describe this table!',
  405. 'fields' => array(
  406. 'analysisfeature_id' => array(
  407. 'description' => 'TODO: please describe this field!',
  408. 'type' => 'serial',
  409. 'not null' => TRUE,
  410. ),
  411. 'feature_id' => array(
  412. 'description' => 'TODO: please describe this field!',
  413. 'type' => 'int',
  414. 'not null' => TRUE,
  415. ),
  416. 'analysis_id' => array(
  417. 'description' => 'TODO: please describe this field!',
  418. 'type' => 'int',
  419. 'not null' => TRUE,
  420. ),
  421. 'rawscore' => array(
  422. 'description' => 'TODO: please describe this field!',
  423. 'type' => 'float',
  424. 'size' => 'big',
  425. 'not null' => FALSE,
  426. ),
  427. 'normscore' => array(
  428. 'description' => 'TODO: please describe this field!',
  429. 'type' => 'float',
  430. 'size' => 'big',
  431. 'not null' => FALSE,
  432. ),
  433. 'significance' => array(
  434. 'description' => 'TODO: please describe this field!',
  435. 'type' => 'float',
  436. 'size' => 'big',
  437. 'not null' => FALSE,
  438. ),
  439. 'identity' => array(
  440. 'description' => 'TODO: please describe this field!',
  441. 'type' => 'float',
  442. 'size' => 'big',
  443. 'not null' => FALSE,
  444. ),
  445. ),
  446. 'primary key' => array(
  447. 0 => 'analysisfeature_id',
  448. ),
  449. 'unique keys' => array(
  450. 'analysisfeature_c1' => array(
  451. 0 => 'feature_id',
  452. 1 => 'analysis_id',
  453. ),
  454. ),
  455. 'indexes' => array(
  456. 'analysisfeature_idx1' => array(
  457. 0 => 'feature_id',
  458. ),
  459. 'analysisfeature_idx2' => array(
  460. 0 => 'analysis_id',
  461. ),
  462. ),
  463. 'foreign keys' => array(
  464. 'analysis' => array(
  465. 'table' => 'analysis',
  466. 'columns' => array(
  467. 'analysis_id' => 'analysis_id',
  468. ),
  469. ),
  470. 'feature' => array(
  471. 'table' => 'feature',
  472. 'columns' => array(
  473. 'feature_id' => 'feature_id',
  474. ),
  475. ),
  476. ),
  477. );
  478. return $description;
  479. }
  480. /**
  481. * Implements hook_chado_schema_v1_2_analysisfeatureprop()
  482. * Purpose: To describe the structure of 'analysisfeatureprop' to tripal
  483. * @see tripal_core_chado_insert()
  484. * @see tripal_core_chado_update()
  485. * @see tripal_core_chado_select()
  486. *
  487. * @return
  488. * An array describing the 'analysisfeatureprop' table
  489. *
  490. * @ingroup tripal_chado_v1.2_schema_api
  491. *
  492. */
  493. function tripal_core_chado_schema_v1_2_analysisfeatureprop() {
  494. $description = array(
  495. 'description' => 'TODO: please describe this table!',
  496. 'fields' => array(
  497. 'analysisfeatureprop_id' => array(
  498. 'description' => 'TODO: please describe this field!',
  499. 'type' => 'serial',
  500. 'not null' => TRUE,
  501. ),
  502. 'analysisfeature_id' => array(
  503. 'description' => 'TODO: please describe this field!',
  504. 'type' => 'int',
  505. 'not null' => TRUE,
  506. ),
  507. 'type_id' => array(
  508. 'description' => 'TODO: please describe this field!',
  509. 'type' => 'int',
  510. 'not null' => TRUE,
  511. ),
  512. 'value' => array(
  513. 'description' => 'TODO: please describe this field!',
  514. 'type' => 'text',
  515. 'not null' => FALSE,
  516. ),
  517. 'rank' => array(
  518. 'description' => 'TODO: please describe this field!',
  519. 'type' => 'int',
  520. 'not null' => TRUE,
  521. ),
  522. ),
  523. 'primary key' => array(
  524. 0 => 'analysisfeatureprop_id',
  525. ),
  526. 'unique keys' => array(
  527. 'analysisfeature_id_type_id_rank' => array(
  528. 0 => 'analysisfeature_id',
  529. 1 => 'type_id',
  530. 2 => 'rank',
  531. ),
  532. ),
  533. 'foreign keys' => array(
  534. 'cvterm' => array(
  535. 'table' => 'cvterm',
  536. 'columns' => array(
  537. 'type_id' => 'cvterm_id',
  538. ),
  539. ),
  540. 'analysisfeature' => array(
  541. 'table' => 'analysisfeature',
  542. 'columns' => array(
  543. 'analysisfeature_id' => 'analysisfeature_id',
  544. ),
  545. ),
  546. ),
  547. );
  548. return $description;
  549. }
  550. /**
  551. * Implements hook_chado_schema_v1_2_analysisprop()
  552. * Purpose: To describe the structure of 'analysisprop' to tripal
  553. * @see tripal_core_chado_insert()
  554. * @see tripal_core_chado_update()
  555. * @see tripal_core_chado_select()
  556. *
  557. * @return
  558. * An array describing the 'analysisprop' table
  559. *
  560. * @ingroup tripal_chado_v1.2_schema_api
  561. *
  562. */
  563. function tripal_core_chado_schema_v1_2_analysisprop() {
  564. $description = array(
  565. 'description' => 'TODO: please describe this table!',
  566. 'fields' => array(
  567. 'analysisprop_id' => array(
  568. 'description' => 'TODO: please describe this field!',
  569. 'type' => 'serial',
  570. 'not null' => TRUE,
  571. ),
  572. 'analysis_id' => array(
  573. 'description' => 'TODO: please describe this field!',
  574. 'type' => 'int',
  575. 'not null' => TRUE,
  576. ),
  577. 'type_id' => array(
  578. 'description' => 'TODO: please describe this field!',
  579. 'type' => 'int',
  580. 'not null' => TRUE,
  581. ),
  582. 'value' => array(
  583. 'description' => 'TODO: please describe this field!',
  584. 'type' => 'text',
  585. 'not null' => FALSE,
  586. ),
  587. 'rank' => array(
  588. 'description' => 'TODO: please describe this field!',
  589. 'type' => 'int',
  590. 'not null' => TRUE,
  591. 'default' => 0,
  592. ),
  593. ),
  594. 'primary key' => array(
  595. 0 => 'analysisprop_id',
  596. ),
  597. 'unique keys' => array(
  598. 'analysisprop_c1' => array(
  599. 0 => 'analysis_id',
  600. 1 => 'type_id',
  601. 2 => 'rank',
  602. ),
  603. ),
  604. 'indexes' => array(
  605. 'analysisprop_idx1' => array(
  606. 0 => 'analysis_id',
  607. ),
  608. 'analysisprop_idx2' => array(
  609. 0 => 'type_id',
  610. ),
  611. ),
  612. 'foreign keys' => array(
  613. 'cvterm' => array(
  614. 'table' => 'cvterm',
  615. 'columns' => array(
  616. 'type_id' => 'cvterm_id',
  617. ),
  618. ),
  619. 'analysis' => array(
  620. 'table' => 'analysis',
  621. 'columns' => array(
  622. 'analysis_id' => 'analysis_id',
  623. ),
  624. ),
  625. ),
  626. );
  627. return $description;
  628. }
  629. /**
  630. * Implements hook_chado_schema_v1_2_arraydesign()
  631. * Purpose: To describe the structure of 'arraydesign' to tripal
  632. * @see tripal_core_chado_insert()
  633. * @see tripal_core_chado_update()
  634. * @see tripal_core_chado_select()
  635. *
  636. * @return
  637. * An array describing the 'arraydesign' table
  638. *
  639. * @ingroup tripal_chado_v1.2_schema_api
  640. *
  641. */
  642. function tripal_core_chado_schema_v1_2_arraydesign() {
  643. $description = array(
  644. 'description' => 'TODO: please describe this table!',
  645. 'fields' => array(
  646. 'arraydesign_id' => array(
  647. 'description' => 'TODO: please describe this field!',
  648. 'type' => 'serial',
  649. 'not null' => TRUE,
  650. ),
  651. 'manufacturer_id' => array(
  652. 'description' => 'TODO: please describe this field!',
  653. 'type' => 'int',
  654. 'not null' => TRUE,
  655. ),
  656. 'platformtype_id' => array(
  657. 'description' => 'TODO: please describe this field!',
  658. 'type' => 'int',
  659. 'not null' => TRUE,
  660. ),
  661. 'substratetype_id' => array(
  662. 'description' => 'TODO: please describe this field!',
  663. 'type' => 'int',
  664. 'not null' => FALSE,
  665. ),
  666. 'protocol_id' => array(
  667. 'description' => 'TODO: please describe this field!',
  668. 'type' => 'int',
  669. 'not null' => FALSE,
  670. ),
  671. 'dbxref_id' => array(
  672. 'description' => 'TODO: please describe this field!',
  673. 'type' => 'int',
  674. 'not null' => FALSE,
  675. ),
  676. 'name' => array(
  677. 'description' => 'TODO: please describe this field!',
  678. 'type' => 'text',
  679. 'not null' => TRUE,
  680. ),
  681. 'version' => array(
  682. 'description' => 'TODO: please describe this field!',
  683. 'type' => 'text',
  684. 'not null' => FALSE,
  685. ),
  686. 'description' => array(
  687. 'description' => 'TODO: please describe this field!',
  688. 'type' => 'text',
  689. 'not null' => FALSE,
  690. ),
  691. 'array_dimensions' => array(
  692. 'description' => 'TODO: please describe this field!',
  693. 'type' => 'text',
  694. 'not null' => FALSE,
  695. ),
  696. 'element_dimensions' => array(
  697. 'description' => 'TODO: please describe this field!',
  698. 'type' => 'text',
  699. 'not null' => FALSE,
  700. ),
  701. 'num_of_elements' => array(
  702. 'description' => 'TODO: please describe this field!',
  703. 'type' => 'int',
  704. 'not null' => FALSE,
  705. ),
  706. 'num_array_columns' => array(
  707. 'description' => 'TODO: please describe this field!',
  708. 'type' => 'int',
  709. 'not null' => FALSE,
  710. ),
  711. 'num_array_rows' => array(
  712. 'description' => 'TODO: please describe this field!',
  713. 'type' => 'int',
  714. 'not null' => FALSE,
  715. ),
  716. 'num_grid_columns' => array(
  717. 'description' => 'TODO: please describe this field!',
  718. 'type' => 'int',
  719. 'not null' => FALSE,
  720. ),
  721. 'num_grid_rows' => array(
  722. 'description' => 'TODO: please describe this field!',
  723. 'type' => 'int',
  724. 'not null' => FALSE,
  725. ),
  726. 'num_sub_columns' => array(
  727. 'description' => 'TODO: please describe this field!',
  728. 'type' => 'int',
  729. 'not null' => FALSE,
  730. ),
  731. 'num_sub_rows' => array(
  732. 'description' => 'TODO: please describe this field!',
  733. 'type' => 'int',
  734. 'not null' => FALSE,
  735. ),
  736. ),
  737. 'primary key' => array(
  738. 0 => 'arraydesign_id',
  739. ),
  740. 'unique keys' => array(
  741. 'arraydesign_c1' => array(
  742. 0 => 'name',
  743. ),
  744. ),
  745. 'indexes' => array(
  746. 'arraydesign_idx1' => array(
  747. 0 => 'manufacturer_id',
  748. ),
  749. 'arraydesign_idx2' => array(
  750. 0 => 'platformtype_id',
  751. ),
  752. 'arraydesign_idx3' => array(
  753. 0 => 'substratetype_id',
  754. ),
  755. 'arraydesign_idx4' => array(
  756. 0 => 'protocol_id',
  757. ),
  758. 'arraydesign_idx5' => array(
  759. 0 => 'dbxref_id',
  760. ),
  761. ),
  762. 'foreign keys' => array(
  763. 'cvterm' => array(
  764. 'table' => 'cvterm',
  765. 'columns' => array(
  766. 'platformtype_id' => 'cvterm_id',
  767. 'substratetype_id' => 'cvterm_id',
  768. ),
  769. ),
  770. 'dbxref' => array(
  771. 'table' => 'dbxref',
  772. 'columns' => array(
  773. 'dbxref_id' => 'dbxref_id',
  774. ),
  775. ),
  776. 'contact' => array(
  777. 'table' => 'contact',
  778. 'columns' => array(
  779. 'manufacturer_id' => 'contact_id',
  780. ),
  781. ),
  782. 'protocol' => array(
  783. 'table' => 'protocol',
  784. 'columns' => array(
  785. 'protocol_id' => 'protocol_id',
  786. ),
  787. ),
  788. ),
  789. );
  790. return $description;
  791. }
  792. /**
  793. * Implements hook_chado_schema_v1_2_arraydesignprop()
  794. * Purpose: To describe the structure of 'arraydesignprop' to tripal
  795. * @see tripal_core_chado_insert()
  796. * @see tripal_core_chado_update()
  797. * @see tripal_core_chado_select()
  798. *
  799. * @return
  800. * An array describing the 'arraydesignprop' table
  801. *
  802. * @ingroup tripal_chado_v1.2_schema_api
  803. *
  804. */
  805. function tripal_core_chado_schema_v1_2_arraydesignprop() {
  806. $description = array(
  807. 'description' => 'TODO: please describe this table!',
  808. 'fields' => array(
  809. 'arraydesignprop_id' => array(
  810. 'description' => 'TODO: please describe this field!',
  811. 'type' => 'serial',
  812. 'not null' => TRUE,
  813. ),
  814. 'arraydesign_id' => array(
  815. 'description' => 'TODO: please describe this field!',
  816. 'type' => 'int',
  817. 'not null' => TRUE,
  818. ),
  819. 'type_id' => array(
  820. 'description' => 'TODO: please describe this field!',
  821. 'type' => 'int',
  822. 'not null' => TRUE,
  823. ),
  824. 'value' => array(
  825. 'description' => 'TODO: please describe this field!',
  826. 'type' => 'text',
  827. 'not null' => FALSE,
  828. ),
  829. 'rank' => array(
  830. 'description' => 'TODO: please describe this field!',
  831. 'type' => 'int',
  832. 'not null' => TRUE,
  833. 'default' => 0,
  834. ),
  835. ),
  836. 'primary key' => array(
  837. 0 => 'arraydesignprop_id',
  838. ),
  839. 'unique keys' => array(
  840. 'arraydesignprop_c1' => array(
  841. 0 => 'arraydesign_id',
  842. 1 => 'type_id',
  843. 2 => 'rank',
  844. ),
  845. ),
  846. 'indexes' => array(
  847. 'arraydesignprop_idx1' => array(
  848. 0 => 'arraydesign_id',
  849. ),
  850. 'arraydesignprop_idx2' => array(
  851. 0 => 'type_id',
  852. ),
  853. ),
  854. 'foreign keys' => array(
  855. 'cvterm' => array(
  856. 'table' => 'cvterm',
  857. 'columns' => array(
  858. 'type_id' => 'cvterm_id',
  859. ),
  860. ),
  861. 'arraydesign' => array(
  862. 'table' => 'arraydesign',
  863. 'columns' => array(
  864. 'arraydesign_id' => 'arraydesign_id',
  865. ),
  866. ),
  867. ),
  868. );
  869. return $description;
  870. }
  871. /**
  872. * Implements hook_chado_schema_v1_2_assay()
  873. * Purpose: To describe the structure of 'assay' to tripal
  874. * @see tripal_core_chado_insert()
  875. * @see tripal_core_chado_update()
  876. * @see tripal_core_chado_select()
  877. *
  878. * @return
  879. * An array describing the 'assay' table
  880. *
  881. * @ingroup tripal_chado_v1.2_schema_api
  882. *
  883. */
  884. function tripal_core_chado_schema_v1_2_assay() {
  885. $description = array(
  886. 'description' => 'TODO: please describe this table!',
  887. 'fields' => array(
  888. 'assay_id' => array(
  889. 'description' => 'TODO: please describe this field!',
  890. 'type' => 'serial',
  891. 'not null' => TRUE,
  892. ),
  893. 'arraydesign_id' => array(
  894. 'description' => 'TODO: please describe this field!',
  895. 'type' => 'int',
  896. 'not null' => TRUE,
  897. ),
  898. 'protocol_id' => array(
  899. 'description' => 'TODO: please describe this field!',
  900. 'type' => 'int',
  901. 'not null' => FALSE,
  902. ),
  903. 'assaydate' => array(
  904. 'description' => 'TODO: please describe this field!',
  905. 'type' => 'datetime',
  906. 'not null' => FALSE,
  907. 'default' => 'ow(',
  908. ),
  909. 'arrayidentifier' => array(
  910. 'description' => 'TODO: please describe this field!',
  911. 'type' => 'text',
  912. 'not null' => FALSE,
  913. ),
  914. 'arraybatchidentifier' => array(
  915. 'description' => 'TODO: please describe this field!',
  916. 'type' => 'text',
  917. 'not null' => FALSE,
  918. ),
  919. 'operator_id' => array(
  920. 'description' => 'TODO: please describe this field!',
  921. 'type' => 'int',
  922. 'not null' => TRUE,
  923. ),
  924. 'dbxref_id' => array(
  925. 'description' => 'TODO: please describe this field!',
  926. 'type' => 'int',
  927. 'not null' => FALSE,
  928. ),
  929. 'name' => array(
  930. 'description' => 'TODO: please describe this field!',
  931. 'type' => 'text',
  932. 'not null' => FALSE,
  933. ),
  934. 'description' => array(
  935. 'description' => 'TODO: please describe this field!',
  936. 'type' => 'text',
  937. 'not null' => FALSE,
  938. ),
  939. ),
  940. 'primary key' => array(
  941. 0 => 'assay_id',
  942. ),
  943. 'unique keys' => array(
  944. 'assay_c1' => array(
  945. 0 => 'name',
  946. ),
  947. ),
  948. 'indexes' => array(
  949. 'assay_idx1' => array(
  950. 0 => 'arraydesign_id',
  951. ),
  952. 'assay_idx2' => array(
  953. 0 => 'protocol_id',
  954. ),
  955. 'assay_idx3' => array(
  956. 0 => 'operator_id',
  957. ),
  958. 'assay_idx4' => array(
  959. 0 => 'dbxref_id',
  960. ),
  961. ),
  962. 'foreign keys' => array(
  963. 'dbxref' => array(
  964. 'table' => 'dbxref',
  965. 'columns' => array(
  966. 'dbxref_id' => 'dbxref_id',
  967. ),
  968. ),
  969. 'contact' => array(
  970. 'table' => 'contact',
  971. 'columns' => array(
  972. 'operator_id' => 'contact_id',
  973. ),
  974. ),
  975. 'arraydesign' => array(
  976. 'table' => 'arraydesign',
  977. 'columns' => array(
  978. 'arraydesign_id' => 'arraydesign_id',
  979. ),
  980. ),
  981. 'protocol' => array(
  982. 'table' => 'protocol',
  983. 'columns' => array(
  984. 'protocol_id' => 'protocol_id',
  985. ),
  986. ),
  987. ),
  988. );
  989. return $description;
  990. }
  991. /**
  992. * Implements hook_chado_schema_v1_2_assay_biomaterial()
  993. * Purpose: To describe the structure of 'assay_biomaterial' to tripal
  994. * @see tripal_core_chado_insert()
  995. * @see tripal_core_chado_update()
  996. * @see tripal_core_chado_select()
  997. *
  998. * @return
  999. * An array describing the 'assay_biomaterial' table
  1000. *
  1001. * @ingroup tripal_chado_v1.2_schema_api
  1002. *
  1003. */
  1004. function tripal_core_chado_schema_v1_2_assay_biomaterial() {
  1005. $description = array(
  1006. 'description' => 'TODO: please describe this table!',
  1007. 'fields' => array(
  1008. 'assay_biomaterial_id' => array(
  1009. 'description' => 'TODO: please describe this field!',
  1010. 'type' => 'serial',
  1011. 'not null' => TRUE,
  1012. ),
  1013. 'assay_id' => array(
  1014. 'description' => 'TODO: please describe this field!',
  1015. 'type' => 'int',
  1016. 'not null' => TRUE,
  1017. ),
  1018. 'biomaterial_id' => array(
  1019. 'description' => 'TODO: please describe this field!',
  1020. 'type' => 'int',
  1021. 'not null' => TRUE,
  1022. ),
  1023. 'channel_id' => array(
  1024. 'description' => 'TODO: please describe this field!',
  1025. 'type' => 'int',
  1026. 'not null' => FALSE,
  1027. ),
  1028. 'rank' => array(
  1029. 'description' => 'TODO: please describe this field!',
  1030. 'type' => 'int',
  1031. 'not null' => TRUE,
  1032. 'default' => 0,
  1033. ),
  1034. ),
  1035. 'primary key' => array(
  1036. 0 => 'assay_biomaterial_id',
  1037. ),
  1038. 'unique keys' => array(
  1039. 'assay_biomaterial_c1' => array(
  1040. 0 => 'assay_id',
  1041. 1 => 'biomaterial_id',
  1042. 2 => 'channel_id',
  1043. 3 => 'rank',
  1044. ),
  1045. ),
  1046. 'indexes' => array(
  1047. 'assay_biomaterial_idx1' => array(
  1048. 0 => 'assay_id',
  1049. ),
  1050. 'assay_biomaterial_idx2' => array(
  1051. 0 => 'biomaterial_id',
  1052. ),
  1053. 'assay_biomaterial_idx3' => array(
  1054. 0 => 'channel_id',
  1055. ),
  1056. ),
  1057. 'foreign keys' => array(
  1058. 'assay' => array(
  1059. 'table' => 'assay',
  1060. 'columns' => array(
  1061. 'assay_id' => 'assay_id',
  1062. ),
  1063. ),
  1064. 'biomaterial' => array(
  1065. 'table' => 'biomaterial',
  1066. 'columns' => array(
  1067. 'biomaterial_id' => 'biomaterial_id',
  1068. ),
  1069. ),
  1070. 'channel' => array(
  1071. 'table' => 'channel',
  1072. 'columns' => array(
  1073. 'channel_id' => 'channel_id',
  1074. ),
  1075. ),
  1076. ),
  1077. );
  1078. return $description;
  1079. }
  1080. /**
  1081. * Implements hook_chado_schema_v1_2_assay_project()
  1082. * Purpose: To describe the structure of 'assay_project' to tripal
  1083. * @see tripal_core_chado_insert()
  1084. * @see tripal_core_chado_update()
  1085. * @see tripal_core_chado_select()
  1086. *
  1087. * @return
  1088. * An array describing the 'assay_project' table
  1089. *
  1090. * @ingroup tripal_chado_v1.2_schema_api
  1091. *
  1092. */
  1093. function tripal_core_chado_schema_v1_2_assay_project() {
  1094. $description = array(
  1095. 'description' => 'TODO: please describe this table!',
  1096. 'fields' => array(
  1097. 'assay_project_id' => array(
  1098. 'description' => 'TODO: please describe this field!',
  1099. 'type' => 'serial',
  1100. 'not null' => TRUE,
  1101. ),
  1102. 'assay_id' => array(
  1103. 'description' => 'TODO: please describe this field!',
  1104. 'type' => 'int',
  1105. 'not null' => TRUE,
  1106. ),
  1107. 'project_id' => array(
  1108. 'description' => 'TODO: please describe this field!',
  1109. 'type' => 'int',
  1110. 'not null' => TRUE,
  1111. ),
  1112. ),
  1113. 'primary key' => array(
  1114. 0 => 'assay_project_id',
  1115. ),
  1116. 'unique keys' => array(
  1117. 'assay_project_c1' => array(
  1118. 0 => 'assay_id',
  1119. 1 => 'project_id',
  1120. ),
  1121. ),
  1122. 'indexes' => array(
  1123. 'assay_project_idx1' => array(
  1124. 0 => 'assay_id',
  1125. ),
  1126. 'assay_project_idx2' => array(
  1127. 0 => 'project_id',
  1128. ),
  1129. ),
  1130. 'foreign keys' => array(
  1131. 'project' => array(
  1132. 'table' => 'project',
  1133. 'columns' => array(
  1134. 'project_id' => 'project_id',
  1135. ),
  1136. ),
  1137. 'assay' => array(
  1138. 'table' => 'assay',
  1139. 'columns' => array(
  1140. 'assay_id' => 'assay_id',
  1141. ),
  1142. ),
  1143. ),
  1144. );
  1145. return $description;
  1146. }
  1147. /**
  1148. * Implements hook_chado_schema_v1_2_assayprop()
  1149. * Purpose: To describe the structure of 'assayprop' to tripal
  1150. * @see tripal_core_chado_insert()
  1151. * @see tripal_core_chado_update()
  1152. * @see tripal_core_chado_select()
  1153. *
  1154. * @return
  1155. * An array describing the 'assayprop' table
  1156. *
  1157. * @ingroup tripal_chado_v1.2_schema_api
  1158. *
  1159. */
  1160. function tripal_core_chado_schema_v1_2_assayprop() {
  1161. $description = array(
  1162. 'description' => 'TODO: please describe this table!',
  1163. 'fields' => array(
  1164. 'assayprop_id' => array(
  1165. 'description' => 'TODO: please describe this field!',
  1166. 'type' => 'serial',
  1167. 'not null' => TRUE,
  1168. ),
  1169. 'assay_id' => array(
  1170. 'description' => 'TODO: please describe this field!',
  1171. 'type' => 'int',
  1172. 'not null' => TRUE,
  1173. ),
  1174. 'type_id' => array(
  1175. 'description' => 'TODO: please describe this field!',
  1176. 'type' => 'int',
  1177. 'not null' => TRUE,
  1178. ),
  1179. 'value' => array(
  1180. 'description' => 'TODO: please describe this field!',
  1181. 'type' => 'text',
  1182. 'not null' => FALSE,
  1183. ),
  1184. 'rank' => array(
  1185. 'description' => 'TODO: please describe this field!',
  1186. 'type' => 'int',
  1187. 'not null' => TRUE,
  1188. 'default' => 0,
  1189. ),
  1190. ),
  1191. 'primary key' => array(
  1192. 0 => 'assayprop_id',
  1193. ),
  1194. 'unique keys' => array(
  1195. 'assayprop_c1' => array(
  1196. 0 => 'assay_id',
  1197. 1 => 'type_id',
  1198. 2 => 'rank',
  1199. ),
  1200. ),
  1201. 'indexes' => array(
  1202. 'assayprop_idx1' => array(
  1203. 0 => 'assay_id',
  1204. ),
  1205. 'assayprop_idx2' => array(
  1206. 0 => 'type_id',
  1207. ),
  1208. ),
  1209. 'foreign keys' => array(
  1210. 'cvterm' => array(
  1211. 'table' => 'cvterm',
  1212. 'columns' => array(
  1213. 'type_id' => 'cvterm_id',
  1214. ),
  1215. ),
  1216. 'assay' => array(
  1217. 'table' => 'assay',
  1218. 'columns' => array(
  1219. 'assay_id' => 'assay_id',
  1220. ),
  1221. ),
  1222. ),
  1223. );
  1224. return $description;
  1225. }
  1226. /**
  1227. * Implements hook_chado_schema_v1_2_biomaterial()
  1228. * Purpose: To describe the structure of 'biomaterial' to tripal
  1229. * @see tripal_core_chado_insert()
  1230. * @see tripal_core_chado_update()
  1231. * @see tripal_core_chado_select()
  1232. *
  1233. * @return
  1234. * An array describing the 'biomaterial' table
  1235. *
  1236. * @ingroup tripal_chado_v1.2_schema_api
  1237. *
  1238. */
  1239. function tripal_core_chado_schema_v1_2_biomaterial() {
  1240. $description = array(
  1241. 'description' => 'TODO: please describe this table!',
  1242. 'fields' => array(
  1243. 'biomaterial_id' => array(
  1244. 'description' => 'TODO: please describe this field!',
  1245. 'type' => 'serial',
  1246. 'not null' => TRUE,
  1247. ),
  1248. 'taxon_id' => array(
  1249. 'description' => 'TODO: please describe this field!',
  1250. 'type' => 'int',
  1251. 'not null' => FALSE,
  1252. ),
  1253. 'biosourceprovider_id' => array(
  1254. 'description' => 'TODO: please describe this field!',
  1255. 'type' => 'int',
  1256. 'not null' => FALSE,
  1257. ),
  1258. 'dbxref_id' => array(
  1259. 'description' => 'TODO: please describe this field!',
  1260. 'type' => 'int',
  1261. 'not null' => FALSE,
  1262. ),
  1263. 'name' => array(
  1264. 'description' => 'TODO: please describe this field!',
  1265. 'type' => 'text',
  1266. 'not null' => FALSE,
  1267. ),
  1268. 'description' => array(
  1269. 'description' => 'TODO: please describe this field!',
  1270. 'type' => 'text',
  1271. 'not null' => FALSE,
  1272. ),
  1273. ),
  1274. 'primary key' => array(
  1275. 0 => 'biomaterial_id',
  1276. ),
  1277. 'unique keys' => array(
  1278. 'biomaterial_c1' => array(
  1279. 0 => 'name',
  1280. ),
  1281. ),
  1282. 'indexes' => array(
  1283. 'biomaterial_idx1' => array(
  1284. 0 => 'taxon_id',
  1285. ),
  1286. 'biomaterial_idx2' => array(
  1287. 0 => 'biosourceprovider_id',
  1288. ),
  1289. 'biomaterial_idx3' => array(
  1290. 0 => 'dbxref_id',
  1291. ),
  1292. ),
  1293. 'foreign keys' => array(
  1294. 'organism' => array(
  1295. 'table' => 'organism',
  1296. 'columns' => array(
  1297. 'taxon_id' => 'organism_id',
  1298. ),
  1299. ),
  1300. 'dbxref' => array(
  1301. 'table' => 'dbxref',
  1302. 'columns' => array(
  1303. 'dbxref_id' => 'dbxref_id',
  1304. ),
  1305. ),
  1306. 'contact' => array(
  1307. 'table' => 'contact',
  1308. 'columns' => array(
  1309. 'biosourceprovider_id' => 'contact_id',
  1310. ),
  1311. ),
  1312. ),
  1313. );
  1314. return $description;
  1315. }
  1316. /**
  1317. * Implements hook_chado_schema_v1_2_biomaterial_dbxref()
  1318. * Purpose: To describe the structure of 'biomaterial_dbxref' to tripal
  1319. * @see tripal_core_chado_insert()
  1320. * @see tripal_core_chado_update()
  1321. * @see tripal_core_chado_select()
  1322. *
  1323. * @return
  1324. * An array describing the 'biomaterial_dbxref' table
  1325. *
  1326. * @ingroup tripal_chado_v1.2_schema_api
  1327. *
  1328. */
  1329. function tripal_core_chado_schema_v1_2_biomaterial_dbxref() {
  1330. $description = array(
  1331. 'description' => 'TODO: please describe this table!',
  1332. 'fields' => array(
  1333. 'biomaterial_dbxref_id' => array(
  1334. 'description' => 'TODO: please describe this field!',
  1335. 'type' => 'serial',
  1336. 'not null' => TRUE,
  1337. ),
  1338. 'biomaterial_id' => array(
  1339. 'description' => 'TODO: please describe this field!',
  1340. 'type' => 'int',
  1341. 'not null' => TRUE,
  1342. ),
  1343. 'dbxref_id' => array(
  1344. 'description' => 'TODO: please describe this field!',
  1345. 'type' => 'int',
  1346. 'not null' => TRUE,
  1347. ),
  1348. ),
  1349. 'primary key' => array(
  1350. 0 => 'biomaterial_dbxref_id',
  1351. ),
  1352. 'unique keys' => array(
  1353. 'biomaterial_dbxref_c1' => array(
  1354. 0 => 'biomaterial_id',
  1355. 1 => 'dbxref_id',
  1356. ),
  1357. ),
  1358. 'indexes' => array(
  1359. 'biomaterial_dbxref_idx1' => array(
  1360. 0 => 'biomaterial_id',
  1361. ),
  1362. 'biomaterial_dbxref_idx2' => array(
  1363. 0 => 'dbxref_id',
  1364. ),
  1365. ),
  1366. 'foreign keys' => array(
  1367. 'dbxref' => array(
  1368. 'table' => 'dbxref',
  1369. 'columns' => array(
  1370. 'dbxref_id' => 'dbxref_id',
  1371. ),
  1372. ),
  1373. 'biomaterial' => array(
  1374. 'table' => 'biomaterial',
  1375. 'columns' => array(
  1376. 'biomaterial_id' => 'biomaterial_id',
  1377. ),
  1378. ),
  1379. ),
  1380. );
  1381. return $description;
  1382. }
  1383. /**
  1384. * Implements hook_chado_schema_v1_2_biomaterial_relationship()
  1385. * Purpose: To describe the structure of 'biomaterial_relationship' to tripal
  1386. * @see tripal_core_chado_insert()
  1387. * @see tripal_core_chado_update()
  1388. * @see tripal_core_chado_select()
  1389. *
  1390. * @return
  1391. * An array describing the 'biomaterial_relationship' table
  1392. *
  1393. * @ingroup tripal_chado_v1.2_schema_api
  1394. *
  1395. */
  1396. function tripal_core_chado_schema_v1_2_biomaterial_relationship() {
  1397. $description = array(
  1398. 'description' => 'TODO: please describe this table!',
  1399. 'fields' => array(
  1400. 'biomaterial_relationship_id' => array(
  1401. 'description' => 'TODO: please describe this field!',
  1402. 'type' => 'serial',
  1403. 'not null' => TRUE,
  1404. ),
  1405. 'subject_id' => array(
  1406. 'description' => 'TODO: please describe this field!',
  1407. 'type' => 'int',
  1408. 'not null' => TRUE,
  1409. ),
  1410. 'type_id' => array(
  1411. 'description' => 'TODO: please describe this field!',
  1412. 'type' => 'int',
  1413. 'not null' => TRUE,
  1414. ),
  1415. 'object_id' => array(
  1416. 'description' => 'TODO: please describe this field!',
  1417. 'type' => 'int',
  1418. 'not null' => TRUE,
  1419. ),
  1420. ),
  1421. 'primary key' => array(
  1422. 0 => 'biomaterial_relationship_id',
  1423. ),
  1424. 'unique keys' => array(
  1425. 'biomaterial_relationship_c1' => array(
  1426. 0 => 'subject_id',
  1427. 1 => 'object_id',
  1428. 2 => 'type_id',
  1429. ),
  1430. ),
  1431. 'indexes' => array(
  1432. 'biomaterial_relationship_idx1' => array(
  1433. 0 => 'subject_id',
  1434. ),
  1435. 'biomaterial_relationship_idx2' => array(
  1436. 0 => 'object_id',
  1437. ),
  1438. 'biomaterial_relationship_idx3' => array(
  1439. 0 => 'type_id',
  1440. ),
  1441. ),
  1442. 'foreign keys' => array(
  1443. 'cvterm' => array(
  1444. 'table' => 'cvterm',
  1445. 'columns' => array(
  1446. 'type_id' => 'cvterm_id',
  1447. ),
  1448. ),
  1449. 'biomaterial' => array(
  1450. 'table' => 'biomaterial',
  1451. 'columns' => array(
  1452. 'subject_id' => 'biomaterial_id',
  1453. 'object_id' => 'biomaterial_id',
  1454. ),
  1455. ),
  1456. ),
  1457. );
  1458. return $description;
  1459. }
  1460. /**
  1461. * Implements hook_chado_schema_v1_2_biomaterial_treatment()
  1462. * Purpose: To describe the structure of 'biomaterial_treatment' to tripal
  1463. * @see tripal_core_chado_insert()
  1464. * @see tripal_core_chado_update()
  1465. * @see tripal_core_chado_select()
  1466. *
  1467. * @return
  1468. * An array describing the 'biomaterial_treatment' table
  1469. *
  1470. * @ingroup tripal_chado_v1.2_schema_api
  1471. *
  1472. */
  1473. function tripal_core_chado_schema_v1_2_biomaterial_treatment() {
  1474. $description = array(
  1475. 'description' => 'TODO: please describe this table!',
  1476. 'fields' => array(
  1477. 'biomaterial_treatment_id' => array(
  1478. 'description' => 'TODO: please describe this field!',
  1479. 'type' => 'serial',
  1480. 'not null' => TRUE,
  1481. ),
  1482. 'biomaterial_id' => array(
  1483. 'description' => 'TODO: please describe this field!',
  1484. 'type' => 'int',
  1485. 'not null' => TRUE,
  1486. ),
  1487. 'treatment_id' => array(
  1488. 'description' => 'TODO: please describe this field!',
  1489. 'type' => 'int',
  1490. 'not null' => TRUE,
  1491. ),
  1492. 'unittype_id' => array(
  1493. 'description' => 'TODO: please describe this field!',
  1494. 'type' => 'int',
  1495. 'not null' => FALSE,
  1496. ),
  1497. 'value' => array(
  1498. 'description' => 'TODO: please describe this field!',
  1499. 'type' => 'float',
  1500. 'not null' => FALSE,
  1501. ),
  1502. 'rank' => array(
  1503. 'description' => 'TODO: please describe this field!',
  1504. 'type' => 'int',
  1505. 'not null' => TRUE,
  1506. 'default' => 0,
  1507. ),
  1508. ),
  1509. 'primary key' => array(
  1510. 0 => 'biomaterial_treatment_id',
  1511. ),
  1512. 'unique keys' => array(
  1513. 'biomaterial_treatment_c1' => array(
  1514. 0 => 'biomaterial_id',
  1515. 1 => 'treatment_id',
  1516. ),
  1517. ),
  1518. 'indexes' => array(
  1519. 'biomaterial_treatment_idx1' => array(
  1520. 0 => 'biomaterial_id',
  1521. ),
  1522. 'biomaterial_treatment_idx2' => array(
  1523. 0 => 'treatment_id',
  1524. ),
  1525. 'biomaterial_treatment_idx3' => array(
  1526. 0 => 'unittype_id',
  1527. ),
  1528. ),
  1529. 'foreign keys' => array(
  1530. 'cvterm' => array(
  1531. 'table' => 'cvterm',
  1532. 'columns' => array(
  1533. 'unittype_id' => 'cvterm_id',
  1534. ),
  1535. ),
  1536. 'biomaterial' => array(
  1537. 'table' => 'biomaterial',
  1538. 'columns' => array(
  1539. 'biomaterial_id' => 'biomaterial_id',
  1540. ),
  1541. ),
  1542. 'treatment' => array(
  1543. 'table' => 'treatment',
  1544. 'columns' => array(
  1545. 'treatment_id' => 'treatment_id',
  1546. ),
  1547. ),
  1548. ),
  1549. );
  1550. return $description;
  1551. }
  1552. /**
  1553. * Implements hook_chado_schema_v1_2_biomaterialprop()
  1554. * Purpose: To describe the structure of 'biomaterialprop' to tripal
  1555. * @see tripal_core_chado_insert()
  1556. * @see tripal_core_chado_update()
  1557. * @see tripal_core_chado_select()
  1558. *
  1559. * @return
  1560. * An array describing the 'biomaterialprop' table
  1561. *
  1562. * @ingroup tripal_chado_v1.2_schema_api
  1563. *
  1564. */
  1565. function tripal_core_chado_schema_v1_2_biomaterialprop() {
  1566. $description = array(
  1567. 'description' => 'TODO: please describe this table!',
  1568. 'fields' => array(
  1569. 'biomaterialprop_id' => array(
  1570. 'description' => 'TODO: please describe this field!',
  1571. 'type' => 'serial',
  1572. 'not null' => TRUE,
  1573. ),
  1574. 'biomaterial_id' => array(
  1575. 'description' => 'TODO: please describe this field!',
  1576. 'type' => 'int',
  1577. 'not null' => TRUE,
  1578. ),
  1579. 'type_id' => array(
  1580. 'description' => 'TODO: please describe this field!',
  1581. 'type' => 'int',
  1582. 'not null' => TRUE,
  1583. ),
  1584. 'value' => array(
  1585. 'description' => 'TODO: please describe this field!',
  1586. 'type' => 'text',
  1587. 'not null' => FALSE,
  1588. ),
  1589. 'rank' => array(
  1590. 'description' => 'TODO: please describe this field!',
  1591. 'type' => 'int',
  1592. 'not null' => TRUE,
  1593. 'default' => 0,
  1594. ),
  1595. ),
  1596. 'primary key' => array(
  1597. 0 => 'biomaterialprop_id',
  1598. ),
  1599. 'unique keys' => array(
  1600. 'biomaterialprop_c1' => array(
  1601. 0 => 'biomaterial_id',
  1602. 1 => 'type_id',
  1603. 2 => 'rank',
  1604. ),
  1605. ),
  1606. 'indexes' => array(
  1607. 'biomaterialprop_idx1' => array(
  1608. 0 => 'biomaterial_id',
  1609. ),
  1610. 'biomaterialprop_idx2' => array(
  1611. 0 => 'type_id',
  1612. ),
  1613. ),
  1614. 'foreign keys' => array(
  1615. 'cvterm' => array(
  1616. 'table' => 'cvterm',
  1617. 'columns' => array(
  1618. 'type_id' => 'cvterm_id',
  1619. ),
  1620. ),
  1621. 'biomaterial' => array(
  1622. 'table' => 'biomaterial',
  1623. 'columns' => array(
  1624. 'biomaterial_id' => 'biomaterial_id',
  1625. ),
  1626. ),
  1627. ),
  1628. );
  1629. return $description;
  1630. }
  1631. /**
  1632. * Implements hook_chado_schema_v1_2_cell_line()
  1633. * Purpose: To describe the structure of 'cell_line' to tripal
  1634. * @see tripal_core_chado_insert()
  1635. * @see tripal_core_chado_update()
  1636. * @see tripal_core_chado_select()
  1637. *
  1638. * @return
  1639. * An array describing the 'cell_line' table
  1640. *
  1641. * @ingroup tripal_chado_v1.2_schema_api
  1642. *
  1643. */
  1644. function tripal_core_chado_schema_v1_2_cell_line() {
  1645. $description = array(
  1646. 'description' => 'TODO: please describe this table!',
  1647. 'fields' => array(
  1648. 'cell_line_id' => array(
  1649. 'description' => 'TODO: please describe this field!',
  1650. 'type' => 'serial',
  1651. 'not null' => TRUE,
  1652. ),
  1653. 'name' => array(
  1654. 'description' => 'TODO: please describe this field!',
  1655. 'type' => 'varchar',
  1656. 'length' => '255',
  1657. 'not null' => FALSE,
  1658. ),
  1659. 'uniquename' => array(
  1660. 'description' => 'TODO: please describe this field!',
  1661. 'type' => 'varchar',
  1662. 'length' => '255',
  1663. 'not null' => TRUE,
  1664. ),
  1665. 'organism_id' => array(
  1666. 'description' => 'TODO: please describe this field!',
  1667. 'type' => 'int',
  1668. 'not null' => TRUE,
  1669. ),
  1670. 'timeaccessioned' => array(
  1671. 'description' => 'TODO: please describe this field!',
  1672. 'type' => 'datetime',
  1673. 'not null' => TRUE,
  1674. 'default' => 'ow(',
  1675. ),
  1676. 'timelastmodified' => array(
  1677. 'description' => 'TODO: please describe this field!',
  1678. 'type' => 'datetime',
  1679. 'not null' => TRUE,
  1680. 'default' => 'ow(',
  1681. ),
  1682. ),
  1683. 'primary key' => array(
  1684. 0 => 'cell_line_id',
  1685. ),
  1686. 'unique keys' => array(
  1687. 'cell_line_c1' => array(
  1688. 0 => 'uniquename',
  1689. 1 => 'organism_id',
  1690. ),
  1691. ),
  1692. 'foreign keys' => array(
  1693. 'organism' => array(
  1694. 'table' => 'organism',
  1695. 'columns' => array(
  1696. 'organism_id' => 'organism_id',
  1697. ),
  1698. ),
  1699. ),
  1700. );
  1701. return $description;
  1702. }
  1703. /**
  1704. * Implements hook_chado_schema_v1_2_cell_line_cvterm()
  1705. * Purpose: To describe the structure of 'cell_line_cvterm' to tripal
  1706. * @see tripal_core_chado_insert()
  1707. * @see tripal_core_chado_update()
  1708. * @see tripal_core_chado_select()
  1709. *
  1710. * @return
  1711. * An array describing the 'cell_line_cvterm' table
  1712. *
  1713. * @ingroup tripal_chado_v1.2_schema_api
  1714. *
  1715. */
  1716. function tripal_core_chado_schema_v1_2_cell_line_cvterm() {
  1717. $description = array(
  1718. 'description' => 'TODO: please describe this table!',
  1719. 'fields' => array(
  1720. 'cell_line_cvterm_id' => array(
  1721. 'description' => 'TODO: please describe this field!',
  1722. 'type' => 'serial',
  1723. 'not null' => TRUE,
  1724. ),
  1725. 'cell_line_id' => array(
  1726. 'description' => 'TODO: please describe this field!',
  1727. 'type' => 'int',
  1728. 'not null' => TRUE,
  1729. ),
  1730. 'cvterm_id' => array(
  1731. 'description' => 'TODO: please describe this field!',
  1732. 'type' => 'int',
  1733. 'not null' => TRUE,
  1734. ),
  1735. 'pub_id' => array(
  1736. 'description' => 'TODO: please describe this field!',
  1737. 'type' => 'int',
  1738. 'not null' => TRUE,
  1739. ),
  1740. 'rank' => array(
  1741. 'description' => 'TODO: please describe this field!',
  1742. 'type' => 'int',
  1743. 'not null' => TRUE,
  1744. 'default' => 0,
  1745. ),
  1746. ),
  1747. 'primary key' => array(
  1748. 0 => 'cell_line_cvterm_id',
  1749. ),
  1750. 'unique keys' => array(
  1751. 'cell_line_cvterm_c1' => array(
  1752. 0 => 'cell_line_id',
  1753. 1 => 'cvterm_id',
  1754. 2 => 'pub_id',
  1755. 3 => 'rank',
  1756. ),
  1757. ),
  1758. 'foreign keys' => array(
  1759. 'cvterm' => array(
  1760. 'table' => 'cvterm',
  1761. 'columns' => array(
  1762. 'cvterm_id' => 'cvterm_id',
  1763. ),
  1764. ),
  1765. 'pub' => array(
  1766. 'table' => 'pub',
  1767. 'columns' => array(
  1768. 'pub_id' => 'pub_id',
  1769. ),
  1770. ),
  1771. 'cell_line' => array(
  1772. 'table' => 'cell_line',
  1773. 'columns' => array(
  1774. 'cell_line_id' => 'cell_line_id',
  1775. ),
  1776. ),
  1777. ),
  1778. );
  1779. return $description;
  1780. }
  1781. /**
  1782. * Implements hook_chado_schema_v1_2_cell_line_cvtermprop()
  1783. * Purpose: To describe the structure of 'cell_line_cvtermprop' to tripal
  1784. * @see tripal_core_chado_insert()
  1785. * @see tripal_core_chado_update()
  1786. * @see tripal_core_chado_select()
  1787. *
  1788. * @return
  1789. * An array describing the 'cell_line_cvtermprop' table
  1790. *
  1791. * @ingroup tripal_chado_v1.2_schema_api
  1792. *
  1793. */
  1794. function tripal_core_chado_schema_v1_2_cell_line_cvtermprop() {
  1795. $description = array(
  1796. 'description' => 'TODO: please describe this table!',
  1797. 'fields' => array(
  1798. 'cell_line_cvtermprop_id' => array(
  1799. 'description' => 'TODO: please describe this field!',
  1800. 'type' => 'serial',
  1801. 'not null' => TRUE,
  1802. ),
  1803. 'cell_line_cvterm_id' => array(
  1804. 'description' => 'TODO: please describe this field!',
  1805. 'type' => 'int',
  1806. 'not null' => TRUE,
  1807. ),
  1808. 'type_id' => array(
  1809. 'description' => 'TODO: please describe this field!',
  1810. 'type' => 'int',
  1811. 'not null' => TRUE,
  1812. ),
  1813. 'value' => array(
  1814. 'description' => 'TODO: please describe this field!',
  1815. 'type' => 'text',
  1816. 'not null' => FALSE,
  1817. ),
  1818. 'rank' => array(
  1819. 'description' => 'TODO: please describe this field!',
  1820. 'type' => 'int',
  1821. 'not null' => TRUE,
  1822. 'default' => 0,
  1823. ),
  1824. ),
  1825. 'primary key' => array(
  1826. 0 => 'cell_line_cvtermprop_id',
  1827. ),
  1828. 'unique keys' => array(
  1829. 'cell_line_cvtermprop_c1' => array(
  1830. 0 => 'cell_line_cvterm_id',
  1831. 1 => 'type_id',
  1832. 2 => 'rank',
  1833. ),
  1834. ),
  1835. 'foreign keys' => array(
  1836. 'cvterm' => array(
  1837. 'table' => 'cvterm',
  1838. 'columns' => array(
  1839. 'type_id' => 'cvterm_id',
  1840. ),
  1841. ),
  1842. 'cell_line_cvterm' => array(
  1843. 'table' => 'cell_line_cvterm',
  1844. 'columns' => array(
  1845. 'cell_line_cvterm_id' => 'cell_line_cvterm_id',
  1846. ),
  1847. ),
  1848. ),
  1849. );
  1850. return $description;
  1851. }
  1852. /**
  1853. * Implements hook_chado_schema_v1_2_cell_line_dbxref()
  1854. * Purpose: To describe the structure of 'cell_line_dbxref' to tripal
  1855. * @see tripal_core_chado_insert()
  1856. * @see tripal_core_chado_update()
  1857. * @see tripal_core_chado_select()
  1858. *
  1859. * @return
  1860. * An array describing the 'cell_line_dbxref' table
  1861. *
  1862. * @ingroup tripal_chado_v1.2_schema_api
  1863. *
  1864. */
  1865. function tripal_core_chado_schema_v1_2_cell_line_dbxref() {
  1866. $description = array(
  1867. 'description' => 'TODO: please describe this table!',
  1868. 'fields' => array(
  1869. 'cell_line_dbxref_id' => array(
  1870. 'description' => 'TODO: please describe this field!',
  1871. 'type' => 'serial',
  1872. 'not null' => TRUE,
  1873. ),
  1874. 'cell_line_id' => array(
  1875. 'description' => 'TODO: please describe this field!',
  1876. 'type' => 'int',
  1877. 'not null' => TRUE,
  1878. ),
  1879. 'dbxref_id' => array(
  1880. 'description' => 'TODO: please describe this field!',
  1881. 'type' => 'int',
  1882. 'not null' => TRUE,
  1883. ),
  1884. 'is_current' => array(
  1885. 'description' => 'TODO: please describe this field!',
  1886. 'type' => 'boolean',
  1887. 'not null' => TRUE,
  1888. 'default' => 'ru',
  1889. ),
  1890. ),
  1891. 'primary key' => array(
  1892. 0 => 'cell_line_dbxref_id',
  1893. ),
  1894. 'unique keys' => array(
  1895. 'cell_line_dbxref_c1' => array(
  1896. 0 => 'cell_line_id',
  1897. 1 => 'dbxref_id',
  1898. ),
  1899. ),
  1900. 'foreign keys' => array(
  1901. 'dbxref' => array(
  1902. 'table' => 'dbxref',
  1903. 'columns' => array(
  1904. 'dbxref_id' => 'dbxref_id',
  1905. ),
  1906. ),
  1907. 'cell_line' => array(
  1908. 'table' => 'cell_line',
  1909. 'columns' => array(
  1910. 'cell_line_id' => 'cell_line_id',
  1911. ),
  1912. ),
  1913. ),
  1914. );
  1915. return $description;
  1916. }
  1917. /**
  1918. * Implements hook_chado_schema_v1_2_cell_line_feature()
  1919. * Purpose: To describe the structure of 'cell_line_feature' to tripal
  1920. * @see tripal_core_chado_insert()
  1921. * @see tripal_core_chado_update()
  1922. * @see tripal_core_chado_select()
  1923. *
  1924. * @return
  1925. * An array describing the 'cell_line_feature' table
  1926. *
  1927. * @ingroup tripal_chado_v1.2_schema_api
  1928. *
  1929. */
  1930. function tripal_core_chado_schema_v1_2_cell_line_feature() {
  1931. $description = array(
  1932. 'description' => 'TODO: please describe this table!',
  1933. 'fields' => array(
  1934. 'cell_line_feature_id' => array(
  1935. 'description' => 'TODO: please describe this field!',
  1936. 'type' => 'serial',
  1937. 'not null' => TRUE,
  1938. ),
  1939. 'cell_line_id' => array(
  1940. 'description' => 'TODO: please describe this field!',
  1941. 'type' => 'int',
  1942. 'not null' => TRUE,
  1943. ),
  1944. 'feature_id' => array(
  1945. 'description' => 'TODO: please describe this field!',
  1946. 'type' => 'int',
  1947. 'not null' => TRUE,
  1948. ),
  1949. 'pub_id' => array(
  1950. 'description' => 'TODO: please describe this field!',
  1951. 'type' => 'int',
  1952. 'not null' => TRUE,
  1953. ),
  1954. ),
  1955. 'primary key' => array(
  1956. 0 => 'cell_line_feature_id',
  1957. ),
  1958. 'unique keys' => array(
  1959. 'cell_line_feature_c1' => array(
  1960. 0 => 'cell_line_id',
  1961. 1 => 'feature_id',
  1962. 2 => 'pub_id',
  1963. ),
  1964. ),
  1965. 'foreign keys' => array(
  1966. 'pub' => array(
  1967. 'table' => 'pub',
  1968. 'columns' => array(
  1969. 'pub_id' => 'pub_id',
  1970. ),
  1971. ),
  1972. 'feature' => array(
  1973. 'table' => 'feature',
  1974. 'columns' => array(
  1975. 'feature_id' => 'feature_id',
  1976. ),
  1977. ),
  1978. 'cell_line' => array(
  1979. 'table' => 'cell_line',
  1980. 'columns' => array(
  1981. 'cell_line_id' => 'cell_line_id',
  1982. ),
  1983. ),
  1984. ),
  1985. );
  1986. return $description;
  1987. }
  1988. /**
  1989. * Implements hook_chado_schema_v1_2_cell_line_library()
  1990. * Purpose: To describe the structure of 'cell_line_library' to tripal
  1991. * @see tripal_core_chado_insert()
  1992. * @see tripal_core_chado_update()
  1993. * @see tripal_core_chado_select()
  1994. *
  1995. * @return
  1996. * An array describing the 'cell_line_library' table
  1997. *
  1998. * @ingroup tripal_chado_v1.2_schema_api
  1999. *
  2000. */
  2001. function tripal_core_chado_schema_v1_2_cell_line_library() {
  2002. $description = array(
  2003. 'description' => 'TODO: please describe this table!',
  2004. 'fields' => array(
  2005. 'cell_line_library_id' => array(
  2006. 'description' => 'TODO: please describe this field!',
  2007. 'type' => 'serial',
  2008. 'not null' => TRUE,
  2009. ),
  2010. 'cell_line_id' => array(
  2011. 'description' => 'TODO: please describe this field!',
  2012. 'type' => 'int',
  2013. 'not null' => TRUE,
  2014. ),
  2015. 'library_id' => array(
  2016. 'description' => 'TODO: please describe this field!',
  2017. 'type' => 'int',
  2018. 'not null' => TRUE,
  2019. ),
  2020. 'pub_id' => array(
  2021. 'description' => 'TODO: please describe this field!',
  2022. 'type' => 'int',
  2023. 'not null' => TRUE,
  2024. ),
  2025. ),
  2026. 'primary key' => array(
  2027. 0 => 'cell_line_library_id',
  2028. ),
  2029. 'unique keys' => array(
  2030. 'cell_line_library_c1' => array(
  2031. 0 => 'cell_line_id',
  2032. 1 => 'library_id',
  2033. 2 => 'pub_id',
  2034. ),
  2035. ),
  2036. 'foreign keys' => array(
  2037. 'pub' => array(
  2038. 'table' => 'pub',
  2039. 'columns' => array(
  2040. 'pub_id' => 'pub_id',
  2041. ),
  2042. ),
  2043. 'library' => array(
  2044. 'table' => 'library',
  2045. 'columns' => array(
  2046. 'library_id' => 'library_id',
  2047. ),
  2048. ),
  2049. 'cell_line' => array(
  2050. 'table' => 'cell_line',
  2051. 'columns' => array(
  2052. 'cell_line_id' => 'cell_line_id',
  2053. ),
  2054. ),
  2055. ),
  2056. );
  2057. return $description;
  2058. }
  2059. /**
  2060. * Implements hook_chado_schema_v1_2_cell_line_pub()
  2061. * Purpose: To describe the structure of 'cell_line_pub' to tripal
  2062. * @see tripal_core_chado_insert()
  2063. * @see tripal_core_chado_update()
  2064. * @see tripal_core_chado_select()
  2065. *
  2066. * @return
  2067. * An array describing the 'cell_line_pub' table
  2068. *
  2069. * @ingroup tripal_chado_v1.2_schema_api
  2070. *
  2071. */
  2072. function tripal_core_chado_schema_v1_2_cell_line_pub() {
  2073. $description = array(
  2074. 'description' => 'TODO: please describe this table!',
  2075. 'fields' => array(
  2076. 'cell_line_pub_id' => array(
  2077. 'description' => 'TODO: please describe this field!',
  2078. 'type' => 'serial',
  2079. 'not null' => TRUE,
  2080. ),
  2081. 'cell_line_id' => array(
  2082. 'description' => 'TODO: please describe this field!',
  2083. 'type' => 'int',
  2084. 'not null' => TRUE,
  2085. ),
  2086. 'pub_id' => array(
  2087. 'description' => 'TODO: please describe this field!',
  2088. 'type' => 'int',
  2089. 'not null' => TRUE,
  2090. ),
  2091. ),
  2092. 'primary key' => array(
  2093. 0 => 'cell_line_pub_id',
  2094. ),
  2095. 'unique keys' => array(
  2096. 'cell_line_pub_c1' => array(
  2097. 0 => 'cell_line_id',
  2098. 1 => 'pub_id',
  2099. ),
  2100. ),
  2101. 'foreign keys' => array(
  2102. 'pub' => array(
  2103. 'table' => 'pub',
  2104. 'columns' => array(
  2105. 'pub_id' => 'pub_id',
  2106. ),
  2107. ),
  2108. 'cell_line' => array(
  2109. 'table' => 'cell_line',
  2110. 'columns' => array(
  2111. 'cell_line_id' => 'cell_line_id',
  2112. ),
  2113. ),
  2114. ),
  2115. );
  2116. return $description;
  2117. }
  2118. /**
  2119. * Implements hook_chado_schema_v1_2_cell_line_relationship()
  2120. * Purpose: To describe the structure of 'cell_line_relationship' to tripal
  2121. * @see tripal_core_chado_insert()
  2122. * @see tripal_core_chado_update()
  2123. * @see tripal_core_chado_select()
  2124. *
  2125. * @return
  2126. * An array describing the 'cell_line_relationship' table
  2127. *
  2128. * @ingroup tripal_chado_v1.2_schema_api
  2129. *
  2130. */
  2131. function tripal_core_chado_schema_v1_2_cell_line_relationship() {
  2132. $description = array(
  2133. 'description' => 'TODO: please describe this table!',
  2134. 'fields' => array(
  2135. 'cell_line_relationship_id' => array(
  2136. 'description' => 'TODO: please describe this field!',
  2137. 'type' => 'serial',
  2138. 'not null' => TRUE,
  2139. ),
  2140. 'subject_id' => array(
  2141. 'description' => 'TODO: please describe this field!',
  2142. 'type' => 'int',
  2143. 'not null' => TRUE,
  2144. ),
  2145. 'object_id' => array(
  2146. 'description' => 'TODO: please describe this field!',
  2147. 'type' => 'int',
  2148. 'not null' => TRUE,
  2149. ),
  2150. 'type_id' => array(
  2151. 'description' => 'TODO: please describe this field!',
  2152. 'type' => 'int',
  2153. 'not null' => TRUE,
  2154. ),
  2155. ),
  2156. 'primary key' => array(
  2157. 0 => 'cell_line_relationship_id',
  2158. ),
  2159. 'unique keys' => array(
  2160. 'cell_line_relationship_c1' => array(
  2161. 0 => 'subject_id',
  2162. 1 => 'object_id',
  2163. 2 => 'type_id',
  2164. ),
  2165. ),
  2166. 'foreign keys' => array(
  2167. 'cvterm' => array(
  2168. 'table' => 'cvterm',
  2169. 'columns' => array(
  2170. 'type_id' => 'cvterm_id',
  2171. ),
  2172. ),
  2173. 'cell_line' => array(
  2174. 'table' => 'cell_line',
  2175. 'columns' => array(
  2176. 'subject_id' => 'cell_line_id',
  2177. 'object_id' => 'cell_line_id',
  2178. ),
  2179. ),
  2180. ),
  2181. );
  2182. return $description;
  2183. }
  2184. /**
  2185. * Implements hook_chado_schema_v1_2_cell_line_synonym()
  2186. * Purpose: To describe the structure of 'cell_line_synonym' to tripal
  2187. * @see tripal_core_chado_insert()
  2188. * @see tripal_core_chado_update()
  2189. * @see tripal_core_chado_select()
  2190. *
  2191. * @return
  2192. * An array describing the 'cell_line_synonym' table
  2193. *
  2194. * @ingroup tripal_chado_v1.2_schema_api
  2195. *
  2196. */
  2197. function tripal_core_chado_schema_v1_2_cell_line_synonym() {
  2198. $description = array(
  2199. 'description' => 'TODO: please describe this table!',
  2200. 'fields' => array(
  2201. 'cell_line_synonym_id' => array(
  2202. 'description' => 'TODO: please describe this field!',
  2203. 'type' => 'serial',
  2204. 'not null' => TRUE,
  2205. ),
  2206. 'cell_line_id' => array(
  2207. 'description' => 'TODO: please describe this field!',
  2208. 'type' => 'int',
  2209. 'not null' => TRUE,
  2210. ),
  2211. 'synonym_id' => array(
  2212. 'description' => 'TODO: please describe this field!',
  2213. 'type' => 'int',
  2214. 'not null' => TRUE,
  2215. ),
  2216. 'pub_id' => array(
  2217. 'description' => 'TODO: please describe this field!',
  2218. 'type' => 'int',
  2219. 'not null' => TRUE,
  2220. ),
  2221. 'is_current' => array(
  2222. 'description' => 'TODO: please describe this field!',
  2223. 'type' => 'boolean',
  2224. 'not null' => TRUE,
  2225. 'default' => 'als',
  2226. ),
  2227. 'is_internal' => array(
  2228. 'description' => 'TODO: please describe this field!',
  2229. 'type' => 'boolean',
  2230. 'not null' => TRUE,
  2231. 'default' => 'als',
  2232. ),
  2233. ),
  2234. 'primary key' => array(
  2235. 0 => 'cell_line_synonym_id',
  2236. ),
  2237. 'unique keys' => array(
  2238. 'cell_line_synonym_c1' => array(
  2239. 0 => 'synonym_id',
  2240. 1 => 'cell_line_id',
  2241. 2 => 'pub_id',
  2242. ),
  2243. ),
  2244. 'foreign keys' => array(
  2245. 'pub' => array(
  2246. 'table' => 'pub',
  2247. 'columns' => array(
  2248. 'pub_id' => 'pub_id',
  2249. ),
  2250. ),
  2251. 'synonym' => array(
  2252. 'table' => 'synonym',
  2253. 'columns' => array(
  2254. 'synonym_id' => 'synonym_id',
  2255. ),
  2256. ),
  2257. 'cell_line' => array(
  2258. 'table' => 'cell_line',
  2259. 'columns' => array(
  2260. 'cell_line_id' => 'cell_line_id',
  2261. ),
  2262. ),
  2263. ),
  2264. );
  2265. return $description;
  2266. }
  2267. /**
  2268. * Implements hook_chado_schema_v1_2_cell_lineprop()
  2269. * Purpose: To describe the structure of 'cell_lineprop' to tripal
  2270. * @see tripal_core_chado_insert()
  2271. * @see tripal_core_chado_update()
  2272. * @see tripal_core_chado_select()
  2273. *
  2274. * @return
  2275. * An array describing the 'cell_lineprop' table
  2276. *
  2277. * @ingroup tripal_chado_v1.2_schema_api
  2278. *
  2279. */
  2280. function tripal_core_chado_schema_v1_2_cell_lineprop() {
  2281. $description = array(
  2282. 'description' => 'TODO: please describe this table!',
  2283. 'fields' => array(
  2284. 'cell_lineprop_id' => array(
  2285. 'description' => 'TODO: please describe this field!',
  2286. 'type' => 'serial',
  2287. 'not null' => TRUE,
  2288. ),
  2289. 'cell_line_id' => array(
  2290. 'description' => 'TODO: please describe this field!',
  2291. 'type' => 'int',
  2292. 'not null' => TRUE,
  2293. ),
  2294. 'type_id' => array(
  2295. 'description' => 'TODO: please describe this field!',
  2296. 'type' => 'int',
  2297. 'not null' => TRUE,
  2298. ),
  2299. 'value' => array(
  2300. 'description' => 'TODO: please describe this field!',
  2301. 'type' => 'text',
  2302. 'not null' => FALSE,
  2303. ),
  2304. 'rank' => array(
  2305. 'description' => 'TODO: please describe this field!',
  2306. 'type' => 'int',
  2307. 'not null' => TRUE,
  2308. 'default' => 0,
  2309. ),
  2310. ),
  2311. 'primary key' => array(
  2312. 0 => 'cell_lineprop_id',
  2313. ),
  2314. 'unique keys' => array(
  2315. 'cell_lineprop_c1' => array(
  2316. 0 => 'cell_line_id',
  2317. 1 => 'type_id',
  2318. 2 => 'rank',
  2319. ),
  2320. ),
  2321. 'foreign keys' => array(
  2322. 'cvterm' => array(
  2323. 'table' => 'cvterm',
  2324. 'columns' => array(
  2325. 'type_id' => 'cvterm_id',
  2326. ),
  2327. ),
  2328. 'cell_line' => array(
  2329. 'table' => 'cell_line',
  2330. 'columns' => array(
  2331. 'cell_line_id' => 'cell_line_id',
  2332. ),
  2333. ),
  2334. ),
  2335. );
  2336. return $description;
  2337. }
  2338. /**
  2339. * Implements hook_chado_schema_v1_2_cell_lineprop_pub()
  2340. * Purpose: To describe the structure of 'cell_lineprop_pub' to tripal
  2341. * @see tripal_core_chado_insert()
  2342. * @see tripal_core_chado_update()
  2343. * @see tripal_core_chado_select()
  2344. *
  2345. * @return
  2346. * An array describing the 'cell_lineprop_pub' table
  2347. *
  2348. * @ingroup tripal_chado_v1.2_schema_api
  2349. *
  2350. */
  2351. function tripal_core_chado_schema_v1_2_cell_lineprop_pub() {
  2352. $description = array(
  2353. 'description' => 'TODO: please describe this table!',
  2354. 'fields' => array(
  2355. 'cell_lineprop_pub_id' => array(
  2356. 'description' => 'TODO: please describe this field!',
  2357. 'type' => 'serial',
  2358. 'not null' => TRUE,
  2359. ),
  2360. 'cell_lineprop_id' => array(
  2361. 'description' => 'TODO: please describe this field!',
  2362. 'type' => 'int',
  2363. 'not null' => TRUE,
  2364. ),
  2365. 'pub_id' => array(
  2366. 'description' => 'TODO: please describe this field!',
  2367. 'type' => 'int',
  2368. 'not null' => TRUE,
  2369. ),
  2370. ),
  2371. 'primary key' => array(
  2372. 0 => 'cell_lineprop_pub_id',
  2373. ),
  2374. 'unique keys' => array(
  2375. 'cell_lineprop_pub_c1' => array(
  2376. 0 => 'cell_lineprop_id',
  2377. 1 => 'pub_id',
  2378. ),
  2379. ),
  2380. 'foreign keys' => array(
  2381. 'pub' => array(
  2382. 'table' => 'pub',
  2383. 'columns' => array(
  2384. 'pub_id' => 'pub_id',
  2385. ),
  2386. ),
  2387. 'cell_lineprop' => array(
  2388. 'table' => 'cell_lineprop',
  2389. 'columns' => array(
  2390. 'cell_lineprop_id' => 'cell_lineprop_id',
  2391. ),
  2392. ),
  2393. ),
  2394. );
  2395. return $description;
  2396. }
  2397. /**
  2398. * Implements hook_chado_schema_v1_2_chadoprop()
  2399. * Purpose: To describe the structure of 'chadoprop' to tripal
  2400. * @see tripal_core_chado_insert()
  2401. * @see tripal_core_chado_update()
  2402. * @see tripal_core_chado_select()
  2403. *
  2404. * @return
  2405. * An array describing the 'chadoprop' table
  2406. *
  2407. * @ingroup tripal_chado_v1.2_schema_api
  2408. *
  2409. */
  2410. function tripal_core_chado_schema_v1_2_chadoprop() {
  2411. $description = array(
  2412. 'description' => 'TODO: please describe this table!',
  2413. 'fields' => array(
  2414. 'chadoprop_id' => array(
  2415. 'description' => 'TODO: please describe this field!',
  2416. 'type' => 'serial',
  2417. 'not null' => TRUE,
  2418. ),
  2419. 'type_id' => array(
  2420. 'description' => 'TODO: please describe this field!',
  2421. 'type' => 'int',
  2422. 'not null' => TRUE,
  2423. ),
  2424. 'value' => array(
  2425. 'description' => 'TODO: please describe this field!',
  2426. 'type' => 'text',
  2427. 'not null' => FALSE,
  2428. ),
  2429. 'rank' => array(
  2430. 'description' => 'TODO: please describe this field!',
  2431. 'type' => 'int',
  2432. 'not null' => TRUE,
  2433. 'default' => 0,
  2434. ),
  2435. ),
  2436. 'primary key' => array(
  2437. 0 => 'chadoprop_id',
  2438. ),
  2439. 'unique keys' => array(
  2440. 'chadoprop_c1' => array(
  2441. 0 => 'type_id',
  2442. 1 => 'rank',
  2443. ),
  2444. ),
  2445. 'foreign keys' => array(
  2446. 'cvterm' => array(
  2447. 'table' => 'cvterm',
  2448. 'columns' => array(
  2449. 'type_id' => 'cvterm_id',
  2450. ),
  2451. ),
  2452. ),
  2453. );
  2454. return $description;
  2455. }
  2456. /**
  2457. * Implements hook_chado_schema_v1_2_channel()
  2458. * Purpose: To describe the structure of 'channel' to tripal
  2459. * @see tripal_core_chado_insert()
  2460. * @see tripal_core_chado_update()
  2461. * @see tripal_core_chado_select()
  2462. *
  2463. * @return
  2464. * An array describing the 'channel' table
  2465. *
  2466. * @ingroup tripal_chado_v1.2_schema_api
  2467. *
  2468. */
  2469. function tripal_core_chado_schema_v1_2_channel() {
  2470. $description = array(
  2471. 'description' => 'TODO: please describe this table!',
  2472. 'fields' => array(
  2473. 'channel_id' => array(
  2474. 'description' => 'TODO: please describe this field!',
  2475. 'type' => 'serial',
  2476. 'not null' => TRUE,
  2477. ),
  2478. 'name' => array(
  2479. 'description' => 'TODO: please describe this field!',
  2480. 'type' => 'text',
  2481. 'not null' => TRUE,
  2482. ),
  2483. 'definition' => array(
  2484. 'description' => 'TODO: please describe this field!',
  2485. 'type' => 'text',
  2486. 'not null' => TRUE,
  2487. ),
  2488. ),
  2489. 'primary key' => array(
  2490. 0 => 'channel_id',
  2491. ),
  2492. 'unique keys' => array(
  2493. 'channel_c1' => array(
  2494. 0 => 'name',
  2495. ),
  2496. ),
  2497. 'foreign keys' => array(
  2498. ),
  2499. );
  2500. return $description;
  2501. }
  2502. /**
  2503. * Implements hook_chado_schema_v1_2_contact()
  2504. * Purpose: To describe the structure of 'contact' to tripal
  2505. * @see tripal_core_chado_insert()
  2506. * @see tripal_core_chado_update()
  2507. * @see tripal_core_chado_select()
  2508. *
  2509. * @return
  2510. * An array describing the 'contact' table
  2511. *
  2512. * @ingroup tripal_chado_v1.2_schema_api
  2513. *
  2514. */
  2515. function tripal_core_chado_schema_v1_2_contact() {
  2516. $description = array(
  2517. 'description' => 'TODO: please describe this table!',
  2518. 'fields' => array(
  2519. 'contact_id' => array(
  2520. 'description' => 'TODO: please describe this field!',
  2521. 'type' => 'serial',
  2522. 'not null' => TRUE,
  2523. ),
  2524. 'type_id' => array(
  2525. 'description' => 'TODO: please describe this field!',
  2526. 'type' => 'int',
  2527. 'not null' => FALSE,
  2528. ),
  2529. 'name' => array(
  2530. 'description' => 'TODO: please describe this field!',
  2531. 'type' => 'varchar',
  2532. 'length' => '255',
  2533. 'not null' => TRUE,
  2534. ),
  2535. 'description' => array(
  2536. 'description' => 'TODO: please describe this field!',
  2537. 'type' => 'varchar',
  2538. 'length' => '255',
  2539. 'not null' => FALSE,
  2540. ),
  2541. ),
  2542. 'primary key' => array(
  2543. 0 => 'contact_id',
  2544. ),
  2545. 'unique keys' => array(
  2546. 'contact_c1' => array(
  2547. 0 => 'name',
  2548. ),
  2549. ),
  2550. 'foreign keys' => array(
  2551. 'cvterm' => array(
  2552. 'table' => 'cvterm',
  2553. 'columns' => array(
  2554. 'type_id' => 'cvterm_id',
  2555. ),
  2556. ),
  2557. ),
  2558. );
  2559. return $description;
  2560. }
  2561. /**
  2562. * Implements hook_chado_schema_v1_2_contact_relationship()
  2563. * Purpose: To describe the structure of 'contact_relationship' to tripal
  2564. * @see tripal_core_chado_insert()
  2565. * @see tripal_core_chado_update()
  2566. * @see tripal_core_chado_select()
  2567. *
  2568. * @return
  2569. * An array describing the 'contact_relationship' table
  2570. *
  2571. * @ingroup tripal_chado_v1.2_schema_api
  2572. *
  2573. */
  2574. function tripal_core_chado_schema_v1_2_contact_relationship() {
  2575. $description = array(
  2576. 'description' => 'TODO: please describe this table!',
  2577. 'fields' => array(
  2578. 'contact_relationship_id' => array(
  2579. 'description' => 'TODO: please describe this field!',
  2580. 'type' => 'serial',
  2581. 'not null' => TRUE,
  2582. ),
  2583. 'type_id' => array(
  2584. 'description' => 'TODO: please describe this field!',
  2585. 'type' => 'int',
  2586. 'not null' => TRUE,
  2587. ),
  2588. 'subject_id' => array(
  2589. 'description' => 'TODO: please describe this field!',
  2590. 'type' => 'int',
  2591. 'not null' => TRUE,
  2592. ),
  2593. 'object_id' => array(
  2594. 'description' => 'TODO: please describe this field!',
  2595. 'type' => 'int',
  2596. 'not null' => TRUE,
  2597. ),
  2598. ),
  2599. 'primary key' => array(
  2600. 0 => 'contact_relationship_id',
  2601. ),
  2602. 'unique keys' => array(
  2603. 'contact_relationship_c1' => array(
  2604. 0 => 'subject_id',
  2605. 1 => 'object_id',
  2606. 2 => 'type_id',
  2607. ),
  2608. ),
  2609. 'indexes' => array(
  2610. 'contact_relationship_idx1' => array(
  2611. 0 => 'type_id',
  2612. ),
  2613. 'contact_relationship_idx2' => array(
  2614. 0 => 'subject_id',
  2615. ),
  2616. 'contact_relationship_idx3' => array(
  2617. 0 => 'object_id',
  2618. ),
  2619. ),
  2620. 'foreign keys' => array(
  2621. 'cvterm' => array(
  2622. 'table' => 'cvterm',
  2623. 'columns' => array(
  2624. 'type_id' => 'cvterm_id',
  2625. ),
  2626. ),
  2627. 'contact' => array(
  2628. 'table' => 'contact',
  2629. 'columns' => array(
  2630. 'subject_id' => 'contact_id',
  2631. 'object_id' => 'contact_id',
  2632. ),
  2633. ),
  2634. ),
  2635. );
  2636. return $description;
  2637. }
  2638. /**
  2639. * Implements hook_chado_schema_v1_2_control()
  2640. * Purpose: To describe the structure of 'control' to tripal
  2641. * @see tripal_core_chado_insert()
  2642. * @see tripal_core_chado_update()
  2643. * @see tripal_core_chado_select()
  2644. *
  2645. * @return
  2646. * An array describing the 'control' table
  2647. *
  2648. * @ingroup tripal_chado_v1.2_schema_api
  2649. *
  2650. */
  2651. function tripal_core_chado_schema_v1_2_control() {
  2652. $description = array(
  2653. 'description' => 'TODO: please describe this table!',
  2654. 'fields' => array(
  2655. 'control_id' => array(
  2656. 'description' => 'TODO: please describe this field!',
  2657. 'type' => 'serial',
  2658. 'not null' => TRUE,
  2659. ),
  2660. 'type_id' => array(
  2661. 'description' => 'TODO: please describe this field!',
  2662. 'type' => 'int',
  2663. 'not null' => TRUE,
  2664. ),
  2665. 'assay_id' => array(
  2666. 'description' => 'TODO: please describe this field!',
  2667. 'type' => 'int',
  2668. 'not null' => TRUE,
  2669. ),
  2670. 'tableinfo_id' => array(
  2671. 'description' => 'TODO: please describe this field!',
  2672. 'type' => 'int',
  2673. 'not null' => TRUE,
  2674. ),
  2675. 'row_id' => array(
  2676. 'description' => 'TODO: please describe this field!',
  2677. 'type' => 'int',
  2678. 'not null' => TRUE,
  2679. ),
  2680. 'name' => array(
  2681. 'description' => 'TODO: please describe this field!',
  2682. 'type' => 'text',
  2683. 'not null' => FALSE,
  2684. ),
  2685. 'value' => array(
  2686. 'description' => 'TODO: please describe this field!',
  2687. 'type' => 'text',
  2688. 'not null' => FALSE,
  2689. ),
  2690. 'rank' => array(
  2691. 'description' => 'TODO: please describe this field!',
  2692. 'type' => 'int',
  2693. 'not null' => TRUE,
  2694. 'default' => 0,
  2695. ),
  2696. ),
  2697. 'primary key' => array(
  2698. 0 => 'control_id',
  2699. ),
  2700. 'indexes' => array(
  2701. 'control_idx1' => array(
  2702. 0 => 'type_id',
  2703. ),
  2704. 'control_idx2' => array(
  2705. 0 => 'assay_id',
  2706. ),
  2707. 'control_idx3' => array(
  2708. 0 => 'tableinfo_id',
  2709. ),
  2710. 'control_idx4' => array(
  2711. 0 => 'row_id',
  2712. ),
  2713. ),
  2714. 'foreign keys' => array(
  2715. 'cvterm' => array(
  2716. 'table' => 'cvterm',
  2717. 'columns' => array(
  2718. 'type_id' => 'cvterm_id',
  2719. ),
  2720. ),
  2721. 'tableinfo' => array(
  2722. 'table' => 'tableinfo',
  2723. 'columns' => array(
  2724. 'tableinfo_id' => 'tableinfo_id',
  2725. ),
  2726. ),
  2727. 'assay' => array(
  2728. 'table' => 'assay',
  2729. 'columns' => array(
  2730. 'assay_id' => 'assay_id',
  2731. ),
  2732. ),
  2733. ),
  2734. );
  2735. return $description;
  2736. }
  2737. /**
  2738. * Implements hook_chado_schema_v1_2_cv()
  2739. * Purpose: To describe the structure of 'cv' to tripal
  2740. * @see tripal_core_chado_insert()
  2741. * @see tripal_core_chado_update()
  2742. * @see tripal_core_chado_select()
  2743. *
  2744. * @return
  2745. * An array describing the 'cv' table
  2746. *
  2747. * @ingroup tripal_chado_v1.2_schema_api
  2748. *
  2749. */
  2750. function tripal_core_chado_schema_v1_2_cv() {
  2751. $description = array(
  2752. 'description' => 'TODO: please describe this table!',
  2753. 'fields' => array(
  2754. 'cv_id' => array(
  2755. 'description' => 'TODO: please describe this field!',
  2756. 'type' => 'serial',
  2757. 'not null' => TRUE,
  2758. ),
  2759. 'name' => array(
  2760. 'description' => 'TODO: please describe this field!',
  2761. 'type' => 'varchar',
  2762. 'length' => '255',
  2763. 'not null' => TRUE,
  2764. ),
  2765. 'definition' => array(
  2766. 'description' => 'TODO: please describe this field!',
  2767. 'type' => 'text',
  2768. 'not null' => FALSE,
  2769. ),
  2770. ),
  2771. 'primary key' => array(
  2772. 0 => 'cv_id',
  2773. ),
  2774. 'unique keys' => array(
  2775. 'cv_c1' => array(
  2776. 0 => 'name',
  2777. ),
  2778. ),
  2779. 'foreign keys' => array(
  2780. ),
  2781. );
  2782. return $description;
  2783. }
  2784. /**
  2785. * Implements hook_chado_schema_v1_2_cvprop()
  2786. * Purpose: To describe the structure of 'cvprop' to tripal
  2787. * @see tripal_core_chado_insert()
  2788. * @see tripal_core_chado_update()
  2789. * @see tripal_core_chado_select()
  2790. *
  2791. * @return
  2792. * An array describing the 'cvprop' table
  2793. *
  2794. * @ingroup tripal_chado_v1.2_schema_api
  2795. *
  2796. */
  2797. function tripal_core_chado_schema_v1_2_cvprop() {
  2798. $description = array(
  2799. 'description' => 'TODO: please describe this table!',
  2800. 'fields' => array(
  2801. 'cvprop_id' => array(
  2802. 'description' => 'TODO: please describe this field!',
  2803. 'type' => 'serial',
  2804. 'not null' => TRUE,
  2805. ),
  2806. 'cv_id' => array(
  2807. 'description' => 'TODO: please describe this field!',
  2808. 'type' => 'int',
  2809. 'not null' => TRUE,
  2810. ),
  2811. 'type_id' => array(
  2812. 'description' => 'TODO: please describe this field!',
  2813. 'type' => 'int',
  2814. 'not null' => TRUE,
  2815. ),
  2816. 'value' => array(
  2817. 'description' => 'TODO: please describe this field!',
  2818. 'type' => 'text',
  2819. 'not null' => FALSE,
  2820. ),
  2821. 'rank' => array(
  2822. 'description' => 'TODO: please describe this field!',
  2823. 'type' => 'int',
  2824. 'not null' => TRUE,
  2825. 'default' => 0,
  2826. ),
  2827. ),
  2828. 'primary key' => array(
  2829. 0 => 'cvprop_id',
  2830. ),
  2831. 'unique keys' => array(
  2832. 'cvprop_c1' => array(
  2833. 0 => 'cv_id',
  2834. 1 => 'type_id',
  2835. 2 => 'rank',
  2836. ),
  2837. ),
  2838. 'foreign keys' => array(
  2839. 'cvterm' => array(
  2840. 'table' => 'cvterm',
  2841. 'columns' => array(
  2842. 'type_id' => 'cvterm_id',
  2843. ),
  2844. ),
  2845. 'cv' => array(
  2846. 'table' => 'cv',
  2847. 'columns' => array(
  2848. 'cv_id' => 'cv_id',
  2849. ),
  2850. ),
  2851. ),
  2852. );
  2853. return $description;
  2854. }
  2855. /**
  2856. * Implements hook_chado_schema_v1_2_cvterm()
  2857. * Purpose: To describe the structure of 'cvterm' to tripal
  2858. * @see tripal_core_chado_insert()
  2859. * @see tripal_core_chado_update()
  2860. * @see tripal_core_chado_select()
  2861. *
  2862. * @return
  2863. * An array describing the 'cvterm' table
  2864. *
  2865. * @ingroup tripal_chado_v1.2_schema_api
  2866. *
  2867. */
  2868. function tripal_core_chado_schema_v1_2_cvterm() {
  2869. $description = array(
  2870. 'description' => 'TODO: please describe this table!',
  2871. 'fields' => array(
  2872. 'cvterm_id' => array(
  2873. 'description' => 'TODO: please describe this field!',
  2874. 'type' => 'serial',
  2875. 'not null' => TRUE,
  2876. ),
  2877. 'cv_id' => array(
  2878. 'description' => 'TODO: please describe this field!',
  2879. 'type' => 'int',
  2880. 'not null' => TRUE,
  2881. ),
  2882. 'name' => array(
  2883. 'description' => 'TODO: please describe this field!',
  2884. 'type' => 'varchar',
  2885. 'length' => '1024',
  2886. 'not null' => TRUE,
  2887. ),
  2888. 'definition' => array(
  2889. 'description' => 'TODO: please describe this field!',
  2890. 'type' => 'text',
  2891. 'not null' => FALSE,
  2892. ),
  2893. 'dbxref_id' => array(
  2894. 'description' => 'TODO: please describe this field!',
  2895. 'type' => 'int',
  2896. 'not null' => TRUE,
  2897. ),
  2898. 'is_obsolete' => array(
  2899. 'description' => 'TODO: please describe this field!',
  2900. 'type' => 'int',
  2901. 'not null' => TRUE,
  2902. 'default' => 0,
  2903. ),
  2904. 'is_relationshiptype' => array(
  2905. 'description' => 'TODO: please describe this field!',
  2906. 'type' => 'int',
  2907. 'not null' => TRUE,
  2908. 'default' => 0,
  2909. ),
  2910. ),
  2911. 'primary key' => array(
  2912. 0 => 'cvterm_id',
  2913. ),
  2914. 'unique keys' => array(
  2915. 'cvterm_c1' => array(
  2916. 0 => 'name',
  2917. 1 => 'cv_id',
  2918. 2 => 'is_obsolete',
  2919. ),
  2920. 'cvterm_c2' => array(
  2921. 0 => 'dbxref_id',
  2922. ),
  2923. ),
  2924. 'indexes' => array(
  2925. 'cvterm_idx1' => array(
  2926. 0 => 'cv_id',
  2927. ),
  2928. 'cvterm_idx2' => array(
  2929. 0 => 'name',
  2930. ),
  2931. 'cvterm_idx3' => array(
  2932. 0 => 'dbxref_id',
  2933. ),
  2934. ),
  2935. 'foreign keys' => array(
  2936. 'cv' => array(
  2937. 'table' => 'cv',
  2938. 'columns' => array(
  2939. 'cv_id' => 'cv_id',
  2940. ),
  2941. ),
  2942. 'dbxref' => array(
  2943. 'table' => 'dbxref',
  2944. 'columns' => array(
  2945. 'dbxref_id' => 'dbxref_id',
  2946. ),
  2947. ),
  2948. ),
  2949. );
  2950. return $description;
  2951. }
  2952. /**
  2953. * Implements hook_chado_schema_v1_2_cvterm_dbxref()
  2954. * Purpose: To describe the structure of 'cvterm_dbxref' to tripal
  2955. * @see tripal_core_chado_insert()
  2956. * @see tripal_core_chado_update()
  2957. * @see tripal_core_chado_select()
  2958. *
  2959. * @return
  2960. * An array describing the 'cvterm_dbxref' table
  2961. *
  2962. * @ingroup tripal_chado_v1.2_schema_api
  2963. *
  2964. */
  2965. function tripal_core_chado_schema_v1_2_cvterm_dbxref() {
  2966. $description = array(
  2967. 'description' => 'TODO: please describe this table!',
  2968. 'fields' => array(
  2969. 'cvterm_dbxref_id' => array(
  2970. 'description' => 'TODO: please describe this field!',
  2971. 'type' => 'serial',
  2972. 'not null' => TRUE,
  2973. ),
  2974. 'cvterm_id' => array(
  2975. 'description' => 'TODO: please describe this field!',
  2976. 'type' => 'int',
  2977. 'not null' => TRUE,
  2978. ),
  2979. 'dbxref_id' => array(
  2980. 'description' => 'TODO: please describe this field!',
  2981. 'type' => 'int',
  2982. 'not null' => TRUE,
  2983. ),
  2984. 'is_for_definition' => array(
  2985. 'description' => 'TODO: please describe this field!',
  2986. 'type' => 'int',
  2987. 'not null' => TRUE,
  2988. 'default' => 0,
  2989. ),
  2990. ),
  2991. 'primary key' => array(
  2992. 0 => 'cvterm_dbxref_id',
  2993. ),
  2994. 'unique keys' => array(
  2995. 'cvterm_dbxref_c1' => array(
  2996. 0 => 'cvterm_id',
  2997. 1 => 'dbxref_id',
  2998. ),
  2999. ),
  3000. 'indexes' => array(
  3001. 'cvterm_dbxref_idx1' => array(
  3002. 0 => 'cvterm_id',
  3003. ),
  3004. 'cvterm_dbxref_idx2' => array(
  3005. 0 => 'dbxref_id',
  3006. ),
  3007. ),
  3008. 'foreign keys' => array(
  3009. 'cvterm' => array(
  3010. 'table' => 'cvterm',
  3011. 'columns' => array(
  3012. 'cvterm_id' => 'cvterm_id',
  3013. ),
  3014. ),
  3015. 'dbxref' => array(
  3016. 'table' => 'dbxref',
  3017. 'columns' => array(
  3018. 'dbxref_id' => 'dbxref_id',
  3019. ),
  3020. ),
  3021. ),
  3022. );
  3023. return $description;
  3024. }
  3025. /**
  3026. * Implements hook_chado_schema_v1_2_cvterm_relationship()
  3027. * Purpose: To describe the structure of 'cvterm_relationship' to tripal
  3028. * @see tripal_core_chado_insert()
  3029. * @see tripal_core_chado_update()
  3030. * @see tripal_core_chado_select()
  3031. *
  3032. * @return
  3033. * An array describing the 'cvterm_relationship' table
  3034. *
  3035. * @ingroup tripal_chado_v1.2_schema_api
  3036. *
  3037. */
  3038. function tripal_core_chado_schema_v1_2_cvterm_relationship() {
  3039. $description = array(
  3040. 'description' => 'TODO: please describe this table!',
  3041. 'fields' => array(
  3042. 'cvterm_relationship_id' => array(
  3043. 'description' => 'TODO: please describe this field!',
  3044. 'type' => 'serial',
  3045. 'not null' => TRUE,
  3046. ),
  3047. 'type_id' => array(
  3048. 'description' => 'TODO: please describe this field!',
  3049. 'type' => 'int',
  3050. 'not null' => TRUE,
  3051. ),
  3052. 'subject_id' => array(
  3053. 'description' => 'TODO: please describe this field!',
  3054. 'type' => 'int',
  3055. 'not null' => TRUE,
  3056. ),
  3057. 'object_id' => array(
  3058. 'description' => 'TODO: please describe this field!',
  3059. 'type' => 'int',
  3060. 'not null' => TRUE,
  3061. ),
  3062. ),
  3063. 'primary key' => array(
  3064. 0 => 'cvterm_relationship_id',
  3065. ),
  3066. 'unique keys' => array(
  3067. 'cvterm_relationship_c1' => array(
  3068. 0 => 'subject_id',
  3069. 1 => 'object_id',
  3070. 2 => 'type_id',
  3071. ),
  3072. ),
  3073. 'indexes' => array(
  3074. 'cvterm_relationship_idx1' => array(
  3075. 0 => 'type_id',
  3076. ),
  3077. 'cvterm_relationship_idx2' => array(
  3078. 0 => 'subject_id',
  3079. ),
  3080. 'cvterm_relationship_idx3' => array(
  3081. 0 => 'object_id',
  3082. ),
  3083. ),
  3084. 'foreign keys' => array(
  3085. 'cvterm' => array(
  3086. 'table' => 'cvterm',
  3087. 'columns' => array(
  3088. 'type_id' => 'cvterm_id',
  3089. 'subject_id' => 'cvterm_id',
  3090. 'object_id' => 'cvterm_id',
  3091. ),
  3092. ),
  3093. ),
  3094. );
  3095. return $description;
  3096. }
  3097. /**
  3098. * Implements hook_chado_schema_v1_2_cvtermpath()
  3099. * Purpose: To describe the structure of 'cvtermpath' to tripal
  3100. * @see tripal_core_chado_insert()
  3101. * @see tripal_core_chado_update()
  3102. * @see tripal_core_chado_select()
  3103. *
  3104. * @return
  3105. * An array describing the 'cvtermpath' table
  3106. *
  3107. * @ingroup tripal_chado_v1.2_schema_api
  3108. *
  3109. */
  3110. function tripal_core_chado_schema_v1_2_cvtermpath() {
  3111. $description = array(
  3112. 'description' => 'TODO: please describe this table!',
  3113. 'fields' => array(
  3114. 'cvtermpath_id' => array(
  3115. 'description' => 'TODO: please describe this field!',
  3116. 'type' => 'serial',
  3117. 'not null' => TRUE,
  3118. ),
  3119. 'type_id' => array(
  3120. 'description' => 'TODO: please describe this field!',
  3121. 'type' => 'int',
  3122. 'not null' => FALSE,
  3123. ),
  3124. 'subject_id' => array(
  3125. 'description' => 'TODO: please describe this field!',
  3126. 'type' => 'int',
  3127. 'not null' => TRUE,
  3128. ),
  3129. 'object_id' => array(
  3130. 'description' => 'TODO: please describe this field!',
  3131. 'type' => 'int',
  3132. 'not null' => TRUE,
  3133. ),
  3134. 'cv_id' => array(
  3135. 'description' => 'TODO: please describe this field!',
  3136. 'type' => 'int',
  3137. 'not null' => TRUE,
  3138. ),
  3139. 'pathdistance' => array(
  3140. 'description' => 'TODO: please describe this field!',
  3141. 'type' => 'int',
  3142. 'not null' => FALSE,
  3143. ),
  3144. ),
  3145. 'primary key' => array(
  3146. 0 => 'cvtermpath_id',
  3147. ),
  3148. 'unique keys' => array(
  3149. 'cvtermpath_c1' => array(
  3150. 0 => 'subject_id',
  3151. 1 => 'object_id',
  3152. 2 => 'type_id',
  3153. 3 => 'pathdistance',
  3154. ),
  3155. ),
  3156. 'indexes' => array(
  3157. 'cvtermpath_idx1' => array(
  3158. 0 => 'type_id',
  3159. ),
  3160. 'cvtermpath_idx2' => array(
  3161. 0 => 'subject_id',
  3162. ),
  3163. 'cvtermpath_idx3' => array(
  3164. 0 => 'object_id',
  3165. ),
  3166. 'cvtermpath_idx4' => array(
  3167. 0 => 'cv_id',
  3168. ),
  3169. ),
  3170. 'foreign keys' => array(
  3171. 'cvterm' => array(
  3172. 'table' => 'cvterm',
  3173. 'columns' => array(
  3174. 'type_id' => 'cvterm_id',
  3175. 'subject_id' => 'cvterm_id',
  3176. 'object_id' => 'cvterm_id',
  3177. ),
  3178. ),
  3179. 'cv' => array(
  3180. 'table' => 'cv',
  3181. 'columns' => array(
  3182. 'cv_id' => 'cv_id',
  3183. ),
  3184. ),
  3185. ),
  3186. );
  3187. return $description;
  3188. }
  3189. /**
  3190. * Implements hook_chado_schema_v1_2_cvtermprop()
  3191. * Purpose: To describe the structure of 'cvtermprop' to tripal
  3192. * @see tripal_core_chado_insert()
  3193. * @see tripal_core_chado_update()
  3194. * @see tripal_core_chado_select()
  3195. *
  3196. * @return
  3197. * An array describing the 'cvtermprop' table
  3198. *
  3199. * @ingroup tripal_chado_v1.2_schema_api
  3200. *
  3201. */
  3202. function tripal_core_chado_schema_v1_2_cvtermprop() {
  3203. $description = array(
  3204. 'description' => 'TODO: please describe this table!',
  3205. 'fields' => array(
  3206. 'cvtermprop_id' => array(
  3207. 'description' => 'TODO: please describe this field!',
  3208. 'type' => 'serial',
  3209. 'not null' => TRUE,
  3210. ),
  3211. 'cvterm_id' => array(
  3212. 'description' => 'TODO: please describe this field!',
  3213. 'type' => 'int',
  3214. 'not null' => TRUE,
  3215. ),
  3216. 'type_id' => array(
  3217. 'description' => 'TODO: please describe this field!',
  3218. 'type' => 'int',
  3219. 'not null' => TRUE,
  3220. ),
  3221. 'value' => array(
  3222. 'description' => 'TODO: please describe this field!',
  3223. 'type' => 'text',
  3224. 'not null' => TRUE,
  3225. 'default' => '',
  3226. ),
  3227. 'rank' => array(
  3228. 'description' => 'TODO: please describe this field!',
  3229. 'type' => 'int',
  3230. 'not null' => TRUE,
  3231. 'default' => 0,
  3232. ),
  3233. ),
  3234. 'primary key' => array(
  3235. 0 => 'cvtermprop_id',
  3236. ),
  3237. 'unique keys' => array(
  3238. 'cvterm_id' => array(
  3239. 0 => 'cvterm_id',
  3240. 1 => 'type_id',
  3241. 2 => 'value',
  3242. 3 => 'rank',
  3243. ),
  3244. ),
  3245. 'indexes' => array(
  3246. 'cvtermprop_idx1' => array(
  3247. 0 => 'cvterm_id',
  3248. ),
  3249. 'cvtermprop_idx2' => array(
  3250. 0 => 'type_id',
  3251. ),
  3252. ),
  3253. 'foreign keys' => array(
  3254. 'cvterm' => array(
  3255. 'table' => 'cvterm',
  3256. 'columns' => array(
  3257. 'cvterm_id' => 'cvterm_id',
  3258. 'type_id' => 'cvterm_id',
  3259. ),
  3260. ),
  3261. ),
  3262. );
  3263. return $description;
  3264. }
  3265. /**
  3266. * Implements hook_chado_schema_v1_2_cvtermsynonym()
  3267. * Purpose: To describe the structure of 'cvtermsynonym' to tripal
  3268. * @see tripal_core_chado_insert()
  3269. * @see tripal_core_chado_update()
  3270. * @see tripal_core_chado_select()
  3271. *
  3272. * @return
  3273. * An array describing the 'cvtermsynonym' table
  3274. *
  3275. * @ingroup tripal_chado_v1.2_schema_api
  3276. *
  3277. */
  3278. function tripal_core_chado_schema_v1_2_cvtermsynonym() {
  3279. $description = array(
  3280. 'description' => 'TODO: please describe this table!',
  3281. 'fields' => array(
  3282. 'cvtermsynonym_id' => array(
  3283. 'description' => 'TODO: please describe this field!',
  3284. 'type' => 'serial',
  3285. 'not null' => TRUE,
  3286. ),
  3287. 'cvterm_id' => array(
  3288. 'description' => 'TODO: please describe this field!',
  3289. 'type' => 'int',
  3290. 'not null' => TRUE,
  3291. ),
  3292. 'synonym' => array(
  3293. 'description' => 'TODO: please describe this field!',
  3294. 'type' => 'varchar',
  3295. 'length' => '1024',
  3296. 'not null' => TRUE,
  3297. ),
  3298. 'type_id' => array(
  3299. 'description' => 'TODO: please describe this field!',
  3300. 'type' => 'int',
  3301. 'not null' => FALSE,
  3302. ),
  3303. ),
  3304. 'primary key' => array(
  3305. 0 => 'cvtermsynonym_id',
  3306. ),
  3307. 'unique keys' => array(
  3308. 'cvtermsynonym_c1' => array(
  3309. 0 => 'cvterm_id',
  3310. 1 => 'synonym',
  3311. ),
  3312. ),
  3313. 'indexes' => array(
  3314. 'cvtermsynonym_idx1' => array(
  3315. 0 => 'cvterm_id',
  3316. ),
  3317. ),
  3318. 'foreign keys' => array(
  3319. 'cvterm' => array(
  3320. 'table' => 'cvterm',
  3321. 'columns' => array(
  3322. 'cvterm_id' => 'cvterm_id',
  3323. 'type_id' => 'cvterm_id',
  3324. ),
  3325. ),
  3326. ),
  3327. );
  3328. return $description;
  3329. }
  3330. /**
  3331. * Implements hook_chado_schema_v1_2_db()
  3332. * Purpose: To describe the structure of 'db' to tripal
  3333. * @see tripal_core_chado_insert()
  3334. * @see tripal_core_chado_update()
  3335. * @see tripal_core_chado_select()
  3336. *
  3337. * @return
  3338. * An array describing the 'db' table
  3339. *
  3340. * @ingroup tripal_chado_v1.2_schema_api
  3341. *
  3342. */
  3343. function tripal_core_chado_schema_v1_2_db() {
  3344. $description = array(
  3345. 'description' => 'TODO: please describe this table!',
  3346. 'fields' => array(
  3347. 'db_id' => array(
  3348. 'description' => 'TODO: please describe this field!',
  3349. 'type' => 'serial',
  3350. 'not null' => TRUE,
  3351. ),
  3352. 'name' => array(
  3353. 'description' => 'TODO: please describe this field!',
  3354. 'type' => 'varchar',
  3355. 'length' => '255',
  3356. 'not null' => TRUE,
  3357. ),
  3358. 'description' => array(
  3359. 'description' => 'TODO: please describe this field!',
  3360. 'type' => 'varchar',
  3361. 'length' => '255',
  3362. 'not null' => FALSE,
  3363. ),
  3364. 'urlprefix' => array(
  3365. 'description' => 'TODO: please describe this field!',
  3366. 'type' => 'varchar',
  3367. 'length' => '255',
  3368. 'not null' => FALSE,
  3369. ),
  3370. 'url' => array(
  3371. 'description' => 'TODO: please describe this field!',
  3372. 'type' => 'varchar',
  3373. 'length' => '255',
  3374. 'not null' => FALSE,
  3375. ),
  3376. ),
  3377. 'primary key' => array(
  3378. 0 => 'db_id',
  3379. ),
  3380. 'unique keys' => array(
  3381. 'db_c1' => array(
  3382. 0 => 'name',
  3383. ),
  3384. ),
  3385. 'foreign keys' => array(
  3386. ),
  3387. );
  3388. return $description;
  3389. }
  3390. /**
  3391. * Implements hook_chado_schema_v1_2_dbxref()
  3392. * Purpose: To describe the structure of 'dbxref' to tripal
  3393. * @see tripal_core_chado_insert()
  3394. * @see tripal_core_chado_update()
  3395. * @see tripal_core_chado_select()
  3396. *
  3397. * @return
  3398. * An array describing the 'dbxref' table
  3399. *
  3400. * @ingroup tripal_chado_v1.2_schema_api
  3401. *
  3402. */
  3403. function tripal_core_chado_schema_v1_2_dbxref() {
  3404. $description = array(
  3405. 'description' => 'TODO: please describe this table!',
  3406. 'fields' => array(
  3407. 'dbxref_id' => array(
  3408. 'description' => 'TODO: please describe this field!',
  3409. 'type' => 'serial',
  3410. 'not null' => TRUE,
  3411. ),
  3412. 'db_id' => array(
  3413. 'description' => 'TODO: please describe this field!',
  3414. 'type' => 'int',
  3415. 'not null' => TRUE,
  3416. ),
  3417. 'accession' => array(
  3418. 'description' => 'TODO: please describe this field!',
  3419. 'type' => 'varchar',
  3420. 'length' => '255',
  3421. 'not null' => TRUE,
  3422. ),
  3423. 'version' => array(
  3424. 'description' => 'TODO: please describe this field!',
  3425. 'type' => 'varchar',
  3426. 'length' => '255',
  3427. 'not null' => TRUE,
  3428. 'default' => '',
  3429. ),
  3430. 'description' => array(
  3431. 'description' => 'TODO: please describe this field!',
  3432. 'type' => 'text',
  3433. 'not null' => FALSE,
  3434. ),
  3435. ),
  3436. 'primary key' => array(
  3437. 0 => 'dbxref_id',
  3438. ),
  3439. 'unique keys' => array(
  3440. 'dbxref_c1' => array(
  3441. 0 => 'db_id',
  3442. 1 => 'accession',
  3443. 2 => 'version',
  3444. ),
  3445. ),
  3446. 'indexes' => array(
  3447. 'dbxref_idx1' => array(
  3448. 0 => 'db_id',
  3449. ),
  3450. 'dbxref_idx2' => array(
  3451. 0 => 'accession',
  3452. ),
  3453. 'dbxref_idx3' => array(
  3454. 0 => 'version',
  3455. ),
  3456. ),
  3457. 'foreign keys' => array(
  3458. 'db' => array(
  3459. 'table' => 'db',
  3460. 'columns' => array(
  3461. 'db_id' => 'db_id',
  3462. ),
  3463. ),
  3464. ),
  3465. );
  3466. return $description;
  3467. }
  3468. /**
  3469. * Implements hook_chado_schema_v1_2_dbxrefprop()
  3470. * Purpose: To describe the structure of 'dbxrefprop' to tripal
  3471. * @see tripal_core_chado_insert()
  3472. * @see tripal_core_chado_update()
  3473. * @see tripal_core_chado_select()
  3474. *
  3475. * @return
  3476. * An array describing the 'dbxrefprop' table
  3477. *
  3478. * @ingroup tripal_chado_v1.2_schema_api
  3479. *
  3480. */
  3481. function tripal_core_chado_schema_v1_2_dbxrefprop() {
  3482. $description = array(
  3483. 'description' => 'TODO: please describe this table!',
  3484. 'fields' => array(
  3485. 'dbxrefprop_id' => array(
  3486. 'description' => 'TODO: please describe this field!',
  3487. 'type' => 'serial',
  3488. 'not null' => TRUE,
  3489. ),
  3490. 'dbxref_id' => array(
  3491. 'description' => 'TODO: please describe this field!',
  3492. 'type' => 'int',
  3493. 'not null' => TRUE,
  3494. ),
  3495. 'type_id' => array(
  3496. 'description' => 'TODO: please describe this field!',
  3497. 'type' => 'int',
  3498. 'not null' => TRUE,
  3499. ),
  3500. 'value' => array(
  3501. 'description' => 'TODO: please describe this field!',
  3502. 'type' => 'text',
  3503. 'not null' => TRUE,
  3504. 'default' => '',
  3505. ),
  3506. 'rank' => array(
  3507. 'description' => 'TODO: please describe this field!',
  3508. 'type' => 'int',
  3509. 'not null' => TRUE,
  3510. 'default' => 0,
  3511. ),
  3512. ),
  3513. 'primary key' => array(
  3514. 0 => 'dbxrefprop_id',
  3515. ),
  3516. 'unique keys' => array(
  3517. 'dbxrefprop_c1' => array(
  3518. 0 => 'dbxref_id',
  3519. 1 => 'type_id',
  3520. 2 => 'rank',
  3521. ),
  3522. ),
  3523. 'indexes' => array(
  3524. 'dbxrefprop_idx1' => array(
  3525. 0 => 'dbxref_id',
  3526. ),
  3527. 'dbxrefprop_idx2' => array(
  3528. 0 => 'type_id',
  3529. ),
  3530. ),
  3531. 'foreign keys' => array(
  3532. 'cvterm' => array(
  3533. 'table' => 'cvterm',
  3534. 'columns' => array(
  3535. 'type_id' => 'cvterm_id',
  3536. ),
  3537. ),
  3538. 'dbxref' => array(
  3539. 'table' => 'dbxref',
  3540. 'columns' => array(
  3541. 'dbxref_id' => 'dbxref_id',
  3542. ),
  3543. ),
  3544. ),
  3545. );
  3546. return $description;
  3547. }
  3548. /**
  3549. * Implements hook_chado_schema_v1_2_eimage()
  3550. * Purpose: To describe the structure of 'eimage' to tripal
  3551. * @see tripal_core_chado_insert()
  3552. * @see tripal_core_chado_update()
  3553. * @see tripal_core_chado_select()
  3554. *
  3555. * @return
  3556. * An array describing the 'eimage' table
  3557. *
  3558. * @ingroup tripal_chado_v1.2_schema_api
  3559. *
  3560. */
  3561. function tripal_core_chado_schema_v1_2_eimage() {
  3562. $description = array(
  3563. 'description' => 'TODO: please describe this table!',
  3564. 'fields' => array(
  3565. 'eimage_id' => array(
  3566. 'description' => 'TODO: please describe this field!',
  3567. 'type' => 'serial',
  3568. 'not null' => TRUE,
  3569. ),
  3570. 'eimage_data' => array(
  3571. 'description' => 'TODO: please describe this field!',
  3572. 'type' => 'text',
  3573. 'not null' => FALSE,
  3574. ),
  3575. 'eimage_type' => array(
  3576. 'description' => 'TODO: please describe this field!',
  3577. 'type' => 'varchar',
  3578. 'length' => '255',
  3579. 'not null' => TRUE,
  3580. ),
  3581. 'image_uri' => array(
  3582. 'description' => 'TODO: please describe this field!',
  3583. 'type' => 'varchar',
  3584. 'length' => '255',
  3585. 'not null' => FALSE,
  3586. ),
  3587. ),
  3588. 'primary key' => array(
  3589. 0 => 'eimage_id',
  3590. ),
  3591. 'foreign keys' => array(
  3592. ),
  3593. );
  3594. return $description;
  3595. }
  3596. /**
  3597. * Implements hook_chado_schema_v1_2_element()
  3598. * Purpose: To describe the structure of 'element' to tripal
  3599. * @see tripal_core_chado_insert()
  3600. * @see tripal_core_chado_update()
  3601. * @see tripal_core_chado_select()
  3602. *
  3603. * @return
  3604. * An array describing the 'element' table
  3605. *
  3606. * @ingroup tripal_chado_v1.2_schema_api
  3607. *
  3608. */
  3609. function tripal_core_chado_schema_v1_2_element() {
  3610. $description = array(
  3611. 'description' => 'TODO: please describe this table!',
  3612. 'fields' => array(
  3613. 'element_id' => array(
  3614. 'description' => 'TODO: please describe this field!',
  3615. 'type' => 'serial',
  3616. 'not null' => TRUE,
  3617. ),
  3618. 'feature_id' => array(
  3619. 'description' => 'TODO: please describe this field!',
  3620. 'type' => 'int',
  3621. 'not null' => FALSE,
  3622. ),
  3623. 'arraydesign_id' => array(
  3624. 'description' => 'TODO: please describe this field!',
  3625. 'type' => 'int',
  3626. 'not null' => TRUE,
  3627. ),
  3628. 'type_id' => array(
  3629. 'description' => 'TODO: please describe this field!',
  3630. 'type' => 'int',
  3631. 'not null' => FALSE,
  3632. ),
  3633. 'dbxref_id' => array(
  3634. 'description' => 'TODO: please describe this field!',
  3635. 'type' => 'int',
  3636. 'not null' => FALSE,
  3637. ),
  3638. ),
  3639. 'primary key' => array(
  3640. 0 => 'element_id',
  3641. ),
  3642. 'unique keys' => array(
  3643. 'element_c1' => array(
  3644. 0 => 'feature_id',
  3645. 1 => 'arraydesign_id',
  3646. ),
  3647. ),
  3648. 'indexes' => array(
  3649. 'element_idx1' => array(
  3650. 0 => 'feature_id',
  3651. ),
  3652. 'element_idx2' => array(
  3653. 0 => 'arraydesign_id',
  3654. ),
  3655. 'element_idx3' => array(
  3656. 0 => 'type_id',
  3657. ),
  3658. 'element_idx4' => array(
  3659. 0 => 'dbxref_id',
  3660. ),
  3661. ),
  3662. 'foreign keys' => array(
  3663. 'cvterm' => array(
  3664. 'table' => 'cvterm',
  3665. 'columns' => array(
  3666. 'type_id' => 'cvterm_id',
  3667. ),
  3668. ),
  3669. 'dbxref' => array(
  3670. 'table' => 'dbxref',
  3671. 'columns' => array(
  3672. 'dbxref_id' => 'dbxref_id',
  3673. ),
  3674. ),
  3675. 'feature' => array(
  3676. 'table' => 'feature',
  3677. 'columns' => array(
  3678. 'feature_id' => 'feature_id',
  3679. ),
  3680. ),
  3681. 'arraydesign' => array(
  3682. 'table' => 'arraydesign',
  3683. 'columns' => array(
  3684. 'arraydesign_id' => 'arraydesign_id',
  3685. ),
  3686. ),
  3687. ),
  3688. );
  3689. return $description;
  3690. }
  3691. /**
  3692. * Implements hook_chado_schema_v1_2_element_relationship()
  3693. * Purpose: To describe the structure of 'element_relationship' to tripal
  3694. * @see tripal_core_chado_insert()
  3695. * @see tripal_core_chado_update()
  3696. * @see tripal_core_chado_select()
  3697. *
  3698. * @return
  3699. * An array describing the 'element_relationship' table
  3700. *
  3701. * @ingroup tripal_chado_v1.2_schema_api
  3702. *
  3703. */
  3704. function tripal_core_chado_schema_v1_2_element_relationship() {
  3705. $description = array(
  3706. 'description' => 'TODO: please describe this table!',
  3707. 'fields' => array(
  3708. 'element_relationship_id' => array(
  3709. 'description' => 'TODO: please describe this field!',
  3710. 'type' => 'serial',
  3711. 'not null' => TRUE,
  3712. ),
  3713. 'subject_id' => array(
  3714. 'description' => 'TODO: please describe this field!',
  3715. 'type' => 'int',
  3716. 'not null' => TRUE,
  3717. ),
  3718. 'type_id' => array(
  3719. 'description' => 'TODO: please describe this field!',
  3720. 'type' => 'int',
  3721. 'not null' => TRUE,
  3722. ),
  3723. 'object_id' => array(
  3724. 'description' => 'TODO: please describe this field!',
  3725. 'type' => 'int',
  3726. 'not null' => TRUE,
  3727. ),
  3728. 'value' => array(
  3729. 'description' => 'TODO: please describe this field!',
  3730. 'type' => 'text',
  3731. 'not null' => FALSE,
  3732. ),
  3733. 'rank' => array(
  3734. 'description' => 'TODO: please describe this field!',
  3735. 'type' => 'int',
  3736. 'not null' => TRUE,
  3737. 'default' => 0,
  3738. ),
  3739. ),
  3740. 'primary key' => array(
  3741. 0 => 'element_relationship_id',
  3742. ),
  3743. 'unique keys' => array(
  3744. 'element_relationship_c1' => array(
  3745. 0 => 'subject_id',
  3746. 1 => 'object_id',
  3747. 2 => 'type_id',
  3748. 3 => 'rank',
  3749. ),
  3750. ),
  3751. 'indexes' => array(
  3752. 'element_relationship_idx1' => array(
  3753. 0 => 'subject_id',
  3754. ),
  3755. 'element_relationship_idx2' => array(
  3756. 0 => 'type_id',
  3757. ),
  3758. 'element_relationship_idx3' => array(
  3759. 0 => 'object_id',
  3760. ),
  3761. 'element_relationship_idx4' => array(
  3762. 0 => 'value',
  3763. ),
  3764. ),
  3765. 'foreign keys' => array(
  3766. 'cvterm' => array(
  3767. 'table' => 'cvterm',
  3768. 'columns' => array(
  3769. 'type_id' => 'cvterm_id',
  3770. ),
  3771. ),
  3772. 'element' => array(
  3773. 'table' => 'element',
  3774. 'columns' => array(
  3775. 'subject_id' => 'element_id',
  3776. 'object_id' => 'element_id',
  3777. ),
  3778. ),
  3779. ),
  3780. );
  3781. return $description;
  3782. }
  3783. /**
  3784. * Implements hook_chado_schema_v1_2_elementresult()
  3785. * Purpose: To describe the structure of 'elementresult' to tripal
  3786. * @see tripal_core_chado_insert()
  3787. * @see tripal_core_chado_update()
  3788. * @see tripal_core_chado_select()
  3789. *
  3790. * @return
  3791. * An array describing the 'elementresult' table
  3792. *
  3793. * @ingroup tripal_chado_v1.2_schema_api
  3794. *
  3795. */
  3796. function tripal_core_chado_schema_v1_2_elementresult() {
  3797. $description = array(
  3798. 'description' => 'TODO: please describe this table!',
  3799. 'fields' => array(
  3800. 'elementresult_id' => array(
  3801. 'description' => 'TODO: please describe this field!',
  3802. 'type' => 'serial',
  3803. 'not null' => TRUE,
  3804. ),
  3805. 'element_id' => array(
  3806. 'description' => 'TODO: please describe this field!',
  3807. 'type' => 'int',
  3808. 'not null' => TRUE,
  3809. ),
  3810. 'quantification_id' => array(
  3811. 'description' => 'TODO: please describe this field!',
  3812. 'type' => 'int',
  3813. 'not null' => TRUE,
  3814. ),
  3815. 'signal' => array(
  3816. 'description' => 'TODO: please describe this field!',
  3817. 'type' => 'float',
  3818. 'size' => 'big',
  3819. 'not null' => TRUE,
  3820. ),
  3821. ),
  3822. 'primary key' => array(
  3823. 0 => 'elementresult_id',
  3824. ),
  3825. 'unique keys' => array(
  3826. 'elementresult_c1' => array(
  3827. 0 => 'element_id',
  3828. 1 => 'quantification_id',
  3829. ),
  3830. ),
  3831. 'indexes' => array(
  3832. 'elementresult_idx1' => array(
  3833. 0 => 'element_id',
  3834. ),
  3835. 'elementresult_idx2' => array(
  3836. 0 => 'quantification_id',
  3837. ),
  3838. 'elementresult_idx3' => array(
  3839. 0 => 'signal',
  3840. ),
  3841. ),
  3842. 'foreign keys' => array(
  3843. 'quantification' => array(
  3844. 'table' => 'quantification',
  3845. 'columns' => array(
  3846. 'quantification_id' => 'quantification_id',
  3847. ),
  3848. ),
  3849. 'element' => array(
  3850. 'table' => 'element',
  3851. 'columns' => array(
  3852. 'element_id' => 'element_id',
  3853. ),
  3854. ),
  3855. ),
  3856. );
  3857. return $description;
  3858. }
  3859. /**
  3860. * Implements hook_chado_schema_v1_2_elementresult_relationship()
  3861. * Purpose: To describe the structure of 'elementresult_relationship' to tripal
  3862. * @see tripal_core_chado_insert()
  3863. * @see tripal_core_chado_update()
  3864. * @see tripal_core_chado_select()
  3865. *
  3866. * @return
  3867. * An array describing the 'elementresult_relationship' table
  3868. *
  3869. * @ingroup tripal_chado_v1.2_schema_api
  3870. *
  3871. */
  3872. function tripal_core_chado_schema_v1_2_elementresult_relationship() {
  3873. $description = array(
  3874. 'description' => 'TODO: please describe this table!',
  3875. 'fields' => array(
  3876. 'elementresult_relationship_id' => array(
  3877. 'description' => 'TODO: please describe this field!',
  3878. 'type' => 'serial',
  3879. 'not null' => TRUE,
  3880. ),
  3881. 'subject_id' => array(
  3882. 'description' => 'TODO: please describe this field!',
  3883. 'type' => 'int',
  3884. 'not null' => TRUE,
  3885. ),
  3886. 'type_id' => array(
  3887. 'description' => 'TODO: please describe this field!',
  3888. 'type' => 'int',
  3889. 'not null' => TRUE,
  3890. ),
  3891. 'object_id' => array(
  3892. 'description' => 'TODO: please describe this field!',
  3893. 'type' => 'int',
  3894. 'not null' => TRUE,
  3895. ),
  3896. 'value' => array(
  3897. 'description' => 'TODO: please describe this field!',
  3898. 'type' => 'text',
  3899. 'not null' => FALSE,
  3900. ),
  3901. 'rank' => array(
  3902. 'description' => 'TODO: please describe this field!',
  3903. 'type' => 'int',
  3904. 'not null' => TRUE,
  3905. 'default' => 0,
  3906. ),
  3907. ),
  3908. 'primary key' => array(
  3909. 0 => 'elementresult_relationship_id',
  3910. ),
  3911. 'unique keys' => array(
  3912. 'elementresult_relationship_c1' => array(
  3913. 0 => 'subject_id',
  3914. 1 => 'object_id',
  3915. 2 => 'type_id',
  3916. 3 => 'rank',
  3917. ),
  3918. ),
  3919. 'indexes' => array(
  3920. 'elementresult_relationship_idx1' => array(
  3921. 0 => 'subject_id',
  3922. ),
  3923. 'elementresult_relationship_idx2' => array(
  3924. 0 => 'type_id',
  3925. ),
  3926. 'elementresult_relationship_idx3' => array(
  3927. 0 => 'object_id',
  3928. ),
  3929. 'elementresult_relationship_idx4' => array(
  3930. 0 => 'value',
  3931. ),
  3932. ),
  3933. 'foreign keys' => array(
  3934. 'cvterm' => array(
  3935. 'table' => 'cvterm',
  3936. 'columns' => array(
  3937. 'type_id' => 'cvterm_id',
  3938. ),
  3939. ),
  3940. 'elementresult' => array(
  3941. 'table' => 'elementresult',
  3942. 'columns' => array(
  3943. 'subject_id' => 'elementresult_id',
  3944. 'object_id' => 'elementresult_id',
  3945. ),
  3946. ),
  3947. ),
  3948. );
  3949. return $description;
  3950. }
  3951. /**
  3952. * Implements hook_chado_schema_v1_2_environment()
  3953. * Purpose: To describe the structure of 'environment' to tripal
  3954. * @see tripal_core_chado_insert()
  3955. * @see tripal_core_chado_update()
  3956. * @see tripal_core_chado_select()
  3957. *
  3958. * @return
  3959. * An array describing the 'environment' table
  3960. *
  3961. * @ingroup tripal_chado_v1.2_schema_api
  3962. *
  3963. */
  3964. function tripal_core_chado_schema_v1_2_environment() {
  3965. $description = array(
  3966. 'description' => 'TODO: please describe this table!',
  3967. 'fields' => array(
  3968. 'environment_id' => array(
  3969. 'description' => 'TODO: please describe this field!',
  3970. 'type' => 'serial',
  3971. 'not null' => TRUE,
  3972. ),
  3973. 'uniquename' => array(
  3974. 'description' => 'TODO: please describe this field!',
  3975. 'type' => 'text',
  3976. 'not null' => TRUE,
  3977. ),
  3978. 'description' => array(
  3979. 'description' => 'TODO: please describe this field!',
  3980. 'type' => 'text',
  3981. 'not null' => FALSE,
  3982. ),
  3983. ),
  3984. 'primary key' => array(
  3985. 0 => 'environment_id',
  3986. ),
  3987. 'unique keys' => array(
  3988. 'environment_c1' => array(
  3989. 0 => 'uniquename',
  3990. ),
  3991. ),
  3992. 'indexes' => array(
  3993. 'environment_idx1' => array(
  3994. 0 => 'uniquename',
  3995. ),
  3996. ),
  3997. 'foreign keys' => array(
  3998. ),
  3999. );
  4000. return $description;
  4001. }
  4002. /**
  4003. * Implements hook_chado_schema_v1_2_environment_cvterm()
  4004. * Purpose: To describe the structure of 'environment_cvterm' to tripal
  4005. * @see tripal_core_chado_insert()
  4006. * @see tripal_core_chado_update()
  4007. * @see tripal_core_chado_select()
  4008. *
  4009. * @return
  4010. * An array describing the 'environment_cvterm' table
  4011. *
  4012. * @ingroup tripal_chado_v1.2_schema_api
  4013. *
  4014. */
  4015. function tripal_core_chado_schema_v1_2_environment_cvterm() {
  4016. $description = array(
  4017. 'description' => 'TODO: please describe this table!',
  4018. 'fields' => array(
  4019. 'environment_cvterm_id' => array(
  4020. 'description' => 'TODO: please describe this field!',
  4021. 'type' => 'serial',
  4022. 'not null' => TRUE,
  4023. ),
  4024. 'environment_id' => array(
  4025. 'description' => 'TODO: please describe this field!',
  4026. 'type' => 'int',
  4027. 'not null' => TRUE,
  4028. ),
  4029. 'cvterm_id' => array(
  4030. 'description' => 'TODO: please describe this field!',
  4031. 'type' => 'int',
  4032. 'not null' => TRUE,
  4033. ),
  4034. ),
  4035. 'primary key' => array(
  4036. 0 => 'environment_cvterm_id',
  4037. ),
  4038. 'unique keys' => array(
  4039. 'environment_cvterm_c1' => array(
  4040. 0 => 'environment_id',
  4041. 1 => 'cvterm_id',
  4042. ),
  4043. ),
  4044. 'indexes' => array(
  4045. 'environment_cvterm_idx1' => array(
  4046. 0 => 'environment_id',
  4047. ),
  4048. 'environment_cvterm_idx2' => array(
  4049. 0 => 'cvterm_id',
  4050. ),
  4051. ),
  4052. 'foreign keys' => array(
  4053. 'cvterm' => array(
  4054. 'table' => 'cvterm',
  4055. 'columns' => array(
  4056. 'cvterm_id' => 'cvterm_id',
  4057. ),
  4058. ),
  4059. 'environment' => array(
  4060. 'table' => 'environment',
  4061. 'columns' => array(
  4062. 'environment_id' => 'environment_id',
  4063. ),
  4064. ),
  4065. ),
  4066. );
  4067. return $description;
  4068. }
  4069. /**
  4070. * Implements hook_chado_schema_v1_2_expression()
  4071. * Purpose: To describe the structure of 'expression' to tripal
  4072. * @see tripal_core_chado_insert()
  4073. * @see tripal_core_chado_update()
  4074. * @see tripal_core_chado_select()
  4075. *
  4076. * @return
  4077. * An array describing the 'expression' table
  4078. *
  4079. * @ingroup tripal_chado_v1.2_schema_api
  4080. *
  4081. */
  4082. function tripal_core_chado_schema_v1_2_expression() {
  4083. $description = array(
  4084. 'description' => 'TODO: please describe this table!',
  4085. 'fields' => array(
  4086. 'expression_id' => array(
  4087. 'description' => 'TODO: please describe this field!',
  4088. 'type' => 'serial',
  4089. 'not null' => TRUE,
  4090. ),
  4091. 'uniquename' => array(
  4092. 'description' => 'TODO: please describe this field!',
  4093. 'type' => 'text',
  4094. 'not null' => TRUE,
  4095. ),
  4096. 'md5checksum' => array(
  4097. 'description' => 'TODO: please describe this field!',
  4098. 'type' => 'char',
  4099. 'length' => '32',
  4100. 'not null' => FALSE,
  4101. ),
  4102. 'description' => array(
  4103. 'description' => 'TODO: please describe this field!',
  4104. 'type' => 'text',
  4105. 'not null' => FALSE,
  4106. ),
  4107. ),
  4108. 'primary key' => array(
  4109. 0 => 'expression_id',
  4110. ),
  4111. 'unique keys' => array(
  4112. 'expression_c1' => array(
  4113. 0 => 'uniquename',
  4114. ),
  4115. ),
  4116. 'foreign keys' => array(
  4117. ),
  4118. );
  4119. return $description;
  4120. }
  4121. /**
  4122. * Implements hook_chado_schema_v1_2_expression_cvterm()
  4123. * Purpose: To describe the structure of 'expression_cvterm' to tripal
  4124. * @see tripal_core_chado_insert()
  4125. * @see tripal_core_chado_update()
  4126. * @see tripal_core_chado_select()
  4127. *
  4128. * @return
  4129. * An array describing the 'expression_cvterm' table
  4130. *
  4131. * @ingroup tripal_chado_v1.2_schema_api
  4132. *
  4133. */
  4134. function tripal_core_chado_schema_v1_2_expression_cvterm() {
  4135. $description = array(
  4136. 'description' => 'TODO: please describe this table!',
  4137. 'fields' => array(
  4138. 'expression_cvterm_id' => array(
  4139. 'description' => 'TODO: please describe this field!',
  4140. 'type' => 'serial',
  4141. 'not null' => TRUE,
  4142. ),
  4143. 'expression_id' => array(
  4144. 'description' => 'TODO: please describe this field!',
  4145. 'type' => 'int',
  4146. 'not null' => TRUE,
  4147. ),
  4148. 'cvterm_id' => array(
  4149. 'description' => 'TODO: please describe this field!',
  4150. 'type' => 'int',
  4151. 'not null' => TRUE,
  4152. ),
  4153. 'rank' => array(
  4154. 'description' => 'TODO: please describe this field!',
  4155. 'type' => 'int',
  4156. 'not null' => TRUE,
  4157. 'default' => 0,
  4158. ),
  4159. 'cvterm_type_id' => array(
  4160. 'description' => 'TODO: please describe this field!',
  4161. 'type' => 'int',
  4162. 'not null' => TRUE,
  4163. ),
  4164. ),
  4165. 'primary key' => array(
  4166. 0 => 'expression_cvterm_id',
  4167. ),
  4168. 'unique keys' => array(
  4169. 'expression_cvterm_c1' => array(
  4170. 0 => 'expression_id',
  4171. 1 => 'cvterm_id',
  4172. 2 => 'cvterm_type_id',
  4173. ),
  4174. ),
  4175. 'indexes' => array(
  4176. 'expression_cvterm_idx1' => array(
  4177. 0 => 'expression_id',
  4178. ),
  4179. 'expression_cvterm_idx2' => array(
  4180. 0 => 'cvterm_id',
  4181. ),
  4182. 'expression_cvterm_idx3' => array(
  4183. 0 => 'cvterm_type_id',
  4184. ),
  4185. ),
  4186. 'foreign keys' => array(
  4187. 'cvterm' => array(
  4188. 'table' => 'cvterm',
  4189. 'columns' => array(
  4190. 'cvterm_id' => 'cvterm_id',
  4191. 'cvterm_type_id' => 'cvterm_id',
  4192. ),
  4193. ),
  4194. 'expression' => array(
  4195. 'table' => 'expression',
  4196. 'columns' => array(
  4197. 'expression_id' => 'expression_id',
  4198. ),
  4199. ),
  4200. ),
  4201. );
  4202. return $description;
  4203. }
  4204. /**
  4205. * Implements hook_chado_schema_v1_2_expression_cvtermprop()
  4206. * Purpose: To describe the structure of 'expression_cvtermprop' to tripal
  4207. * @see tripal_core_chado_insert()
  4208. * @see tripal_core_chado_update()
  4209. * @see tripal_core_chado_select()
  4210. *
  4211. * @return
  4212. * An array describing the 'expression_cvtermprop' table
  4213. *
  4214. * @ingroup tripal_chado_v1.2_schema_api
  4215. *
  4216. */
  4217. function tripal_core_chado_schema_v1_2_expression_cvtermprop() {
  4218. $description = array(
  4219. 'description' => 'TODO: please describe this table!',
  4220. 'fields' => array(
  4221. 'expression_cvtermprop_id' => array(
  4222. 'description' => 'TODO: please describe this field!',
  4223. 'type' => 'serial',
  4224. 'not null' => TRUE,
  4225. ),
  4226. 'expression_cvterm_id' => array(
  4227. 'description' => 'TODO: please describe this field!',
  4228. 'type' => 'int',
  4229. 'not null' => TRUE,
  4230. ),
  4231. 'type_id' => array(
  4232. 'description' => 'TODO: please describe this field!',
  4233. 'type' => 'int',
  4234. 'not null' => TRUE,
  4235. ),
  4236. 'value' => array(
  4237. 'description' => 'TODO: please describe this field!',
  4238. 'type' => 'text',
  4239. 'not null' => FALSE,
  4240. ),
  4241. 'rank' => array(
  4242. 'description' => 'TODO: please describe this field!',
  4243. 'type' => 'int',
  4244. 'not null' => TRUE,
  4245. 'default' => 0,
  4246. ),
  4247. ),
  4248. 'primary key' => array(
  4249. 0 => 'expression_cvtermprop_id',
  4250. ),
  4251. 'unique keys' => array(
  4252. 'expression_cvtermprop_c1' => array(
  4253. 0 => 'expression_cvterm_id',
  4254. 1 => 'type_id',
  4255. 2 => 'rank',
  4256. ),
  4257. ),
  4258. 'indexes' => array(
  4259. 'expression_cvtermprop_idx1' => array(
  4260. 0 => 'expression_cvterm_id',
  4261. ),
  4262. 'expression_cvtermprop_idx2' => array(
  4263. 0 => 'type_id',
  4264. ),
  4265. ),
  4266. 'foreign keys' => array(
  4267. 'cvterm' => array(
  4268. 'table' => 'cvterm',
  4269. 'columns' => array(
  4270. 'type_id' => 'cvterm_id',
  4271. ),
  4272. ),
  4273. 'expression_cvterm' => array(
  4274. 'table' => 'expression_cvterm',
  4275. 'columns' => array(
  4276. 'expression_cvterm_id' => 'expression_cvterm_id',
  4277. ),
  4278. ),
  4279. ),
  4280. );
  4281. return $description;
  4282. }
  4283. /**
  4284. * Implements hook_chado_schema_v1_2_expression_image()
  4285. * Purpose: To describe the structure of 'expression_image' to tripal
  4286. * @see tripal_core_chado_insert()
  4287. * @see tripal_core_chado_update()
  4288. * @see tripal_core_chado_select()
  4289. *
  4290. * @return
  4291. * An array describing the 'expression_image' table
  4292. *
  4293. * @ingroup tripal_chado_v1.2_schema_api
  4294. *
  4295. */
  4296. function tripal_core_chado_schema_v1_2_expression_image() {
  4297. $description = array(
  4298. 'description' => 'TODO: please describe this table!',
  4299. 'fields' => array(
  4300. 'expression_image_id' => array(
  4301. 'description' => 'TODO: please describe this field!',
  4302. 'type' => 'serial',
  4303. 'not null' => TRUE,
  4304. ),
  4305. 'expression_id' => array(
  4306. 'description' => 'TODO: please describe this field!',
  4307. 'type' => 'int',
  4308. 'not null' => TRUE,
  4309. ),
  4310. 'eimage_id' => array(
  4311. 'description' => 'TODO: please describe this field!',
  4312. 'type' => 'int',
  4313. 'not null' => TRUE,
  4314. ),
  4315. ),
  4316. 'primary key' => array(
  4317. 0 => 'expression_image_id',
  4318. ),
  4319. 'unique keys' => array(
  4320. 'expression_image_c1' => array(
  4321. 0 => 'expression_id',
  4322. 1 => 'eimage_id',
  4323. ),
  4324. ),
  4325. 'indexes' => array(
  4326. 'expression_image_idx1' => array(
  4327. 0 => 'expression_id',
  4328. ),
  4329. 'expression_image_idx2' => array(
  4330. 0 => 'eimage_id',
  4331. ),
  4332. ),
  4333. 'foreign keys' => array(
  4334. 'expression' => array(
  4335. 'table' => 'expression',
  4336. 'columns' => array(
  4337. 'expression_id' => 'expression_id',
  4338. ),
  4339. ),
  4340. 'eimage' => array(
  4341. 'table' => 'eimage',
  4342. 'columns' => array(
  4343. 'eimage_id' => 'eimage_id',
  4344. ),
  4345. ),
  4346. ),
  4347. );
  4348. return $description;
  4349. }
  4350. /**
  4351. * Implements hook_chado_schema_v1_2_expression_pub()
  4352. * Purpose: To describe the structure of 'expression_pub' to tripal
  4353. * @see tripal_core_chado_insert()
  4354. * @see tripal_core_chado_update()
  4355. * @see tripal_core_chado_select()
  4356. *
  4357. * @return
  4358. * An array describing the 'expression_pub' table
  4359. *
  4360. * @ingroup tripal_chado_v1.2_schema_api
  4361. *
  4362. */
  4363. function tripal_core_chado_schema_v1_2_expression_pub() {
  4364. $description = array(
  4365. 'description' => 'TODO: please describe this table!',
  4366. 'fields' => array(
  4367. 'expression_pub_id' => array(
  4368. 'description' => 'TODO: please describe this field!',
  4369. 'type' => 'serial',
  4370. 'not null' => TRUE,
  4371. ),
  4372. 'expression_id' => array(
  4373. 'description' => 'TODO: please describe this field!',
  4374. 'type' => 'int',
  4375. 'not null' => TRUE,
  4376. ),
  4377. 'pub_id' => array(
  4378. 'description' => 'TODO: please describe this field!',
  4379. 'type' => 'int',
  4380. 'not null' => TRUE,
  4381. ),
  4382. ),
  4383. 'primary key' => array(
  4384. 0 => 'expression_pub_id',
  4385. ),
  4386. 'unique keys' => array(
  4387. 'expression_pub_c1' => array(
  4388. 0 => 'expression_id',
  4389. 1 => 'pub_id',
  4390. ),
  4391. ),
  4392. 'indexes' => array(
  4393. 'expression_pub_idx1' => array(
  4394. 0 => 'expression_id',
  4395. ),
  4396. 'expression_pub_idx2' => array(
  4397. 0 => 'pub_id',
  4398. ),
  4399. ),
  4400. 'foreign keys' => array(
  4401. 'pub' => array(
  4402. 'table' => 'pub',
  4403. 'columns' => array(
  4404. 'pub_id' => 'pub_id',
  4405. ),
  4406. ),
  4407. 'expression' => array(
  4408. 'table' => 'expression',
  4409. 'columns' => array(
  4410. 'expression_id' => 'expression_id',
  4411. ),
  4412. ),
  4413. ),
  4414. );
  4415. return $description;
  4416. }
  4417. /**
  4418. * Implements hook_chado_schema_v1_2_expressionprop()
  4419. * Purpose: To describe the structure of 'expressionprop' to tripal
  4420. * @see tripal_core_chado_insert()
  4421. * @see tripal_core_chado_update()
  4422. * @see tripal_core_chado_select()
  4423. *
  4424. * @return
  4425. * An array describing the 'expressionprop' table
  4426. *
  4427. * @ingroup tripal_chado_v1.2_schema_api
  4428. *
  4429. */
  4430. function tripal_core_chado_schema_v1_2_expressionprop() {
  4431. $description = array(
  4432. 'description' => 'TODO: please describe this table!',
  4433. 'fields' => array(
  4434. 'expressionprop_id' => array(
  4435. 'description' => 'TODO: please describe this field!',
  4436. 'type' => 'serial',
  4437. 'not null' => TRUE,
  4438. ),
  4439. 'expression_id' => array(
  4440. 'description' => 'TODO: please describe this field!',
  4441. 'type' => 'int',
  4442. 'not null' => TRUE,
  4443. ),
  4444. 'type_id' => array(
  4445. 'description' => 'TODO: please describe this field!',
  4446. 'type' => 'int',
  4447. 'not null' => TRUE,
  4448. ),
  4449. 'value' => array(
  4450. 'description' => 'TODO: please describe this field!',
  4451. 'type' => 'text',
  4452. 'not null' => FALSE,
  4453. ),
  4454. 'rank' => array(
  4455. 'description' => 'TODO: please describe this field!',
  4456. 'type' => 'int',
  4457. 'not null' => TRUE,
  4458. 'default' => 0,
  4459. ),
  4460. ),
  4461. 'primary key' => array(
  4462. 0 => 'expressionprop_id',
  4463. ),
  4464. 'unique keys' => array(
  4465. 'expressionprop_c1' => array(
  4466. 0 => 'expression_id',
  4467. 1 => 'type_id',
  4468. 2 => 'rank',
  4469. ),
  4470. ),
  4471. 'indexes' => array(
  4472. 'expressionprop_idx1' => array(
  4473. 0 => 'expression_id',
  4474. ),
  4475. 'expressionprop_idx2' => array(
  4476. 0 => 'type_id',
  4477. ),
  4478. ),
  4479. 'foreign keys' => array(
  4480. 'cvterm' => array(
  4481. 'table' => 'cvterm',
  4482. 'columns' => array(
  4483. 'type_id' => 'cvterm_id',
  4484. ),
  4485. ),
  4486. 'expression' => array(
  4487. 'table' => 'expression',
  4488. 'columns' => array(
  4489. 'expression_id' => 'expression_id',
  4490. ),
  4491. ),
  4492. ),
  4493. );
  4494. return $description;
  4495. }
  4496. /**
  4497. * Implements hook_chado_schema_v1_2_feature()
  4498. * Purpose: To describe the structure of 'feature' to tripal
  4499. * @see tripal_core_chado_insert()
  4500. * @see tripal_core_chado_update()
  4501. * @see tripal_core_chado_select()
  4502. *
  4503. * @return
  4504. * An array describing the 'feature' table
  4505. *
  4506. * @ingroup tripal_chado_v1.2_schema_api
  4507. *
  4508. */
  4509. function tripal_core_chado_schema_v1_2_feature() {
  4510. $description = array(
  4511. 'description' => 'TODO: please describe this table!',
  4512. 'fields' => array(
  4513. 'feature_id' => array(
  4514. 'description' => 'TODO: please describe this field!',
  4515. 'type' => 'serial',
  4516. 'not null' => TRUE,
  4517. ),
  4518. 'dbxref_id' => array(
  4519. 'description' => 'TODO: please describe this field!',
  4520. 'type' => 'int',
  4521. 'not null' => FALSE,
  4522. ),
  4523. 'organism_id' => array(
  4524. 'description' => 'TODO: please describe this field!',
  4525. 'type' => 'int',
  4526. 'not null' => TRUE,
  4527. ),
  4528. 'name' => array(
  4529. 'description' => 'TODO: please describe this field!',
  4530. 'type' => 'varchar',
  4531. 'length' => '255',
  4532. 'not null' => FALSE,
  4533. ),
  4534. 'uniquename' => array(
  4535. 'description' => 'TODO: please describe this field!',
  4536. 'type' => 'text',
  4537. 'not null' => TRUE,
  4538. ),
  4539. 'residues' => array(
  4540. 'description' => 'TODO: please describe this field!',
  4541. 'type' => 'text',
  4542. 'not null' => FALSE,
  4543. ),
  4544. 'seqlen' => array(
  4545. 'description' => 'TODO: please describe this field!',
  4546. 'type' => 'int',
  4547. 'not null' => FALSE,
  4548. ),
  4549. 'md5checksum' => array(
  4550. 'description' => 'TODO: please describe this field!',
  4551. 'type' => 'char',
  4552. 'length' => '32',
  4553. 'not null' => FALSE,
  4554. ),
  4555. 'type_id' => array(
  4556. 'description' => 'TODO: please describe this field!',
  4557. 'type' => 'int',
  4558. 'not null' => TRUE,
  4559. ),
  4560. 'is_analysis' => array(
  4561. 'description' => 'TODO: please describe this field!',
  4562. 'type' => 'boolean',
  4563. 'not null' => TRUE,
  4564. 'default' => 'als',
  4565. ),
  4566. 'is_obsolete' => array(
  4567. 'description' => 'TODO: please describe this field!',
  4568. 'type' => 'boolean',
  4569. 'not null' => TRUE,
  4570. 'default' => 'als',
  4571. ),
  4572. 'timeaccessioned' => array(
  4573. 'description' => 'TODO: please describe this field!',
  4574. 'type' => 'datetime',
  4575. 'not null' => TRUE,
  4576. 'default' => 'ow(',
  4577. ),
  4578. 'timelastmodified' => array(
  4579. 'description' => 'TODO: please describe this field!',
  4580. 'type' => 'datetime',
  4581. 'not null' => TRUE,
  4582. 'default' => 'ow(',
  4583. ),
  4584. ),
  4585. 'primary key' => array(
  4586. 0 => 'feature_id',
  4587. ),
  4588. 'unique keys' => array(
  4589. 'feature_c1' => array(
  4590. 0 => 'organism_id',
  4591. 1 => 'uniquename',
  4592. 2 => 'type_id',
  4593. ),
  4594. ),
  4595. 'indexes' => array(
  4596. 'feature_idx1' => array(
  4597. 0 => 'dbxref_id',
  4598. ),
  4599. 'feature_idx2' => array(
  4600. 0 => 'organism_id',
  4601. ),
  4602. 'feature_idx3' => array(
  4603. 0 => 'type_id',
  4604. ),
  4605. 'feature_idx4' => array(
  4606. 0 => 'uniquename',
  4607. ),
  4608. 'feature_name_ind1' => array(
  4609. 0 => 'name',
  4610. ),
  4611. ),
  4612. 'foreign keys' => array(
  4613. 'organism' => array(
  4614. 'table' => 'organism',
  4615. 'columns' => array(
  4616. 'organism_id' => 'organism_id',
  4617. ),
  4618. ),
  4619. 'cvterm' => array(
  4620. 'table' => 'cvterm',
  4621. 'columns' => array(
  4622. 'type_id' => 'cvterm_id',
  4623. ),
  4624. ),
  4625. 'dbxref' => array(
  4626. 'table' => 'dbxref',
  4627. 'columns' => array(
  4628. 'dbxref_id' => 'dbxref_id',
  4629. ),
  4630. ),
  4631. ),
  4632. );
  4633. return $description;
  4634. }
  4635. /**
  4636. * Implements hook_chado_schema_v1_2_feature_cvterm()
  4637. * Purpose: To describe the structure of 'feature_cvterm' to tripal
  4638. * @see tripal_core_chado_insert()
  4639. * @see tripal_core_chado_update()
  4640. * @see tripal_core_chado_select()
  4641. *
  4642. * @return
  4643. * An array describing the 'feature_cvterm' table
  4644. *
  4645. * @ingroup tripal_chado_v1.2_schema_api
  4646. *
  4647. */
  4648. function tripal_core_chado_schema_v1_2_feature_cvterm() {
  4649. $description = array(
  4650. 'description' => 'TODO: please describe this table!',
  4651. 'fields' => array(
  4652. 'feature_cvterm_id' => array(
  4653. 'description' => 'TODO: please describe this field!',
  4654. 'type' => 'serial',
  4655. 'not null' => TRUE,
  4656. ),
  4657. 'feature_id' => array(
  4658. 'description' => 'TODO: please describe this field!',
  4659. 'type' => 'int',
  4660. 'not null' => TRUE,
  4661. ),
  4662. 'cvterm_id' => array(
  4663. 'description' => 'TODO: please describe this field!',
  4664. 'type' => 'int',
  4665. 'not null' => TRUE,
  4666. ),
  4667. 'pub_id' => array(
  4668. 'description' => 'TODO: please describe this field!',
  4669. 'type' => 'int',
  4670. 'not null' => TRUE,
  4671. ),
  4672. 'is_not' => array(
  4673. 'description' => 'TODO: please describe this field!',
  4674. 'type' => 'boolean',
  4675. 'not null' => TRUE,
  4676. 'default' => 'als',
  4677. ),
  4678. 'rank' => array(
  4679. 'description' => 'TODO: please describe this field!',
  4680. 'type' => 'int',
  4681. 'not null' => TRUE,
  4682. 'default' => 0,
  4683. ),
  4684. ),
  4685. 'primary key' => array(
  4686. 0 => 'feature_cvterm_id',
  4687. ),
  4688. 'unique keys' => array(
  4689. 'feature_cvterm_c1' => array(
  4690. 0 => 'feature_id',
  4691. 1 => 'cvterm_id',
  4692. 2 => 'pub_id',
  4693. 3 => 'rank',
  4694. ),
  4695. ),
  4696. 'indexes' => array(
  4697. 'feature_cvterm_idx1' => array(
  4698. 0 => 'feature_id',
  4699. ),
  4700. 'feature_cvterm_idx2' => array(
  4701. 0 => 'cvterm_id',
  4702. ),
  4703. 'feature_cvterm_idx3' => array(
  4704. 0 => 'pub_id',
  4705. ),
  4706. ),
  4707. 'foreign keys' => array(
  4708. 'cvterm' => array(
  4709. 'table' => 'cvterm',
  4710. 'columns' => array(
  4711. 'cvterm_id' => 'cvterm_id',
  4712. ),
  4713. ),
  4714. 'pub' => array(
  4715. 'table' => 'pub',
  4716. 'columns' => array(
  4717. 'pub_id' => 'pub_id',
  4718. ),
  4719. ),
  4720. 'feature' => array(
  4721. 'table' => 'feature',
  4722. 'columns' => array(
  4723. 'feature_id' => 'feature_id',
  4724. ),
  4725. ),
  4726. ),
  4727. );
  4728. return $description;
  4729. }
  4730. /**
  4731. * Implements hook_chado_schema_v1_2_feature_cvterm_dbxref()
  4732. * Purpose: To describe the structure of 'feature_cvterm_dbxref' to tripal
  4733. * @see tripal_core_chado_insert()
  4734. * @see tripal_core_chado_update()
  4735. * @see tripal_core_chado_select()
  4736. *
  4737. * @return
  4738. * An array describing the 'feature_cvterm_dbxref' table
  4739. *
  4740. * @ingroup tripal_chado_v1.2_schema_api
  4741. *
  4742. */
  4743. function tripal_core_chado_schema_v1_2_feature_cvterm_dbxref() {
  4744. $description = array(
  4745. 'description' => 'TODO: please describe this table!',
  4746. 'fields' => array(
  4747. 'feature_cvterm_dbxref_id' => array(
  4748. 'description' => 'TODO: please describe this field!',
  4749. 'type' => 'serial',
  4750. 'not null' => TRUE,
  4751. ),
  4752. 'feature_cvterm_id' => array(
  4753. 'description' => 'TODO: please describe this field!',
  4754. 'type' => 'int',
  4755. 'not null' => TRUE,
  4756. ),
  4757. 'dbxref_id' => array(
  4758. 'description' => 'TODO: please describe this field!',
  4759. 'type' => 'int',
  4760. 'not null' => TRUE,
  4761. ),
  4762. ),
  4763. 'primary key' => array(
  4764. 0 => 'feature_cvterm_dbxref_id',
  4765. ),
  4766. 'unique keys' => array(
  4767. 'feature_cvterm_dbxref_c1' => array(
  4768. 0 => 'feature_cvterm_id',
  4769. 1 => 'dbxref_id',
  4770. ),
  4771. ),
  4772. 'indexes' => array(
  4773. 'feature_cvterm_dbxref_idx1' => array(
  4774. 0 => 'feature_cvterm_id',
  4775. ),
  4776. 'feature_cvterm_dbxref_idx2' => array(
  4777. 0 => 'dbxref_id',
  4778. ),
  4779. ),
  4780. 'foreign keys' => array(
  4781. 'feature_cvterm' => array(
  4782. 'table' => 'feature_cvterm',
  4783. 'columns' => array(
  4784. 'feature_cvterm_id' => 'feature_cvterm_id',
  4785. ),
  4786. ),
  4787. 'dbxref' => array(
  4788. 'table' => 'dbxref',
  4789. 'columns' => array(
  4790. 'dbxref_id' => 'dbxref_id',
  4791. ),
  4792. ),
  4793. ),
  4794. );
  4795. return $description;
  4796. }
  4797. /**
  4798. * Implements hook_chado_schema_v1_2_feature_cvterm_pub()
  4799. * Purpose: To describe the structure of 'feature_cvterm_pub' to tripal
  4800. * @see tripal_core_chado_insert()
  4801. * @see tripal_core_chado_update()
  4802. * @see tripal_core_chado_select()
  4803. *
  4804. * @return
  4805. * An array describing the 'feature_cvterm_pub' table
  4806. *
  4807. * @ingroup tripal_chado_v1.2_schema_api
  4808. *
  4809. */
  4810. function tripal_core_chado_schema_v1_2_feature_cvterm_pub() {
  4811. $description = array(
  4812. 'description' => 'TODO: please describe this table!',
  4813. 'fields' => array(
  4814. 'feature_cvterm_pub_id' => array(
  4815. 'description' => 'TODO: please describe this field!',
  4816. 'type' => 'serial',
  4817. 'not null' => TRUE,
  4818. ),
  4819. 'feature_cvterm_id' => array(
  4820. 'description' => 'TODO: please describe this field!',
  4821. 'type' => 'int',
  4822. 'not null' => TRUE,
  4823. ),
  4824. 'pub_id' => array(
  4825. 'description' => 'TODO: please describe this field!',
  4826. 'type' => 'int',
  4827. 'not null' => TRUE,
  4828. ),
  4829. ),
  4830. 'primary key' => array(
  4831. 0 => 'feature_cvterm_pub_id',
  4832. ),
  4833. 'unique keys' => array(
  4834. 'feature_cvterm_pub_c1' => array(
  4835. 0 => 'feature_cvterm_id',
  4836. 1 => 'pub_id',
  4837. ),
  4838. ),
  4839. 'indexes' => array(
  4840. 'feature_cvterm_pub_idx1' => array(
  4841. 0 => 'feature_cvterm_id',
  4842. ),
  4843. 'feature_cvterm_pub_idx2' => array(
  4844. 0 => 'pub_id',
  4845. ),
  4846. ),
  4847. 'foreign keys' => array(
  4848. 'feature_cvterm' => array(
  4849. 'table' => 'feature_cvterm',
  4850. 'columns' => array(
  4851. 'feature_cvterm_id' => 'feature_cvterm_id',
  4852. ),
  4853. ),
  4854. 'pub' => array(
  4855. 'table' => 'pub',
  4856. 'columns' => array(
  4857. 'pub_id' => 'pub_id',
  4858. ),
  4859. ),
  4860. ),
  4861. );
  4862. return $description;
  4863. }
  4864. /**
  4865. * Implements hook_chado_schema_v1_2_feature_cvtermprop()
  4866. * Purpose: To describe the structure of 'feature_cvtermprop' to tripal
  4867. * @see tripal_core_chado_insert()
  4868. * @see tripal_core_chado_update()
  4869. * @see tripal_core_chado_select()
  4870. *
  4871. * @return
  4872. * An array describing the 'feature_cvtermprop' table
  4873. *
  4874. * @ingroup tripal_chado_v1.2_schema_api
  4875. *
  4876. */
  4877. function tripal_core_chado_schema_v1_2_feature_cvtermprop() {
  4878. $description = array(
  4879. 'description' => 'TODO: please describe this table!',
  4880. 'fields' => array(
  4881. 'feature_cvtermprop_id' => array(
  4882. 'description' => 'TODO: please describe this field!',
  4883. 'type' => 'serial',
  4884. 'not null' => TRUE,
  4885. ),
  4886. 'feature_cvterm_id' => array(
  4887. 'description' => 'TODO: please describe this field!',
  4888. 'type' => 'int',
  4889. 'not null' => TRUE,
  4890. ),
  4891. 'type_id' => array(
  4892. 'description' => 'TODO: please describe this field!',
  4893. 'type' => 'int',
  4894. 'not null' => TRUE,
  4895. ),
  4896. 'value' => array(
  4897. 'description' => 'TODO: please describe this field!',
  4898. 'type' => 'text',
  4899. 'not null' => FALSE,
  4900. ),
  4901. 'rank' => array(
  4902. 'description' => 'TODO: please describe this field!',
  4903. 'type' => 'int',
  4904. 'not null' => TRUE,
  4905. 'default' => 0,
  4906. ),
  4907. ),
  4908. 'primary key' => array(
  4909. 0 => 'feature_cvtermprop_id',
  4910. ),
  4911. 'unique keys' => array(
  4912. 'feature_cvtermprop_c1' => array(
  4913. 0 => 'feature_cvterm_id',
  4914. 1 => 'type_id',
  4915. 2 => 'rank',
  4916. ),
  4917. ),
  4918. 'indexes' => array(
  4919. 'feature_cvtermprop_idx1' => array(
  4920. 0 => 'feature_cvterm_id',
  4921. ),
  4922. 'feature_cvtermprop_idx2' => array(
  4923. 0 => 'type_id',
  4924. ),
  4925. ),
  4926. 'foreign keys' => array(
  4927. 'cvterm' => array(
  4928. 'table' => 'cvterm',
  4929. 'columns' => array(
  4930. 'type_id' => 'cvterm_id',
  4931. ),
  4932. ),
  4933. 'feature_cvterm' => array(
  4934. 'table' => 'feature_cvterm',
  4935. 'columns' => array(
  4936. 'feature_cvterm_id' => 'feature_cvterm_id',
  4937. ),
  4938. ),
  4939. ),
  4940. );
  4941. return $description;
  4942. }
  4943. /**
  4944. * Implements hook_chado_schema_v1_2_feature_dbxref()
  4945. * Purpose: To describe the structure of 'feature_dbxref' to tripal
  4946. * @see tripal_core_chado_insert()
  4947. * @see tripal_core_chado_update()
  4948. * @see tripal_core_chado_select()
  4949. *
  4950. * @return
  4951. * An array describing the 'feature_dbxref' table
  4952. *
  4953. * @ingroup tripal_chado_v1.2_schema_api
  4954. *
  4955. */
  4956. function tripal_core_chado_schema_v1_2_feature_dbxref() {
  4957. $description = array(
  4958. 'description' => 'TODO: please describe this table!',
  4959. 'fields' => array(
  4960. 'feature_dbxref_id' => array(
  4961. 'description' => 'TODO: please describe this field!',
  4962. 'type' => 'serial',
  4963. 'not null' => TRUE,
  4964. ),
  4965. 'feature_id' => array(
  4966. 'description' => 'TODO: please describe this field!',
  4967. 'type' => 'int',
  4968. 'not null' => TRUE,
  4969. ),
  4970. 'dbxref_id' => array(
  4971. 'description' => 'TODO: please describe this field!',
  4972. 'type' => 'int',
  4973. 'not null' => TRUE,
  4974. ),
  4975. 'is_current' => array(
  4976. 'description' => 'TODO: please describe this field!',
  4977. 'type' => 'boolean',
  4978. 'not null' => TRUE,
  4979. 'default' => 'ru',
  4980. ),
  4981. ),
  4982. 'primary key' => array(
  4983. 0 => 'feature_dbxref_id',
  4984. ),
  4985. 'unique keys' => array(
  4986. 'feature_dbxref_c1' => array(
  4987. 0 => 'feature_id',
  4988. 1 => 'dbxref_id',
  4989. ),
  4990. ),
  4991. 'indexes' => array(
  4992. 'feature_dbxref_idx1' => array(
  4993. 0 => 'feature_id',
  4994. ),
  4995. 'feature_dbxref_idx2' => array(
  4996. 0 => 'dbxref_id',
  4997. ),
  4998. ),
  4999. 'foreign keys' => array(
  5000. 'dbxref' => array(
  5001. 'table' => 'dbxref',
  5002. 'columns' => array(
  5003. 'dbxref_id' => 'dbxref_id',
  5004. ),
  5005. ),
  5006. 'feature' => array(
  5007. 'table' => 'feature',
  5008. 'columns' => array(
  5009. 'feature_id' => 'feature_id',
  5010. ),
  5011. ),
  5012. ),
  5013. );
  5014. return $description;
  5015. }
  5016. /**
  5017. * Implements hook_chado_schema_v1_2_feature_expression()
  5018. * Purpose: To describe the structure of 'feature_expression' to tripal
  5019. * @see tripal_core_chado_insert()
  5020. * @see tripal_core_chado_update()
  5021. * @see tripal_core_chado_select()
  5022. *
  5023. * @return
  5024. * An array describing the 'feature_expression' table
  5025. *
  5026. * @ingroup tripal_chado_v1.2_schema_api
  5027. *
  5028. */
  5029. function tripal_core_chado_schema_v1_2_feature_expression() {
  5030. $description = array(
  5031. 'description' => 'TODO: please describe this table!',
  5032. 'fields' => array(
  5033. 'feature_expression_id' => array(
  5034. 'description' => 'TODO: please describe this field!',
  5035. 'type' => 'serial',
  5036. 'not null' => TRUE,
  5037. ),
  5038. 'expression_id' => array(
  5039. 'description' => 'TODO: please describe this field!',
  5040. 'type' => 'int',
  5041. 'not null' => TRUE,
  5042. ),
  5043. 'feature_id' => array(
  5044. 'description' => 'TODO: please describe this field!',
  5045. 'type' => 'int',
  5046. 'not null' => TRUE,
  5047. ),
  5048. 'pub_id' => array(
  5049. 'description' => 'TODO: please describe this field!',
  5050. 'type' => 'int',
  5051. 'not null' => TRUE,
  5052. ),
  5053. ),
  5054. 'primary key' => array(
  5055. 0 => 'feature_expression_id',
  5056. ),
  5057. 'unique keys' => array(
  5058. 'feature_expression_c1' => array(
  5059. 0 => 'expression_id',
  5060. 1 => 'feature_id',
  5061. 2 => 'pub_id',
  5062. ),
  5063. ),
  5064. 'indexes' => array(
  5065. 'feature_expression_idx1' => array(
  5066. 0 => 'expression_id',
  5067. ),
  5068. 'feature_expression_idx2' => array(
  5069. 0 => 'feature_id',
  5070. ),
  5071. 'feature_expression_idx3' => array(
  5072. 0 => 'pub_id',
  5073. ),
  5074. ),
  5075. 'foreign keys' => array(
  5076. 'pub' => array(
  5077. 'table' => 'pub',
  5078. 'columns' => array(
  5079. 'pub_id' => 'pub_id',
  5080. ),
  5081. ),
  5082. 'feature' => array(
  5083. 'table' => 'feature',
  5084. 'columns' => array(
  5085. 'feature_id' => 'feature_id',
  5086. ),
  5087. ),
  5088. 'expression' => array(
  5089. 'table' => 'expression',
  5090. 'columns' => array(
  5091. 'expression_id' => 'expression_id',
  5092. ),
  5093. ),
  5094. ),
  5095. );
  5096. return $description;
  5097. }
  5098. /**
  5099. * Implements hook_chado_schema_v1_2_feature_expressionprop()
  5100. * Purpose: To describe the structure of 'feature_expressionprop' to tripal
  5101. * @see tripal_core_chado_insert()
  5102. * @see tripal_core_chado_update()
  5103. * @see tripal_core_chado_select()
  5104. *
  5105. * @return
  5106. * An array describing the 'feature_expressionprop' table
  5107. *
  5108. * @ingroup tripal_chado_v1.2_schema_api
  5109. *
  5110. */
  5111. function tripal_core_chado_schema_v1_2_feature_expressionprop() {
  5112. $description = array(
  5113. 'description' => 'TODO: please describe this table!',
  5114. 'fields' => array(
  5115. 'feature_expressionprop_id' => array(
  5116. 'description' => 'TODO: please describe this field!',
  5117. 'type' => 'serial',
  5118. 'not null' => TRUE,
  5119. ),
  5120. 'feature_expression_id' => array(
  5121. 'description' => 'TODO: please describe this field!',
  5122. 'type' => 'int',
  5123. 'not null' => TRUE,
  5124. ),
  5125. 'type_id' => array(
  5126. 'description' => 'TODO: please describe this field!',
  5127. 'type' => 'int',
  5128. 'not null' => TRUE,
  5129. ),
  5130. 'value' => array(
  5131. 'description' => 'TODO: please describe this field!',
  5132. 'type' => 'text',
  5133. 'not null' => FALSE,
  5134. ),
  5135. 'rank' => array(
  5136. 'description' => 'TODO: please describe this field!',
  5137. 'type' => 'int',
  5138. 'not null' => TRUE,
  5139. 'default' => 0,
  5140. ),
  5141. ),
  5142. 'primary key' => array(
  5143. 0 => 'feature_expressionprop_id',
  5144. ),
  5145. 'unique keys' => array(
  5146. 'feature_expressionprop_c1' => array(
  5147. 0 => 'feature_expression_id',
  5148. 1 => 'type_id',
  5149. 2 => 'rank',
  5150. ),
  5151. ),
  5152. 'indexes' => array(
  5153. 'feature_expressionprop_idx1' => array(
  5154. 0 => 'feature_expression_id',
  5155. ),
  5156. 'feature_expressionprop_idx2' => array(
  5157. 0 => 'type_id',
  5158. ),
  5159. ),
  5160. 'foreign keys' => array(
  5161. 'cvterm' => array(
  5162. 'table' => 'cvterm',
  5163. 'columns' => array(
  5164. 'type_id' => 'cvterm_id',
  5165. ),
  5166. ),
  5167. 'feature_expression' => array(
  5168. 'table' => 'feature_expression',
  5169. 'columns' => array(
  5170. 'feature_expression_id' => 'feature_expression_id',
  5171. ),
  5172. ),
  5173. ),
  5174. );
  5175. return $description;
  5176. }
  5177. /**
  5178. * Implements hook_chado_schema_v1_2_feature_genotype()
  5179. * Purpose: To describe the structure of 'feature_genotype' to tripal
  5180. * @see tripal_core_chado_insert()
  5181. * @see tripal_core_chado_update()
  5182. * @see tripal_core_chado_select()
  5183. *
  5184. * @return
  5185. * An array describing the 'feature_genotype' table
  5186. *
  5187. * @ingroup tripal_chado_v1.2_schema_api
  5188. *
  5189. */
  5190. function tripal_core_chado_schema_v1_2_feature_genotype() {
  5191. $description = array(
  5192. 'description' => 'TODO: please describe this table!',
  5193. 'fields' => array(
  5194. 'feature_genotype_id' => array(
  5195. 'description' => 'TODO: please describe this field!',
  5196. 'type' => 'serial',
  5197. 'not null' => TRUE,
  5198. ),
  5199. 'feature_id' => array(
  5200. 'description' => 'TODO: please describe this field!',
  5201. 'type' => 'int',
  5202. 'not null' => TRUE,
  5203. ),
  5204. 'genotype_id' => array(
  5205. 'description' => 'TODO: please describe this field!',
  5206. 'type' => 'int',
  5207. 'not null' => TRUE,
  5208. ),
  5209. 'chromosome_id' => array(
  5210. 'description' => 'TODO: please describe this field!',
  5211. 'type' => 'int',
  5212. 'not null' => FALSE,
  5213. ),
  5214. 'rank' => array(
  5215. 'description' => 'TODO: please describe this field!',
  5216. 'type' => 'int',
  5217. 'not null' => TRUE,
  5218. ),
  5219. 'cgroup' => array(
  5220. 'description' => 'TODO: please describe this field!',
  5221. 'type' => 'int',
  5222. 'not null' => TRUE,
  5223. ),
  5224. 'cvterm_id' => array(
  5225. 'description' => 'TODO: please describe this field!',
  5226. 'type' => 'int',
  5227. 'not null' => TRUE,
  5228. ),
  5229. ),
  5230. 'primary key' => array(
  5231. 0 => 'feature_genotype_id',
  5232. ),
  5233. 'unique keys' => array(
  5234. 'feature_genotype_c1' => array(
  5235. 0 => 'feature_id',
  5236. 1 => 'genotype_id',
  5237. 2 => 'cvterm_id',
  5238. 3 => 'chromosome_id',
  5239. 4 => 'rank',
  5240. 5 => 'cgroup',
  5241. ),
  5242. ),
  5243. 'indexes' => array(
  5244. 'feature_genotype_idx1' => array(
  5245. 0 => 'feature_id',
  5246. ),
  5247. 'feature_genotype_idx2' => array(
  5248. 0 => 'genotype_id',
  5249. ),
  5250. ),
  5251. 'foreign keys' => array(
  5252. 'cvterm' => array(
  5253. 'table' => 'cvterm',
  5254. 'columns' => array(
  5255. 'cvterm_id' => 'cvterm_id',
  5256. ),
  5257. ),
  5258. 'feature' => array(
  5259. 'table' => 'feature',
  5260. 'columns' => array(
  5261. 'feature_id' => 'feature_id',
  5262. 'chromosome_id' => 'feature_id',
  5263. ),
  5264. ),
  5265. 'genotype' => array(
  5266. 'table' => 'genotype',
  5267. 'columns' => array(
  5268. 'genotype_id' => 'genotype_id',
  5269. ),
  5270. ),
  5271. ),
  5272. );
  5273. return $description;
  5274. }
  5275. /**
  5276. * Implements hook_chado_schema_v1_2_feature_phenotype()
  5277. * Purpose: To describe the structure of 'feature_phenotype' to tripal
  5278. * @see tripal_core_chado_insert()
  5279. * @see tripal_core_chado_update()
  5280. * @see tripal_core_chado_select()
  5281. *
  5282. * @return
  5283. * An array describing the 'feature_phenotype' table
  5284. *
  5285. * @ingroup tripal_chado_v1.2_schema_api
  5286. *
  5287. */
  5288. function tripal_core_chado_schema_v1_2_feature_phenotype() {
  5289. $description = array(
  5290. 'description' => 'TODO: please describe this table!',
  5291. 'fields' => array(
  5292. 'feature_phenotype_id' => array(
  5293. 'description' => 'TODO: please describe this field!',
  5294. 'type' => 'serial',
  5295. 'not null' => TRUE,
  5296. ),
  5297. 'feature_id' => array(
  5298. 'description' => 'TODO: please describe this field!',
  5299. 'type' => 'int',
  5300. 'not null' => TRUE,
  5301. ),
  5302. 'phenotype_id' => array(
  5303. 'description' => 'TODO: please describe this field!',
  5304. 'type' => 'int',
  5305. 'not null' => TRUE,
  5306. ),
  5307. ),
  5308. 'primary key' => array(
  5309. 0 => 'feature_phenotype_id',
  5310. ),
  5311. 'unique keys' => array(
  5312. 'feature_phenotype_c1' => array(
  5313. 0 => 'feature_id',
  5314. 1 => 'phenotype_id',
  5315. ),
  5316. ),
  5317. 'indexes' => array(
  5318. 'feature_phenotype_idx1' => array(
  5319. 0 => 'feature_id',
  5320. ),
  5321. 'feature_phenotype_idx2' => array(
  5322. 0 => 'phenotype_id',
  5323. ),
  5324. ),
  5325. 'foreign keys' => array(
  5326. 'feature' => array(
  5327. 'table' => 'feature',
  5328. 'columns' => array(
  5329. 'feature_id' => 'feature_id',
  5330. ),
  5331. ),
  5332. 'phenotype' => array(
  5333. 'table' => 'phenotype',
  5334. 'columns' => array(
  5335. 'phenotype_id' => 'phenotype_id',
  5336. ),
  5337. ),
  5338. ),
  5339. );
  5340. return $description;
  5341. }
  5342. /**
  5343. * Implements hook_chado_schema_v1_2_feature_pub()
  5344. * Purpose: To describe the structure of 'feature_pub' to tripal
  5345. * @see tripal_core_chado_insert()
  5346. * @see tripal_core_chado_update()
  5347. * @see tripal_core_chado_select()
  5348. *
  5349. * @return
  5350. * An array describing the 'feature_pub' table
  5351. *
  5352. * @ingroup tripal_chado_v1.2_schema_api
  5353. *
  5354. */
  5355. function tripal_core_chado_schema_v1_2_feature_pub() {
  5356. $description = array(
  5357. 'description' => 'TODO: please describe this table!',
  5358. 'fields' => array(
  5359. 'feature_pub_id' => array(
  5360. 'description' => 'TODO: please describe this field!',
  5361. 'type' => 'serial',
  5362. 'not null' => TRUE,
  5363. ),
  5364. 'feature_id' => array(
  5365. 'description' => 'TODO: please describe this field!',
  5366. 'type' => 'int',
  5367. 'not null' => TRUE,
  5368. ),
  5369. 'pub_id' => array(
  5370. 'description' => 'TODO: please describe this field!',
  5371. 'type' => 'int',
  5372. 'not null' => TRUE,
  5373. ),
  5374. ),
  5375. 'primary key' => array(
  5376. 0 => 'feature_pub_id',
  5377. ),
  5378. 'unique keys' => array(
  5379. 'feature_pub_c1' => array(
  5380. 0 => 'feature_id',
  5381. 1 => 'pub_id',
  5382. ),
  5383. ),
  5384. 'indexes' => array(
  5385. 'feature_pub_idx1' => array(
  5386. 0 => 'feature_id',
  5387. ),
  5388. 'feature_pub_idx2' => array(
  5389. 0 => 'pub_id',
  5390. ),
  5391. ),
  5392. 'foreign keys' => array(
  5393. 'pub' => array(
  5394. 'table' => 'pub',
  5395. 'columns' => array(
  5396. 'pub_id' => 'pub_id',
  5397. ),
  5398. ),
  5399. 'feature' => array(
  5400. 'table' => 'feature',
  5401. 'columns' => array(
  5402. 'feature_id' => 'feature_id',
  5403. ),
  5404. ),
  5405. ),
  5406. );
  5407. return $description;
  5408. }
  5409. /**
  5410. * Implements hook_chado_schema_v1_2_feature_pubprop()
  5411. * Purpose: To describe the structure of 'feature_pubprop' to tripal
  5412. * @see tripal_core_chado_insert()
  5413. * @see tripal_core_chado_update()
  5414. * @see tripal_core_chado_select()
  5415. *
  5416. * @return
  5417. * An array describing the 'feature_pubprop' table
  5418. *
  5419. * @ingroup tripal_chado_v1.2_schema_api
  5420. *
  5421. */
  5422. function tripal_core_chado_schema_v1_2_feature_pubprop() {
  5423. $description = array(
  5424. 'description' => 'TODO: please describe this table!',
  5425. 'fields' => array(
  5426. 'feature_pubprop_id' => array(
  5427. 'description' => 'TODO: please describe this field!',
  5428. 'type' => 'serial',
  5429. 'not null' => TRUE,
  5430. ),
  5431. 'feature_pub_id' => array(
  5432. 'description' => 'TODO: please describe this field!',
  5433. 'type' => 'int',
  5434. 'not null' => TRUE,
  5435. ),
  5436. 'type_id' => array(
  5437. 'description' => 'TODO: please describe this field!',
  5438. 'type' => 'int',
  5439. 'not null' => TRUE,
  5440. ),
  5441. 'value' => array(
  5442. 'description' => 'TODO: please describe this field!',
  5443. 'type' => 'text',
  5444. 'not null' => FALSE,
  5445. ),
  5446. 'rank' => array(
  5447. 'description' => 'TODO: please describe this field!',
  5448. 'type' => 'int',
  5449. 'not null' => TRUE,
  5450. 'default' => 0,
  5451. ),
  5452. ),
  5453. 'primary key' => array(
  5454. 0 => 'feature_pubprop_id',
  5455. ),
  5456. 'unique keys' => array(
  5457. 'feature_pubprop_c1' => array(
  5458. 0 => 'feature_pub_id',
  5459. 1 => 'type_id',
  5460. 2 => 'rank',
  5461. ),
  5462. ),
  5463. 'indexes' => array(
  5464. 'feature_pubprop_idx1' => array(
  5465. 0 => 'feature_pub_id',
  5466. ),
  5467. ),
  5468. 'foreign keys' => array(
  5469. 'cvterm' => array(
  5470. 'table' => 'cvterm',
  5471. 'columns' => array(
  5472. 'type_id' => 'cvterm_id',
  5473. ),
  5474. ),
  5475. 'feature_pub' => array(
  5476. 'table' => 'feature_pub',
  5477. 'columns' => array(
  5478. 'feature_pub_id' => 'feature_pub_id',
  5479. ),
  5480. ),
  5481. ),
  5482. );
  5483. return $description;
  5484. }
  5485. /**
  5486. * Implements hook_chado_schema_v1_2_feature_relationship()
  5487. * Purpose: To describe the structure of 'feature_relationship' to tripal
  5488. * @see tripal_core_chado_insert()
  5489. * @see tripal_core_chado_update()
  5490. * @see tripal_core_chado_select()
  5491. *
  5492. * @return
  5493. * An array describing the 'feature_relationship' table
  5494. *
  5495. * @ingroup tripal_chado_v1.2_schema_api
  5496. *
  5497. */
  5498. function tripal_core_chado_schema_v1_2_feature_relationship() {
  5499. $description = array(
  5500. 'description' => 'TODO: please describe this table!',
  5501. 'fields' => array(
  5502. 'feature_relationship_id' => array(
  5503. 'description' => 'TODO: please describe this field!',
  5504. 'type' => 'serial',
  5505. 'not null' => TRUE,
  5506. ),
  5507. 'subject_id' => array(
  5508. 'description' => 'TODO: please describe this field!',
  5509. 'type' => 'int',
  5510. 'not null' => TRUE,
  5511. ),
  5512. 'object_id' => array(
  5513. 'description' => 'TODO: please describe this field!',
  5514. 'type' => 'int',
  5515. 'not null' => TRUE,
  5516. ),
  5517. 'type_id' => array(
  5518. 'description' => 'TODO: please describe this field!',
  5519. 'type' => 'int',
  5520. 'not null' => TRUE,
  5521. ),
  5522. 'value' => array(
  5523. 'description' => 'TODO: please describe this field!',
  5524. 'type' => 'text',
  5525. 'not null' => FALSE,
  5526. ),
  5527. 'rank' => array(
  5528. 'description' => 'TODO: please describe this field!',
  5529. 'type' => 'int',
  5530. 'not null' => TRUE,
  5531. 'default' => 0,
  5532. ),
  5533. ),
  5534. 'primary key' => array(
  5535. 0 => 'feature_relationship_id',
  5536. ),
  5537. 'unique keys' => array(
  5538. 'feature_relationship_c1' => array(
  5539. 0 => 'subject_id',
  5540. 1 => 'object_id',
  5541. 2 => 'type_id',
  5542. 3 => 'rank',
  5543. ),
  5544. ),
  5545. 'indexes' => array(
  5546. 'feature_relationship_idx1' => array(
  5547. 0 => 'subject_id',
  5548. ),
  5549. 'feature_relationship_idx2' => array(
  5550. 0 => 'object_id',
  5551. ),
  5552. 'feature_relationship_idx3' => array(
  5553. 0 => 'type_id',
  5554. ),
  5555. ),
  5556. 'foreign keys' => array(
  5557. 'cvterm' => array(
  5558. 'table' => 'cvterm',
  5559. 'columns' => array(
  5560. 'type_id' => 'cvterm_id',
  5561. ),
  5562. ),
  5563. 'feature' => array(
  5564. 'table' => 'feature',
  5565. 'columns' => array(
  5566. 'subject_id' => 'feature_id',
  5567. 'object_id' => 'feature_id',
  5568. ),
  5569. ),
  5570. ),
  5571. );
  5572. return $description;
  5573. }
  5574. /**
  5575. * Implements hook_chado_schema_v1_2_feature_relationship_pub()
  5576. * Purpose: To describe the structure of 'feature_relationship_pub' to tripal
  5577. * @see tripal_core_chado_insert()
  5578. * @see tripal_core_chado_update()
  5579. * @see tripal_core_chado_select()
  5580. *
  5581. * @return
  5582. * An array describing the 'feature_relationship_pub' table
  5583. *
  5584. * @ingroup tripal_chado_v1.2_schema_api
  5585. *
  5586. */
  5587. function tripal_core_chado_schema_v1_2_feature_relationship_pub() {
  5588. $description = array(
  5589. 'description' => 'TODO: please describe this table!',
  5590. 'fields' => array(
  5591. 'feature_relationship_pub_id' => array(
  5592. 'description' => 'TODO: please describe this field!',
  5593. 'type' => 'serial',
  5594. 'not null' => TRUE,
  5595. ),
  5596. 'feature_relationship_id' => array(
  5597. 'description' => 'TODO: please describe this field!',
  5598. 'type' => 'int',
  5599. 'not null' => TRUE,
  5600. ),
  5601. 'pub_id' => array(
  5602. 'description' => 'TODO: please describe this field!',
  5603. 'type' => 'int',
  5604. 'not null' => TRUE,
  5605. ),
  5606. ),
  5607. 'primary key' => array(
  5608. 0 => 'feature_relationship_pub_id',
  5609. ),
  5610. 'unique keys' => array(
  5611. 'feature_relationship_pub_c1' => array(
  5612. 0 => 'feature_relationship_id',
  5613. 1 => 'pub_id',
  5614. ),
  5615. ),
  5616. 'indexes' => array(
  5617. 'feature_relationship_pub_idx1' => array(
  5618. 0 => 'feature_relationship_id',
  5619. ),
  5620. 'feature_relationship_pub_idx2' => array(
  5621. 0 => 'pub_id',
  5622. ),
  5623. ),
  5624. 'foreign keys' => array(
  5625. 'feature_relationship' => array(
  5626. 'table' => 'feature_relationship',
  5627. 'columns' => array(
  5628. 'feature_relationship_id' => 'feature_relationship_id',
  5629. ),
  5630. ),
  5631. 'pub' => array(
  5632. 'table' => 'pub',
  5633. 'columns' => array(
  5634. 'pub_id' => 'pub_id',
  5635. ),
  5636. ),
  5637. ),
  5638. );
  5639. return $description;
  5640. }
  5641. /**
  5642. * Implements hook_chado_schema_v1_2_feature_relationshipprop()
  5643. * Purpose: To describe the structure of 'feature_relationshipprop' to tripal
  5644. * @see tripal_core_chado_insert()
  5645. * @see tripal_core_chado_update()
  5646. * @see tripal_core_chado_select()
  5647. *
  5648. * @return
  5649. * An array describing the 'feature_relationshipprop' table
  5650. *
  5651. * @ingroup tripal_chado_v1.2_schema_api
  5652. *
  5653. */
  5654. function tripal_core_chado_schema_v1_2_feature_relationshipprop() {
  5655. $description = array(
  5656. 'description' => 'TODO: please describe this table!',
  5657. 'fields' => array(
  5658. 'feature_relationshipprop_id' => array(
  5659. 'description' => 'TODO: please describe this field!',
  5660. 'type' => 'serial',
  5661. 'not null' => TRUE,
  5662. ),
  5663. 'feature_relationship_id' => array(
  5664. 'description' => 'TODO: please describe this field!',
  5665. 'type' => 'int',
  5666. 'not null' => TRUE,
  5667. ),
  5668. 'type_id' => array(
  5669. 'description' => 'TODO: please describe this field!',
  5670. 'type' => 'int',
  5671. 'not null' => TRUE,
  5672. ),
  5673. 'value' => array(
  5674. 'description' => 'TODO: please describe this field!',
  5675. 'type' => 'text',
  5676. 'not null' => FALSE,
  5677. ),
  5678. 'rank' => array(
  5679. 'description' => 'TODO: please describe this field!',
  5680. 'type' => 'int',
  5681. 'not null' => TRUE,
  5682. 'default' => 0,
  5683. ),
  5684. ),
  5685. 'primary key' => array(
  5686. 0 => 'feature_relationshipprop_id',
  5687. ),
  5688. 'unique keys' => array(
  5689. 'feature_relationshipprop_c1' => array(
  5690. 0 => 'feature_relationship_id',
  5691. 1 => 'type_id',
  5692. 2 => 'rank',
  5693. ),
  5694. ),
  5695. 'indexes' => array(
  5696. 'feature_relationshipprop_idx1' => array(
  5697. 0 => 'feature_relationship_id',
  5698. ),
  5699. 'feature_relationshipprop_idx2' => array(
  5700. 0 => 'type_id',
  5701. ),
  5702. ),
  5703. 'foreign keys' => array(
  5704. 'cvterm' => array(
  5705. 'table' => 'cvterm',
  5706. 'columns' => array(
  5707. 'type_id' => 'cvterm_id',
  5708. ),
  5709. ),
  5710. 'feature_relationship' => array(
  5711. 'table' => 'feature_relationship',
  5712. 'columns' => array(
  5713. 'feature_relationship_id' => 'feature_relationship_id',
  5714. ),
  5715. ),
  5716. ),
  5717. );
  5718. return $description;
  5719. }
  5720. /**
  5721. * Implements hook_chado_schema_v1_2_feature_relationshipprop_pub()
  5722. * Purpose: To describe the structure of 'feature_relationshipprop_pub' to tripal
  5723. * @see tripal_core_chado_insert()
  5724. * @see tripal_core_chado_update()
  5725. * @see tripal_core_chado_select()
  5726. *
  5727. * @return
  5728. * An array describing the 'feature_relationshipprop_pub' table
  5729. *
  5730. * @ingroup tripal_chado_v1.2_schema_api
  5731. *
  5732. */
  5733. function tripal_core_chado_schema_v1_2_feature_relationshipprop_pub() {
  5734. $description = array(
  5735. 'description' => 'TODO: please describe this table!',
  5736. 'fields' => array(
  5737. 'feature_relationshipprop_pub_id' => array(
  5738. 'description' => 'TODO: please describe this field!',
  5739. 'type' => 'serial',
  5740. 'not null' => TRUE,
  5741. ),
  5742. 'feature_relationshipprop_id' => array(
  5743. 'description' => 'TODO: please describe this field!',
  5744. 'type' => 'int',
  5745. 'not null' => TRUE,
  5746. ),
  5747. 'pub_id' => array(
  5748. 'description' => 'TODO: please describe this field!',
  5749. 'type' => 'int',
  5750. 'not null' => TRUE,
  5751. ),
  5752. ),
  5753. 'primary key' => array(
  5754. 0 => 'feature_relationshipprop_pub_id',
  5755. ),
  5756. 'unique keys' => array(
  5757. 'feature_relationshipprop_pub_c1' => array(
  5758. 0 => 'feature_relationshipprop_id',
  5759. 1 => 'pub_id',
  5760. ),
  5761. ),
  5762. 'indexes' => array(
  5763. 'feature_relationshipprop_pub_idx1' => array(
  5764. 0 => 'feature_relationshipprop_id',
  5765. ),
  5766. 'feature_relationshipprop_pub_idx2' => array(
  5767. 0 => 'pub_id',
  5768. ),
  5769. ),
  5770. 'foreign keys' => array(
  5771. 'feature_relationshipprop' => array(
  5772. 'table' => 'feature_relationshipprop',
  5773. 'columns' => array(
  5774. 'feature_relationshipprop_id' => 'feature_relationshipprop_id',
  5775. ),
  5776. ),
  5777. 'pub' => array(
  5778. 'table' => 'pub',
  5779. 'columns' => array(
  5780. 'pub_id' => 'pub_id',
  5781. ),
  5782. ),
  5783. ),
  5784. );
  5785. return $description;
  5786. }
  5787. /**
  5788. * Implements hook_chado_schema_v1_2_feature_synonym()
  5789. * Purpose: To describe the structure of 'feature_synonym' to tripal
  5790. * @see tripal_core_chado_insert()
  5791. * @see tripal_core_chado_update()
  5792. * @see tripal_core_chado_select()
  5793. *
  5794. * @return
  5795. * An array describing the 'feature_synonym' table
  5796. *
  5797. * @ingroup tripal_chado_v1.2_schema_api
  5798. *
  5799. */
  5800. function tripal_core_chado_schema_v1_2_feature_synonym() {
  5801. $description = array(
  5802. 'description' => 'TODO: please describe this table!',
  5803. 'fields' => array(
  5804. 'feature_synonym_id' => array(
  5805. 'description' => 'TODO: please describe this field!',
  5806. 'type' => 'serial',
  5807. 'not null' => TRUE,
  5808. ),
  5809. 'synonym_id' => array(
  5810. 'description' => 'TODO: please describe this field!',
  5811. 'type' => 'int',
  5812. 'not null' => TRUE,
  5813. ),
  5814. 'feature_id' => array(
  5815. 'description' => 'TODO: please describe this field!',
  5816. 'type' => 'int',
  5817. 'not null' => TRUE,
  5818. ),
  5819. 'pub_id' => array(
  5820. 'description' => 'TODO: please describe this field!',
  5821. 'type' => 'int',
  5822. 'not null' => TRUE,
  5823. ),
  5824. 'is_current' => array(
  5825. 'description' => 'TODO: please describe this field!',
  5826. 'type' => 'boolean',
  5827. 'not null' => TRUE,
  5828. 'default' => 'als',
  5829. ),
  5830. 'is_internal' => array(
  5831. 'description' => 'TODO: please describe this field!',
  5832. 'type' => 'boolean',
  5833. 'not null' => TRUE,
  5834. 'default' => 'als',
  5835. ),
  5836. ),
  5837. 'primary key' => array(
  5838. 0 => 'feature_synonym_id',
  5839. ),
  5840. 'unique keys' => array(
  5841. 'feature_synonym_c1' => array(
  5842. 0 => 'synonym_id',
  5843. 1 => 'feature_id',
  5844. 2 => 'pub_id',
  5845. ),
  5846. ),
  5847. 'indexes' => array(
  5848. 'feature_synonym_idx1' => array(
  5849. 0 => 'synonym_id',
  5850. ),
  5851. 'feature_synonym_idx2' => array(
  5852. 0 => 'feature_id',
  5853. ),
  5854. 'feature_synonym_idx3' => array(
  5855. 0 => 'pub_id',
  5856. ),
  5857. ),
  5858. 'foreign keys' => array(
  5859. 'pub' => array(
  5860. 'table' => 'pub',
  5861. 'columns' => array(
  5862. 'pub_id' => 'pub_id',
  5863. ),
  5864. ),
  5865. 'feature' => array(
  5866. 'table' => 'feature',
  5867. 'columns' => array(
  5868. 'feature_id' => 'feature_id',
  5869. ),
  5870. ),
  5871. 'synonym' => array(
  5872. 'table' => 'synonym',
  5873. 'columns' => array(
  5874. 'synonym_id' => 'synonym_id',
  5875. ),
  5876. ),
  5877. ),
  5878. );
  5879. return $description;
  5880. }
  5881. /**
  5882. * Implements hook_chado_schema_v1_2_featureloc()
  5883. * Purpose: To describe the structure of 'featureloc' to tripal
  5884. * @see tripal_core_chado_insert()
  5885. * @see tripal_core_chado_update()
  5886. * @see tripal_core_chado_select()
  5887. *
  5888. * @return
  5889. * An array describing the 'featureloc' table
  5890. *
  5891. * @ingroup tripal_chado_v1.2_schema_api
  5892. *
  5893. */
  5894. function tripal_core_chado_schema_v1_2_featureloc() {
  5895. $description = array(
  5896. 'description' => 'TODO: please describe this table!',
  5897. 'fields' => array(
  5898. 'featureloc_id' => array(
  5899. 'description' => 'TODO: please describe this field!',
  5900. 'type' => 'serial',
  5901. 'not null' => TRUE,
  5902. ),
  5903. 'feature_id' => array(
  5904. 'description' => 'TODO: please describe this field!',
  5905. 'type' => 'int',
  5906. 'not null' => TRUE,
  5907. ),
  5908. 'srcfeature_id' => array(
  5909. 'description' => 'TODO: please describe this field!',
  5910. 'type' => 'int',
  5911. 'not null' => FALSE,
  5912. ),
  5913. 'fmin' => array(
  5914. 'description' => 'TODO: please describe this field!',
  5915. 'type' => 'int',
  5916. 'not null' => FALSE,
  5917. ),
  5918. 'is_fmin_partial' => array(
  5919. 'description' => 'TODO: please describe this field!',
  5920. 'type' => 'boolean',
  5921. 'not null' => TRUE,
  5922. 'default' => 'als',
  5923. ),
  5924. 'fmax' => array(
  5925. 'description' => 'TODO: please describe this field!',
  5926. 'type' => 'int',
  5927. 'not null' => FALSE,
  5928. ),
  5929. 'is_fmax_partial' => array(
  5930. 'description' => 'TODO: please describe this field!',
  5931. 'type' => 'boolean',
  5932. 'not null' => TRUE,
  5933. 'default' => 'als',
  5934. ),
  5935. 'strand' => array(
  5936. 'description' => 'TODO: please describe this field!',
  5937. 'type' => 'int',
  5938. 'size' => 'small',
  5939. 'not null' => FALSE,
  5940. ),
  5941. 'phase' => array(
  5942. 'description' => 'TODO: please describe this field!',
  5943. 'type' => 'int',
  5944. 'not null' => FALSE,
  5945. ),
  5946. 'residue_info' => array(
  5947. 'description' => 'TODO: please describe this field!',
  5948. 'type' => 'text',
  5949. 'not null' => FALSE,
  5950. ),
  5951. 'locgroup' => array(
  5952. 'description' => 'TODO: please describe this field!',
  5953. 'type' => 'int',
  5954. 'not null' => TRUE,
  5955. 'default' => 0,
  5956. ),
  5957. 'rank' => array(
  5958. 'description' => 'TODO: please describe this field!',
  5959. 'type' => 'int',
  5960. 'not null' => TRUE,
  5961. 'default' => 0,
  5962. ),
  5963. ),
  5964. 'primary key' => array(
  5965. 0 => 'featureloc_id',
  5966. ),
  5967. 'unique keys' => array(
  5968. 'featureloc_c1' => array(
  5969. 0 => 'feature_id',
  5970. 1 => 'locgroup',
  5971. 2 => 'rank',
  5972. ),
  5973. ),
  5974. 'indexes' => array(
  5975. 'binloc_boxrange' => array(
  5976. 0 => 'fmin',
  5977. ),
  5978. 'binloc_boxrange_src' => array(
  5979. 0 => 'srcfeature_id',
  5980. 1 => 'fmin',
  5981. ),
  5982. 'featureloc_idx1' => array(
  5983. 0 => 'feature_id',
  5984. ),
  5985. 'featureloc_idx2' => array(
  5986. 0 => 'srcfeature_id',
  5987. ),
  5988. 'featureloc_idx3' => array(
  5989. 0 => 'srcfeature_id',
  5990. 1 => 'fmin',
  5991. 2 => 'fmax',
  5992. ),
  5993. ),
  5994. 'foreign keys' => array(
  5995. 'feature' => array(
  5996. 'table' => 'feature',
  5997. 'columns' => array(
  5998. 'feature_id' => 'feature_id',
  5999. 'srcfeature_id' => 'feature_id',
  6000. ),
  6001. ),
  6002. ),
  6003. );
  6004. return $description;
  6005. }
  6006. /**
  6007. * Implements hook_chado_schema_v1_2_featureloc_pub()
  6008. * Purpose: To describe the structure of 'featureloc_pub' to tripal
  6009. * @see tripal_core_chado_insert()
  6010. * @see tripal_core_chado_update()
  6011. * @see tripal_core_chado_select()
  6012. *
  6013. * @return
  6014. * An array describing the 'featureloc_pub' table
  6015. *
  6016. * @ingroup tripal_chado_v1.2_schema_api
  6017. *
  6018. */
  6019. function tripal_core_chado_schema_v1_2_featureloc_pub() {
  6020. $description = array(
  6021. 'description' => 'TODO: please describe this table!',
  6022. 'fields' => array(
  6023. 'featureloc_pub_id' => array(
  6024. 'description' => 'TODO: please describe this field!',
  6025. 'type' => 'serial',
  6026. 'not null' => TRUE,
  6027. ),
  6028. 'featureloc_id' => array(
  6029. 'description' => 'TODO: please describe this field!',
  6030. 'type' => 'int',
  6031. 'not null' => TRUE,
  6032. ),
  6033. 'pub_id' => array(
  6034. 'description' => 'TODO: please describe this field!',
  6035. 'type' => 'int',
  6036. 'not null' => TRUE,
  6037. ),
  6038. ),
  6039. 'primary key' => array(
  6040. 0 => 'featureloc_pub_id',
  6041. ),
  6042. 'unique keys' => array(
  6043. 'featureloc_pub_c1' => array(
  6044. 0 => 'featureloc_id',
  6045. 1 => 'pub_id',
  6046. ),
  6047. ),
  6048. 'indexes' => array(
  6049. 'featureloc_pub_idx1' => array(
  6050. 0 => 'featureloc_id',
  6051. ),
  6052. 'featureloc_pub_idx2' => array(
  6053. 0 => 'pub_id',
  6054. ),
  6055. ),
  6056. 'foreign keys' => array(
  6057. 'featureloc' => array(
  6058. 'table' => 'featureloc',
  6059. 'columns' => array(
  6060. 'featureloc_id' => 'featureloc_id',
  6061. ),
  6062. ),
  6063. 'pub' => array(
  6064. 'table' => 'pub',
  6065. 'columns' => array(
  6066. 'pub_id' => 'pub_id',
  6067. ),
  6068. ),
  6069. ),
  6070. );
  6071. return $description;
  6072. }
  6073. /**
  6074. * Implements hook_chado_schema_v1_2_featuremap()
  6075. * Purpose: To describe the structure of 'featuremap' to tripal
  6076. * @see tripal_core_chado_insert()
  6077. * @see tripal_core_chado_update()
  6078. * @see tripal_core_chado_select()
  6079. *
  6080. * @return
  6081. * An array describing the 'featuremap' table
  6082. *
  6083. * @ingroup tripal_chado_v1.2_schema_api
  6084. *
  6085. */
  6086. function tripal_core_chado_schema_v1_2_featuremap() {
  6087. $description = array(
  6088. 'description' => 'TODO: please describe this table!',
  6089. 'fields' => array(
  6090. 'featuremap_id' => array(
  6091. 'description' => 'TODO: please describe this field!',
  6092. 'type' => 'serial',
  6093. 'not null' => TRUE,
  6094. ),
  6095. 'name' => array(
  6096. 'description' => 'TODO: please describe this field!',
  6097. 'type' => 'varchar',
  6098. 'length' => '255',
  6099. 'not null' => FALSE,
  6100. ),
  6101. 'description' => array(
  6102. 'description' => 'TODO: please describe this field!',
  6103. 'type' => 'text',
  6104. 'not null' => FALSE,
  6105. ),
  6106. 'unittype_id' => array(
  6107. 'description' => 'TODO: please describe this field!',
  6108. 'type' => 'int',
  6109. 'not null' => FALSE,
  6110. ),
  6111. ),
  6112. 'primary key' => array(
  6113. 0 => 'featuremap_id',
  6114. ),
  6115. 'unique keys' => array(
  6116. 'featuremap_c1' => array(
  6117. 0 => 'name',
  6118. ),
  6119. ),
  6120. 'foreign keys' => array(
  6121. 'cvterm' => array(
  6122. 'table' => 'cvterm',
  6123. 'columns' => array(
  6124. 'unittype_id' => 'cvterm_id',
  6125. ),
  6126. ),
  6127. ),
  6128. );
  6129. return $description;
  6130. }
  6131. /**
  6132. * Implements hook_chado_schema_v1_2_featuremap_pub()
  6133. * Purpose: To describe the structure of 'featuremap_pub' to tripal
  6134. * @see tripal_core_chado_insert()
  6135. * @see tripal_core_chado_update()
  6136. * @see tripal_core_chado_select()
  6137. *
  6138. * @return
  6139. * An array describing the 'featuremap_pub' table
  6140. *
  6141. * @ingroup tripal_chado_v1.2_schema_api
  6142. *
  6143. */
  6144. function tripal_core_chado_schema_v1_2_featuremap_pub() {
  6145. $description = array(
  6146. 'description' => 'TODO: please describe this table!',
  6147. 'fields' => array(
  6148. 'featuremap_pub_id' => array(
  6149. 'description' => 'TODO: please describe this field!',
  6150. 'type' => 'serial',
  6151. 'not null' => TRUE,
  6152. ),
  6153. 'featuremap_id' => array(
  6154. 'description' => 'TODO: please describe this field!',
  6155. 'type' => 'int',
  6156. 'not null' => TRUE,
  6157. ),
  6158. 'pub_id' => array(
  6159. 'description' => 'TODO: please describe this field!',
  6160. 'type' => 'int',
  6161. 'not null' => TRUE,
  6162. ),
  6163. ),
  6164. 'primary key' => array(
  6165. 0 => 'featuremap_pub_id',
  6166. ),
  6167. 'indexes' => array(
  6168. 'featuremap_pub_idx1' => array(
  6169. 0 => 'featuremap_id',
  6170. ),
  6171. 'featuremap_pub_idx2' => array(
  6172. 0 => 'pub_id',
  6173. ),
  6174. ),
  6175. 'foreign keys' => array(
  6176. 'pub' => array(
  6177. 'table' => 'pub',
  6178. 'columns' => array(
  6179. 'pub_id' => 'pub_id',
  6180. ),
  6181. ),
  6182. 'featuremap' => array(
  6183. 'table' => 'featuremap',
  6184. 'columns' => array(
  6185. 'featuremap_id' => 'featuremap_id',
  6186. ),
  6187. ),
  6188. ),
  6189. );
  6190. return $description;
  6191. }
  6192. /**
  6193. * Implements hook_chado_schema_v1_2_featurepos()
  6194. * Purpose: To describe the structure of 'featurepos' to tripal
  6195. * @see tripal_core_chado_insert()
  6196. * @see tripal_core_chado_update()
  6197. * @see tripal_core_chado_select()
  6198. *
  6199. * @return
  6200. * An array describing the 'featurepos' table
  6201. *
  6202. * @ingroup tripal_chado_v1.2_schema_api
  6203. *
  6204. */
  6205. function tripal_core_chado_schema_v1_2_featurepos() {
  6206. $description = array(
  6207. 'description' => 'TODO: please describe this table!',
  6208. 'fields' => array(
  6209. 'featurepos_id' => array(
  6210. 'description' => 'TODO: please describe this field!',
  6211. 'type' => 'serial',
  6212. 'not null' => TRUE,
  6213. ),
  6214. 'featuremap_id' => array(
  6215. 'description' => 'TODO: please describe this field!',
  6216. 'type' => 'serial',
  6217. 'not null' => TRUE,
  6218. ),
  6219. 'feature_id' => array(
  6220. 'description' => 'TODO: please describe this field!',
  6221. 'type' => 'int',
  6222. 'not null' => TRUE,
  6223. ),
  6224. 'map_feature_id' => array(
  6225. 'description' => 'TODO: please describe this field!',
  6226. 'type' => 'int',
  6227. 'not null' => TRUE,
  6228. ),
  6229. 'mappos' => array(
  6230. 'description' => 'TODO: please describe this field!',
  6231. 'type' => 'float',
  6232. 'size' => 'big',
  6233. 'not null' => TRUE,
  6234. ),
  6235. ),
  6236. 'primary key' => array(
  6237. 0 => 'featurepos_id',
  6238. ),
  6239. 'indexes' => array(
  6240. 'featurepos_idx1' => array(
  6241. 0 => 'featuremap_id',
  6242. ),
  6243. 'featurepos_idx2' => array(
  6244. 0 => 'feature_id',
  6245. ),
  6246. 'featurepos_idx3' => array(
  6247. 0 => 'map_feature_id',
  6248. ),
  6249. ),
  6250. 'foreign keys' => array(
  6251. 'feature' => array(
  6252. 'table' => 'feature',
  6253. 'columns' => array(
  6254. 'feature_id' => 'feature_id',
  6255. 'map_feature_id' => 'feature_id',
  6256. ),
  6257. ),
  6258. 'featuremap' => array(
  6259. 'table' => 'featuremap',
  6260. 'columns' => array(
  6261. 'featuremap_id' => 'featuremap_id',
  6262. ),
  6263. ),
  6264. ),
  6265. );
  6266. return $description;
  6267. }
  6268. /**
  6269. * Implements hook_chado_schema_v1_2_featureprop()
  6270. * Purpose: To describe the structure of 'featureprop' to tripal
  6271. * @see tripal_core_chado_insert()
  6272. * @see tripal_core_chado_update()
  6273. * @see tripal_core_chado_select()
  6274. *
  6275. * @return
  6276. * An array describing the 'featureprop' table
  6277. *
  6278. * @ingroup tripal_chado_v1.2_schema_api
  6279. *
  6280. */
  6281. function tripal_core_chado_schema_v1_2_featureprop() {
  6282. $description = array(
  6283. 'description' => 'TODO: please describe this table!',
  6284. 'fields' => array(
  6285. 'featureprop_id' => array(
  6286. 'description' => 'TODO: please describe this field!',
  6287. 'type' => 'serial',
  6288. 'not null' => TRUE,
  6289. ),
  6290. 'feature_id' => array(
  6291. 'description' => 'TODO: please describe this field!',
  6292. 'type' => 'int',
  6293. 'not null' => TRUE,
  6294. ),
  6295. 'type_id' => array(
  6296. 'description' => 'TODO: please describe this field!',
  6297. 'type' => 'int',
  6298. 'not null' => TRUE,
  6299. ),
  6300. 'value' => array(
  6301. 'description' => 'TODO: please describe this field!',
  6302. 'type' => 'text',
  6303. 'not null' => FALSE,
  6304. ),
  6305. 'rank' => array(
  6306. 'description' => 'TODO: please describe this field!',
  6307. 'type' => 'int',
  6308. 'not null' => TRUE,
  6309. 'default' => 0,
  6310. ),
  6311. ),
  6312. 'primary key' => array(
  6313. 0 => 'featureprop_id',
  6314. ),
  6315. 'unique keys' => array(
  6316. 'featureprop_c1' => array(
  6317. 0 => 'feature_id',
  6318. 1 => 'type_id',
  6319. 2 => 'rank',
  6320. ),
  6321. ),
  6322. 'indexes' => array(
  6323. 'featureprop_idx1' => array(
  6324. 0 => 'feature_id',
  6325. ),
  6326. 'featureprop_idx2' => array(
  6327. 0 => 'type_id',
  6328. ),
  6329. ),
  6330. 'foreign keys' => array(
  6331. 'cvterm' => array(
  6332. 'table' => 'cvterm',
  6333. 'columns' => array(
  6334. 'type_id' => 'cvterm_id',
  6335. ),
  6336. ),
  6337. 'feature' => array(
  6338. 'table' => 'feature',
  6339. 'columns' => array(
  6340. 'feature_id' => 'feature_id',
  6341. ),
  6342. ),
  6343. ),
  6344. );
  6345. return $description;
  6346. }
  6347. /**
  6348. * Implements hook_chado_schema_v1_2_featureprop_pub()
  6349. * Purpose: To describe the structure of 'featureprop_pub' to tripal
  6350. * @see tripal_core_chado_insert()
  6351. * @see tripal_core_chado_update()
  6352. * @see tripal_core_chado_select()
  6353. *
  6354. * @return
  6355. * An array describing the 'featureprop_pub' table
  6356. *
  6357. * @ingroup tripal_chado_v1.2_schema_api
  6358. *
  6359. */
  6360. function tripal_core_chado_schema_v1_2_featureprop_pub() {
  6361. $description = array(
  6362. 'description' => 'TODO: please describe this table!',
  6363. 'fields' => array(
  6364. 'featureprop_pub_id' => array(
  6365. 'description' => 'TODO: please describe this field!',
  6366. 'type' => 'serial',
  6367. 'not null' => TRUE,
  6368. ),
  6369. 'featureprop_id' => array(
  6370. 'description' => 'TODO: please describe this field!',
  6371. 'type' => 'int',
  6372. 'not null' => TRUE,
  6373. ),
  6374. 'pub_id' => array(
  6375. 'description' => 'TODO: please describe this field!',
  6376. 'type' => 'int',
  6377. 'not null' => TRUE,
  6378. ),
  6379. ),
  6380. 'primary key' => array(
  6381. 0 => 'featureprop_pub_id',
  6382. ),
  6383. 'unique keys' => array(
  6384. 'featureprop_pub_c1' => array(
  6385. 0 => 'featureprop_id',
  6386. 1 => 'pub_id',
  6387. ),
  6388. ),
  6389. 'indexes' => array(
  6390. 'featureprop_pub_idx1' => array(
  6391. 0 => 'featureprop_id',
  6392. ),
  6393. 'featureprop_pub_idx2' => array(
  6394. 0 => 'pub_id',
  6395. ),
  6396. ),
  6397. 'foreign keys' => array(
  6398. 'featureprop' => array(
  6399. 'table' => 'featureprop',
  6400. 'columns' => array(
  6401. 'featureprop_id' => 'featureprop_id',
  6402. ),
  6403. ),
  6404. 'pub' => array(
  6405. 'table' => 'pub',
  6406. 'columns' => array(
  6407. 'pub_id' => 'pub_id',
  6408. ),
  6409. ),
  6410. ),
  6411. );
  6412. return $description;
  6413. }
  6414. /**
  6415. * Implements hook_chado_schema_v1_2_featurerange()
  6416. * Purpose: To describe the structure of 'featurerange' to tripal
  6417. * @see tripal_core_chado_insert()
  6418. * @see tripal_core_chado_update()
  6419. * @see tripal_core_chado_select()
  6420. *
  6421. * @return
  6422. * An array describing the 'featurerange' table
  6423. *
  6424. * @ingroup tripal_chado_v1.2_schema_api
  6425. *
  6426. */
  6427. function tripal_core_chado_schema_v1_2_featurerange() {
  6428. $description = array(
  6429. 'description' => 'TODO: please describe this table!',
  6430. 'fields' => array(
  6431. 'featurerange_id' => array(
  6432. 'description' => 'TODO: please describe this field!',
  6433. 'type' => 'serial',
  6434. 'not null' => TRUE,
  6435. ),
  6436. 'featuremap_id' => array(
  6437. 'description' => 'TODO: please describe this field!',
  6438. 'type' => 'int',
  6439. 'not null' => TRUE,
  6440. ),
  6441. 'feature_id' => array(
  6442. 'description' => 'TODO: please describe this field!',
  6443. 'type' => 'int',
  6444. 'not null' => TRUE,
  6445. ),
  6446. 'leftstartf_id' => array(
  6447. 'description' => 'TODO: please describe this field!',
  6448. 'type' => 'int',
  6449. 'not null' => TRUE,
  6450. ),
  6451. 'leftendf_id' => array(
  6452. 'description' => 'TODO: please describe this field!',
  6453. 'type' => 'int',
  6454. 'not null' => FALSE,
  6455. ),
  6456. 'rightstartf_id' => array(
  6457. 'description' => 'TODO: please describe this field!',
  6458. 'type' => 'int',
  6459. 'not null' => FALSE,
  6460. ),
  6461. 'rightendf_id' => array(
  6462. 'description' => 'TODO: please describe this field!',
  6463. 'type' => 'int',
  6464. 'not null' => TRUE,
  6465. ),
  6466. 'rangestr' => array(
  6467. 'description' => 'TODO: please describe this field!',
  6468. 'type' => 'varchar',
  6469. 'length' => '255',
  6470. 'not null' => FALSE,
  6471. ),
  6472. ),
  6473. 'primary key' => array(
  6474. 0 => 'featurerange_id',
  6475. ),
  6476. 'indexes' => array(
  6477. 'featurerange_idx1' => array(
  6478. 0 => 'featuremap_id',
  6479. ),
  6480. 'featurerange_idx2' => array(
  6481. 0 => 'feature_id',
  6482. ),
  6483. 'featurerange_idx3' => array(
  6484. 0 => 'leftstartf_id',
  6485. ),
  6486. 'featurerange_idx4' => array(
  6487. 0 => 'leftendf_id',
  6488. ),
  6489. 'featurerange_idx5' => array(
  6490. 0 => 'rightstartf_id',
  6491. ),
  6492. 'featurerange_idx6' => array(
  6493. 0 => 'rightendf_id',
  6494. ),
  6495. ),
  6496. 'foreign keys' => array(
  6497. 'feature' => array(
  6498. 'table' => 'feature',
  6499. 'columns' => array(
  6500. 'feature_id' => 'feature_id',
  6501. 'leftstartf_id' => 'feature_id',
  6502. 'leftendf_id' => 'feature_id',
  6503. 'rightstartf_id' => 'feature_id',
  6504. 'rightendf_id' => 'feature_id',
  6505. ),
  6506. ),
  6507. 'featuremap' => array(
  6508. 'table' => 'featuremap',
  6509. 'columns' => array(
  6510. 'featuremap_id' => 'featuremap_id',
  6511. ),
  6512. ),
  6513. ),
  6514. );
  6515. return $description;
  6516. }
  6517. /**
  6518. * Implements hook_chado_schema_v1_2_genotype()
  6519. * Purpose: To describe the structure of 'genotype' to tripal
  6520. * @see tripal_core_chado_insert()
  6521. * @see tripal_core_chado_update()
  6522. * @see tripal_core_chado_select()
  6523. *
  6524. * @return
  6525. * An array describing the 'genotype' table
  6526. *
  6527. * @ingroup tripal_chado_v1.2_schema_api
  6528. *
  6529. */
  6530. function tripal_core_chado_schema_v1_2_genotype() {
  6531. $description = array(
  6532. 'description' => 'TODO: please describe this table!',
  6533. 'fields' => array(
  6534. 'genotype_id' => array(
  6535. 'description' => 'TODO: please describe this field!',
  6536. 'type' => 'serial',
  6537. 'not null' => TRUE,
  6538. ),
  6539. 'name' => array(
  6540. 'description' => 'TODO: please describe this field!',
  6541. 'type' => 'text',
  6542. 'not null' => FALSE,
  6543. ),
  6544. 'uniquename' => array(
  6545. 'description' => 'TODO: please describe this field!',
  6546. 'type' => 'text',
  6547. 'not null' => TRUE,
  6548. ),
  6549. 'description' => array(
  6550. 'description' => 'TODO: please describe this field!',
  6551. 'type' => 'varchar',
  6552. 'length' => '255',
  6553. 'not null' => FALSE,
  6554. ),
  6555. 'type_id' => array(
  6556. 'description' => 'TODO: please describe this field!',
  6557. 'type' => 'int',
  6558. 'not null' => TRUE,
  6559. ),
  6560. ),
  6561. 'primary key' => array(
  6562. 0 => 'genotype_id',
  6563. ),
  6564. 'unique keys' => array(
  6565. 'genotype_c1' => array(
  6566. 0 => 'uniquename',
  6567. ),
  6568. ),
  6569. 'indexes' => array(
  6570. 'genotype_idx1' => array(
  6571. 0 => 'uniquename',
  6572. ),
  6573. 'genotype_idx2' => array(
  6574. 0 => 'name',
  6575. ),
  6576. ),
  6577. 'foreign keys' => array(
  6578. 'cvterm' => array(
  6579. 'table' => 'cvterm',
  6580. 'columns' => array(
  6581. 'type_id' => 'cvterm_id',
  6582. ),
  6583. ),
  6584. ),
  6585. );
  6586. return $description;
  6587. }
  6588. /**
  6589. * Implements hook_chado_schema_v1_2_genotypeprop()
  6590. * Purpose: To describe the structure of 'genotypeprop' to tripal
  6591. * @see tripal_core_chado_insert()
  6592. * @see tripal_core_chado_update()
  6593. * @see tripal_core_chado_select()
  6594. *
  6595. * @return
  6596. * An array describing the 'genotypeprop' table
  6597. *
  6598. * @ingroup tripal_chado_v1.2_schema_api
  6599. *
  6600. */
  6601. function tripal_core_chado_schema_v1_2_genotypeprop() {
  6602. $description = array(
  6603. 'description' => 'TODO: please describe this table!',
  6604. 'fields' => array(
  6605. 'genotypeprop_id' => array(
  6606. 'description' => 'TODO: please describe this field!',
  6607. 'type' => 'serial',
  6608. 'not null' => TRUE,
  6609. ),
  6610. 'genotype_id' => array(
  6611. 'description' => 'TODO: please describe this field!',
  6612. 'type' => 'int',
  6613. 'not null' => TRUE,
  6614. ),
  6615. 'type_id' => array(
  6616. 'description' => 'TODO: please describe this field!',
  6617. 'type' => 'int',
  6618. 'not null' => TRUE,
  6619. ),
  6620. 'value' => array(
  6621. 'description' => 'TODO: please describe this field!',
  6622. 'type' => 'text',
  6623. 'not null' => FALSE,
  6624. ),
  6625. 'rank' => array(
  6626. 'description' => 'TODO: please describe this field!',
  6627. 'type' => 'int',
  6628. 'not null' => TRUE,
  6629. 'default' => 0,
  6630. ),
  6631. ),
  6632. 'primary key' => array(
  6633. 0 => 'genotypeprop_id',
  6634. ),
  6635. 'unique keys' => array(
  6636. 'genotypeprop_c1' => array(
  6637. 0 => 'genotype_id',
  6638. 1 => 'type_id',
  6639. 2 => 'rank',
  6640. ),
  6641. ),
  6642. 'indexes' => array(
  6643. 'genotypeprop_idx1' => array(
  6644. 0 => 'genotype_id',
  6645. ),
  6646. 'genotypeprop_idx2' => array(
  6647. 0 => 'type_id',
  6648. ),
  6649. ),
  6650. 'foreign keys' => array(
  6651. 'cvterm' => array(
  6652. 'table' => 'cvterm',
  6653. 'columns' => array(
  6654. 'type_id' => 'cvterm_id',
  6655. ),
  6656. ),
  6657. 'genotype' => array(
  6658. 'table' => 'genotype',
  6659. 'columns' => array(
  6660. 'genotype_id' => 'genotype_id',
  6661. ),
  6662. ),
  6663. ),
  6664. );
  6665. return $description;
  6666. }
  6667. /**
  6668. * Implements hook_chado_schema_v1_2_library()
  6669. * Purpose: To describe the structure of 'library' to tripal
  6670. * @see tripal_core_chado_insert()
  6671. * @see tripal_core_chado_update()
  6672. * @see tripal_core_chado_select()
  6673. *
  6674. * @return
  6675. * An array describing the 'library' table
  6676. *
  6677. * @ingroup tripal_chado_v1.2_schema_api
  6678. *
  6679. */
  6680. function tripal_core_chado_schema_v1_2_library() {
  6681. $description = array(
  6682. 'description' => 'TODO: please describe this table!',
  6683. 'fields' => array(
  6684. 'library_id' => array(
  6685. 'description' => 'TODO: please describe this field!',
  6686. 'type' => 'serial',
  6687. 'not null' => TRUE,
  6688. ),
  6689. 'organism_id' => array(
  6690. 'description' => 'TODO: please describe this field!',
  6691. 'type' => 'int',
  6692. 'not null' => TRUE,
  6693. ),
  6694. 'name' => array(
  6695. 'description' => 'TODO: please describe this field!',
  6696. 'type' => 'varchar',
  6697. 'length' => '255',
  6698. 'not null' => FALSE,
  6699. ),
  6700. 'uniquename' => array(
  6701. 'description' => 'TODO: please describe this field!',
  6702. 'type' => 'text',
  6703. 'not null' => TRUE,
  6704. ),
  6705. 'type_id' => array(
  6706. 'description' => 'TODO: please describe this field!',
  6707. 'type' => 'int',
  6708. 'not null' => TRUE,
  6709. ),
  6710. 'is_obsolete' => array(
  6711. 'description' => 'TODO: please describe this field!',
  6712. 'type' => 'int',
  6713. 'not null' => TRUE,
  6714. 'default' => 0,
  6715. ),
  6716. 'timeaccessioned' => array(
  6717. 'description' => 'TODO: please describe this field!',
  6718. 'type' => 'datetime',
  6719. 'not null' => TRUE,
  6720. 'default' => 'ow(',
  6721. ),
  6722. 'timelastmodified' => array(
  6723. 'description' => 'TODO: please describe this field!',
  6724. 'type' => 'datetime',
  6725. 'not null' => TRUE,
  6726. 'default' => 'ow(',
  6727. ),
  6728. ),
  6729. 'primary key' => array(
  6730. 0 => 'library_id',
  6731. ),
  6732. 'unique keys' => array(
  6733. 'library_c1' => array(
  6734. 0 => 'organism_id',
  6735. 1 => 'uniquename',
  6736. 2 => 'type_id',
  6737. ),
  6738. ),
  6739. 'indexes' => array(
  6740. 'library_idx1' => array(
  6741. 0 => 'organism_id',
  6742. ),
  6743. 'library_idx2' => array(
  6744. 0 => 'type_id',
  6745. ),
  6746. 'library_idx3' => array(
  6747. 0 => 'uniquename',
  6748. ),
  6749. 'library_name_ind1' => array(
  6750. 0 => 'name',
  6751. ),
  6752. ),
  6753. 'foreign keys' => array(
  6754. 'organism' => array(
  6755. 'table' => 'organism',
  6756. 'columns' => array(
  6757. 'organism_id' => 'organism_id',
  6758. ),
  6759. ),
  6760. 'cvterm' => array(
  6761. 'table' => 'cvterm',
  6762. 'columns' => array(
  6763. 'type_id' => 'cvterm_id',
  6764. ),
  6765. ),
  6766. ),
  6767. );
  6768. return $description;
  6769. }
  6770. /**
  6771. * Implements hook_chado_schema_v1_2_library_cvterm()
  6772. * Purpose: To describe the structure of 'library_cvterm' to tripal
  6773. * @see tripal_core_chado_insert()
  6774. * @see tripal_core_chado_update()
  6775. * @see tripal_core_chado_select()
  6776. *
  6777. * @return
  6778. * An array describing the 'library_cvterm' table
  6779. *
  6780. * @ingroup tripal_chado_v1.2_schema_api
  6781. *
  6782. */
  6783. function tripal_core_chado_schema_v1_2_library_cvterm() {
  6784. $description = array(
  6785. 'description' => 'TODO: please describe this table!',
  6786. 'fields' => array(
  6787. 'library_cvterm_id' => array(
  6788. 'description' => 'TODO: please describe this field!',
  6789. 'type' => 'serial',
  6790. 'not null' => TRUE,
  6791. ),
  6792. 'library_id' => array(
  6793. 'description' => 'TODO: please describe this field!',
  6794. 'type' => 'int',
  6795. 'not null' => TRUE,
  6796. ),
  6797. 'cvterm_id' => array(
  6798. 'description' => 'TODO: please describe this field!',
  6799. 'type' => 'int',
  6800. 'not null' => TRUE,
  6801. ),
  6802. 'pub_id' => array(
  6803. 'description' => 'TODO: please describe this field!',
  6804. 'type' => 'int',
  6805. 'not null' => TRUE,
  6806. ),
  6807. ),
  6808. 'primary key' => array(
  6809. 0 => 'library_cvterm_id',
  6810. ),
  6811. 'unique keys' => array(
  6812. 'library_cvterm_c1' => array(
  6813. 0 => 'library_id',
  6814. 1 => 'cvterm_id',
  6815. 2 => 'pub_id',
  6816. ),
  6817. ),
  6818. 'indexes' => array(
  6819. 'library_cvterm_idx1' => array(
  6820. 0 => 'library_id',
  6821. ),
  6822. 'library_cvterm_idx2' => array(
  6823. 0 => 'cvterm_id',
  6824. ),
  6825. 'library_cvterm_idx3' => array(
  6826. 0 => 'pub_id',
  6827. ),
  6828. ),
  6829. 'foreign keys' => array(
  6830. 'cvterm' => array(
  6831. 'table' => 'cvterm',
  6832. 'columns' => array(
  6833. 'cvterm_id' => 'cvterm_id',
  6834. ),
  6835. ),
  6836. 'pub' => array(
  6837. 'table' => 'pub',
  6838. 'columns' => array(
  6839. 'pub_id' => 'pub_id',
  6840. ),
  6841. ),
  6842. 'library' => array(
  6843. 'table' => 'library',
  6844. 'columns' => array(
  6845. 'library_id' => 'library_id',
  6846. ),
  6847. ),
  6848. ),
  6849. );
  6850. return $description;
  6851. }
  6852. /**
  6853. * Implements hook_chado_schema_v1_2_library_dbxref()
  6854. * Purpose: To describe the structure of 'library_dbxref' to tripal
  6855. * @see tripal_core_chado_insert()
  6856. * @see tripal_core_chado_update()
  6857. * @see tripal_core_chado_select()
  6858. *
  6859. * @return
  6860. * An array describing the 'library_dbxref' table
  6861. *
  6862. * @ingroup tripal_chado_v1.2_schema_api
  6863. *
  6864. */
  6865. function tripal_core_chado_schema_v1_2_library_dbxref() {
  6866. $description = array(
  6867. 'description' => 'TODO: please describe this table!',
  6868. 'fields' => array(
  6869. 'library_dbxref_id' => array(
  6870. 'description' => 'TODO: please describe this field!',
  6871. 'type' => 'serial',
  6872. 'not null' => TRUE,
  6873. ),
  6874. 'library_id' => array(
  6875. 'description' => 'TODO: please describe this field!',
  6876. 'type' => 'int',
  6877. 'not null' => TRUE,
  6878. ),
  6879. 'dbxref_id' => array(
  6880. 'description' => 'TODO: please describe this field!',
  6881. 'type' => 'int',
  6882. 'not null' => TRUE,
  6883. ),
  6884. 'is_current' => array(
  6885. 'description' => 'TODO: please describe this field!',
  6886. 'type' => 'boolean',
  6887. 'not null' => TRUE,
  6888. 'default' => 'ru',
  6889. ),
  6890. ),
  6891. 'primary key' => array(
  6892. 0 => 'library_dbxref_id',
  6893. ),
  6894. 'unique keys' => array(
  6895. 'library_dbxref_c1' => array(
  6896. 0 => 'library_id',
  6897. 1 => 'dbxref_id',
  6898. ),
  6899. ),
  6900. 'indexes' => array(
  6901. 'library_dbxref_idx1' => array(
  6902. 0 => 'library_id',
  6903. ),
  6904. 'library_dbxref_idx2' => array(
  6905. 0 => 'dbxref_id',
  6906. ),
  6907. ),
  6908. 'foreign keys' => array(
  6909. 'dbxref' => array(
  6910. 'table' => 'dbxref',
  6911. 'columns' => array(
  6912. 'dbxref_id' => 'dbxref_id',
  6913. ),
  6914. ),
  6915. 'library' => array(
  6916. 'table' => 'library',
  6917. 'columns' => array(
  6918. 'library_id' => 'library_id',
  6919. ),
  6920. ),
  6921. ),
  6922. );
  6923. return $description;
  6924. }
  6925. /**
  6926. * Implements hook_chado_schema_v1_2_library_feature()
  6927. * Purpose: To describe the structure of 'library_feature' to tripal
  6928. * @see tripal_core_chado_insert()
  6929. * @see tripal_core_chado_update()
  6930. * @see tripal_core_chado_select()
  6931. *
  6932. * @return
  6933. * An array describing the 'library_feature' table
  6934. *
  6935. * @ingroup tripal_chado_v1.2_schema_api
  6936. *
  6937. */
  6938. function tripal_core_chado_schema_v1_2_library_feature() {
  6939. $description = array(
  6940. 'description' => 'TODO: please describe this table!',
  6941. 'fields' => array(
  6942. 'library_feature_id' => array(
  6943. 'description' => 'TODO: please describe this field!',
  6944. 'type' => 'serial',
  6945. 'not null' => TRUE,
  6946. ),
  6947. 'library_id' => array(
  6948. 'description' => 'TODO: please describe this field!',
  6949. 'type' => 'int',
  6950. 'not null' => TRUE,
  6951. ),
  6952. 'feature_id' => array(
  6953. 'description' => 'TODO: please describe this field!',
  6954. 'type' => 'int',
  6955. 'not null' => TRUE,
  6956. ),
  6957. ),
  6958. 'primary key' => array(
  6959. 0 => 'library_feature_id',
  6960. ),
  6961. 'unique keys' => array(
  6962. 'library_feature_c1' => array(
  6963. 0 => 'library_id',
  6964. 1 => 'feature_id',
  6965. ),
  6966. ),
  6967. 'indexes' => array(
  6968. 'library_feature_idx1' => array(
  6969. 0 => 'library_id',
  6970. ),
  6971. 'library_feature_idx2' => array(
  6972. 0 => 'feature_id',
  6973. ),
  6974. ),
  6975. 'foreign keys' => array(
  6976. 'feature' => array(
  6977. 'table' => 'feature',
  6978. 'columns' => array(
  6979. 'feature_id' => 'feature_id',
  6980. ),
  6981. ),
  6982. 'library' => array(
  6983. 'table' => 'library',
  6984. 'columns' => array(
  6985. 'library_id' => 'library_id',
  6986. ),
  6987. ),
  6988. ),
  6989. );
  6990. return $description;
  6991. }
  6992. /**
  6993. * Implements hook_chado_schema_v1_2_library_pub()
  6994. * Purpose: To describe the structure of 'library_pub' to tripal
  6995. * @see tripal_core_chado_insert()
  6996. * @see tripal_core_chado_update()
  6997. * @see tripal_core_chado_select()
  6998. *
  6999. * @return
  7000. * An array describing the 'library_pub' table
  7001. *
  7002. * @ingroup tripal_chado_v1.2_schema_api
  7003. *
  7004. */
  7005. function tripal_core_chado_schema_v1_2_library_pub() {
  7006. $description = array(
  7007. 'description' => 'TODO: please describe this table!',
  7008. 'fields' => array(
  7009. 'library_pub_id' => array(
  7010. 'description' => 'TODO: please describe this field!',
  7011. 'type' => 'serial',
  7012. 'not null' => TRUE,
  7013. ),
  7014. 'library_id' => array(
  7015. 'description' => 'TODO: please describe this field!',
  7016. 'type' => 'int',
  7017. 'not null' => TRUE,
  7018. ),
  7019. 'pub_id' => array(
  7020. 'description' => 'TODO: please describe this field!',
  7021. 'type' => 'int',
  7022. 'not null' => TRUE,
  7023. ),
  7024. ),
  7025. 'primary key' => array(
  7026. 0 => 'library_pub_id',
  7027. ),
  7028. 'unique keys' => array(
  7029. 'library_pub_c1' => array(
  7030. 0 => 'library_id',
  7031. 1 => 'pub_id',
  7032. ),
  7033. ),
  7034. 'indexes' => array(
  7035. 'library_pub_idx1' => array(
  7036. 0 => 'library_id',
  7037. ),
  7038. 'library_pub_idx2' => array(
  7039. 0 => 'pub_id',
  7040. ),
  7041. ),
  7042. 'foreign keys' => array(
  7043. 'pub' => array(
  7044. 'table' => 'pub',
  7045. 'columns' => array(
  7046. 'pub_id' => 'pub_id',
  7047. ),
  7048. ),
  7049. 'library' => array(
  7050. 'table' => 'library',
  7051. 'columns' => array(
  7052. 'library_id' => 'library_id',
  7053. ),
  7054. ),
  7055. ),
  7056. );
  7057. return $description;
  7058. }
  7059. /**
  7060. * Implements hook_chado_schema_v1_2_library_synonym()
  7061. * Purpose: To describe the structure of 'library_synonym' to tripal
  7062. * @see tripal_core_chado_insert()
  7063. * @see tripal_core_chado_update()
  7064. * @see tripal_core_chado_select()
  7065. *
  7066. * @return
  7067. * An array describing the 'library_synonym' table
  7068. *
  7069. * @ingroup tripal_chado_v1.2_schema_api
  7070. *
  7071. */
  7072. function tripal_core_chado_schema_v1_2_library_synonym() {
  7073. $description = array(
  7074. 'description' => 'TODO: please describe this table!',
  7075. 'fields' => array(
  7076. 'library_synonym_id' => array(
  7077. 'description' => 'TODO: please describe this field!',
  7078. 'type' => 'serial',
  7079. 'not null' => TRUE,
  7080. ),
  7081. 'synonym_id' => array(
  7082. 'description' => 'TODO: please describe this field!',
  7083. 'type' => 'int',
  7084. 'not null' => TRUE,
  7085. ),
  7086. 'library_id' => array(
  7087. 'description' => 'TODO: please describe this field!',
  7088. 'type' => 'int',
  7089. 'not null' => TRUE,
  7090. ),
  7091. 'pub_id' => array(
  7092. 'description' => 'TODO: please describe this field!',
  7093. 'type' => 'int',
  7094. 'not null' => TRUE,
  7095. ),
  7096. 'is_current' => array(
  7097. 'description' => 'TODO: please describe this field!',
  7098. 'type' => 'boolean',
  7099. 'not null' => TRUE,
  7100. 'default' => 'ru',
  7101. ),
  7102. 'is_internal' => array(
  7103. 'description' => 'TODO: please describe this field!',
  7104. 'type' => 'boolean',
  7105. 'not null' => TRUE,
  7106. 'default' => 'als',
  7107. ),
  7108. ),
  7109. 'primary key' => array(
  7110. 0 => 'library_synonym_id',
  7111. ),
  7112. 'unique keys' => array(
  7113. 'library_synonym_c1' => array(
  7114. 0 => 'synonym_id',
  7115. 1 => 'library_id',
  7116. 2 => 'pub_id',
  7117. ),
  7118. ),
  7119. 'indexes' => array(
  7120. 'library_synonym_idx1' => array(
  7121. 0 => 'synonym_id',
  7122. ),
  7123. 'library_synonym_idx2' => array(
  7124. 0 => 'library_id',
  7125. ),
  7126. 'library_synonym_idx3' => array(
  7127. 0 => 'pub_id',
  7128. ),
  7129. ),
  7130. 'foreign keys' => array(
  7131. 'pub' => array(
  7132. 'table' => 'pub',
  7133. 'columns' => array(
  7134. 'pub_id' => 'pub_id',
  7135. ),
  7136. ),
  7137. 'synonym' => array(
  7138. 'table' => 'synonym',
  7139. 'columns' => array(
  7140. 'synonym_id' => 'synonym_id',
  7141. ),
  7142. ),
  7143. 'library' => array(
  7144. 'table' => 'library',
  7145. 'columns' => array(
  7146. 'library_id' => 'library_id',
  7147. ),
  7148. ),
  7149. ),
  7150. );
  7151. return $description;
  7152. }
  7153. /**
  7154. * Implements hook_chado_schema_v1_2_libraryprop()
  7155. * Purpose: To describe the structure of 'libraryprop' to tripal
  7156. * @see tripal_core_chado_insert()
  7157. * @see tripal_core_chado_update()
  7158. * @see tripal_core_chado_select()
  7159. *
  7160. * @return
  7161. * An array describing the 'libraryprop' table
  7162. *
  7163. * @ingroup tripal_chado_v1.2_schema_api
  7164. *
  7165. */
  7166. function tripal_core_chado_schema_v1_2_libraryprop() {
  7167. $description = array(
  7168. 'description' => 'TODO: please describe this table!',
  7169. 'fields' => array(
  7170. 'libraryprop_id' => array(
  7171. 'description' => 'TODO: please describe this field!',
  7172. 'type' => 'serial',
  7173. 'not null' => TRUE,
  7174. ),
  7175. 'library_id' => array(
  7176. 'description' => 'TODO: please describe this field!',
  7177. 'type' => 'int',
  7178. 'not null' => TRUE,
  7179. ),
  7180. 'type_id' => array(
  7181. 'description' => 'TODO: please describe this field!',
  7182. 'type' => 'int',
  7183. 'not null' => TRUE,
  7184. ),
  7185. 'value' => array(
  7186. 'description' => 'TODO: please describe this field!',
  7187. 'type' => 'text',
  7188. 'not null' => FALSE,
  7189. ),
  7190. 'rank' => array(
  7191. 'description' => 'TODO: please describe this field!',
  7192. 'type' => 'int',
  7193. 'not null' => TRUE,
  7194. 'default' => 0,
  7195. ),
  7196. ),
  7197. 'primary key' => array(
  7198. 0 => 'libraryprop_id',
  7199. ),
  7200. 'unique keys' => array(
  7201. 'libraryprop_c1' => array(
  7202. 0 => 'library_id',
  7203. 1 => 'type_id',
  7204. 2 => 'rank',
  7205. ),
  7206. ),
  7207. 'indexes' => array(
  7208. 'libraryprop_idx1' => array(
  7209. 0 => 'library_id',
  7210. ),
  7211. 'libraryprop_idx2' => array(
  7212. 0 => 'type_id',
  7213. ),
  7214. ),
  7215. 'foreign keys' => array(
  7216. 'cvterm' => array(
  7217. 'table' => 'cvterm',
  7218. 'columns' => array(
  7219. 'type_id' => 'cvterm_id',
  7220. ),
  7221. ),
  7222. 'library' => array(
  7223. 'table' => 'library',
  7224. 'columns' => array(
  7225. 'library_id' => 'library_id',
  7226. ),
  7227. ),
  7228. ),
  7229. );
  7230. return $description;
  7231. }
  7232. /**
  7233. * Implements hook_chado_schema_v1_2_libraryprop_pub()
  7234. * Purpose: To describe the structure of 'libraryprop_pub' to tripal
  7235. * @see tripal_core_chado_insert()
  7236. * @see tripal_core_chado_update()
  7237. * @see tripal_core_chado_select()
  7238. *
  7239. * @return
  7240. * An array describing the 'libraryprop_pub' table
  7241. *
  7242. * @ingroup tripal_chado_v1.2_schema_api
  7243. *
  7244. */
  7245. function tripal_core_chado_schema_v1_2_libraryprop_pub() {
  7246. $description = array(
  7247. 'description' => 'TODO: please describe this table!',
  7248. 'fields' => array(
  7249. 'libraryprop_pub_id' => array(
  7250. 'description' => 'TODO: please describe this field!',
  7251. 'type' => 'serial',
  7252. 'not null' => TRUE,
  7253. ),
  7254. 'libraryprop_id' => array(
  7255. 'description' => 'TODO: please describe this field!',
  7256. 'type' => 'int',
  7257. 'not null' => TRUE,
  7258. ),
  7259. 'pub_id' => array(
  7260. 'description' => 'TODO: please describe this field!',
  7261. 'type' => 'int',
  7262. 'not null' => TRUE,
  7263. ),
  7264. ),
  7265. 'primary key' => array(
  7266. 0 => 'libraryprop_pub_id',
  7267. ),
  7268. 'unique keys' => array(
  7269. 'libraryprop_pub_c1' => array(
  7270. 0 => 'libraryprop_id',
  7271. 1 => 'pub_id',
  7272. ),
  7273. ),
  7274. 'indexes' => array(
  7275. 'libraryprop_pub_idx1' => array(
  7276. 0 => 'libraryprop_id',
  7277. ),
  7278. 'libraryprop_pub_idx2' => array(
  7279. 0 => 'pub_id',
  7280. ),
  7281. ),
  7282. 'foreign keys' => array(
  7283. 'pub' => array(
  7284. 'table' => 'pub',
  7285. 'columns' => array(
  7286. 'pub_id' => 'pub_id',
  7287. ),
  7288. ),
  7289. 'libraryprop' => array(
  7290. 'table' => 'libraryprop',
  7291. 'columns' => array(
  7292. 'libraryprop_id' => 'libraryprop_id',
  7293. ),
  7294. ),
  7295. ),
  7296. );
  7297. return $description;
  7298. }
  7299. /**
  7300. * Implements hook_chado_schema_v1_2_magedocumentation()
  7301. * Purpose: To describe the structure of 'magedocumentation' to tripal
  7302. * @see tripal_core_chado_insert()
  7303. * @see tripal_core_chado_update()
  7304. * @see tripal_core_chado_select()
  7305. *
  7306. * @return
  7307. * An array describing the 'magedocumentation' table
  7308. *
  7309. * @ingroup tripal_chado_v1.2_schema_api
  7310. *
  7311. */
  7312. function tripal_core_chado_schema_v1_2_magedocumentation() {
  7313. $description = array(
  7314. 'description' => 'TODO: please describe this table!',
  7315. 'fields' => array(
  7316. 'magedocumentation_id' => array(
  7317. 'description' => 'TODO: please describe this field!',
  7318. 'type' => 'serial',
  7319. 'not null' => TRUE,
  7320. ),
  7321. 'mageml_id' => array(
  7322. 'description' => 'TODO: please describe this field!',
  7323. 'type' => 'int',
  7324. 'not null' => TRUE,
  7325. ),
  7326. 'tableinfo_id' => array(
  7327. 'description' => 'TODO: please describe this field!',
  7328. 'type' => 'int',
  7329. 'not null' => TRUE,
  7330. ),
  7331. 'row_id' => array(
  7332. 'description' => 'TODO: please describe this field!',
  7333. 'type' => 'int',
  7334. 'not null' => TRUE,
  7335. ),
  7336. 'mageidentifier' => array(
  7337. 'description' => 'TODO: please describe this field!',
  7338. 'type' => 'text',
  7339. 'not null' => TRUE,
  7340. ),
  7341. ),
  7342. 'primary key' => array(
  7343. 0 => 'magedocumentation_id',
  7344. ),
  7345. 'indexes' => array(
  7346. 'magedocumentation_idx1' => array(
  7347. 0 => 'mageml_id',
  7348. ),
  7349. 'magedocumentation_idx2' => array(
  7350. 0 => 'tableinfo_id',
  7351. ),
  7352. 'magedocumentation_idx3' => array(
  7353. 0 => 'row_id',
  7354. ),
  7355. ),
  7356. 'foreign keys' => array(
  7357. 'tableinfo' => array(
  7358. 'table' => 'tableinfo',
  7359. 'columns' => array(
  7360. 'tableinfo_id' => 'tableinfo_id',
  7361. ),
  7362. ),
  7363. 'mageml' => array(
  7364. 'table' => 'mageml',
  7365. 'columns' => array(
  7366. 'mageml_id' => 'mageml_id',
  7367. ),
  7368. ),
  7369. ),
  7370. );
  7371. return $description;
  7372. }
  7373. /**
  7374. * Implements hook_chado_schema_v1_2_mageml()
  7375. * Purpose: To describe the structure of 'mageml' to tripal
  7376. * @see tripal_core_chado_insert()
  7377. * @see tripal_core_chado_update()
  7378. * @see tripal_core_chado_select()
  7379. *
  7380. * @return
  7381. * An array describing the 'mageml' table
  7382. *
  7383. * @ingroup tripal_chado_v1.2_schema_api
  7384. *
  7385. */
  7386. function tripal_core_chado_schema_v1_2_mageml() {
  7387. $description = array(
  7388. 'description' => 'TODO: please describe this table!',
  7389. 'fields' => array(
  7390. 'mageml_id' => array(
  7391. 'description' => 'TODO: please describe this field!',
  7392. 'type' => 'serial',
  7393. 'not null' => TRUE,
  7394. ),
  7395. 'mage_package' => array(
  7396. 'description' => 'TODO: please describe this field!',
  7397. 'type' => 'text',
  7398. 'not null' => TRUE,
  7399. ),
  7400. 'mage_ml' => array(
  7401. 'description' => 'TODO: please describe this field!',
  7402. 'type' => 'text',
  7403. 'not null' => TRUE,
  7404. ),
  7405. ),
  7406. 'primary key' => array(
  7407. 0 => 'mageml_id',
  7408. ),
  7409. 'foreign keys' => array(
  7410. ),
  7411. );
  7412. return $description;
  7413. }
  7414. /**
  7415. * Implements hook_chado_schema_v1_2_materialized_view()
  7416. * Purpose: To describe the structure of 'materialized_view' to tripal
  7417. * @see tripal_core_chado_insert()
  7418. * @see tripal_core_chado_update()
  7419. * @see tripal_core_chado_select()
  7420. *
  7421. * @return
  7422. * An array describing the 'materialized_view' table
  7423. *
  7424. * @ingroup tripal_chado_v1.2_schema_api
  7425. *
  7426. */
  7427. function tripal_core_chado_schema_v1_2_materialized_view() {
  7428. $description = array(
  7429. );
  7430. return $description;
  7431. }
  7432. /**
  7433. * Implements hook_chado_schema_v1_2_nd_experiment()
  7434. * Purpose: To describe the structure of 'nd_experiment' to tripal
  7435. * @see tripal_core_chado_insert()
  7436. * @see tripal_core_chado_update()
  7437. * @see tripal_core_chado_select()
  7438. *
  7439. * @return
  7440. * An array describing the 'nd_experiment' table
  7441. *
  7442. * @ingroup tripal_chado_v1.2_schema_api
  7443. *
  7444. */
  7445. function tripal_core_chado_schema_v1_2_nd_experiment() {
  7446. $description = array(
  7447. 'description' => 'TODO: please describe this table!',
  7448. 'fields' => array(
  7449. 'nd_experiment_id' => array(
  7450. 'description' => 'TODO: please describe this field!',
  7451. 'type' => 'serial',
  7452. 'not null' => TRUE,
  7453. ),
  7454. 'nd_geolocation_id' => array(
  7455. 'description' => 'TODO: please describe this field!',
  7456. 'type' => 'int',
  7457. 'not null' => TRUE,
  7458. ),
  7459. 'type_id' => array(
  7460. 'description' => 'TODO: please describe this field!',
  7461. 'type' => 'int',
  7462. 'not null' => TRUE,
  7463. ),
  7464. ),
  7465. 'primary key' => array(
  7466. 0 => 'nd_experiment_id',
  7467. ),
  7468. 'foreign keys' => array(
  7469. 'cvterm' => array(
  7470. 'table' => 'cvterm',
  7471. 'columns' => array(
  7472. 'type_id' => 'cvterm_id',
  7473. ),
  7474. ),
  7475. 'nd_geolocation' => array(
  7476. 'table' => 'nd_geolocation',
  7477. 'columns' => array(
  7478. 'nd_geolocation_id' => 'nd_geolocation_id',
  7479. ),
  7480. ),
  7481. ),
  7482. );
  7483. return $description;
  7484. }
  7485. /**
  7486. * Implements hook_chado_schema_v1_2_nd_experiment_contact()
  7487. * Purpose: To describe the structure of 'nd_experiment_contact' to tripal
  7488. * @see tripal_core_chado_insert()
  7489. * @see tripal_core_chado_update()
  7490. * @see tripal_core_chado_select()
  7491. *
  7492. * @return
  7493. * An array describing the 'nd_experiment_contact' table
  7494. *
  7495. * @ingroup tripal_chado_v1.2_schema_api
  7496. *
  7497. */
  7498. function tripal_core_chado_schema_v1_2_nd_experiment_contact() {
  7499. $description = array(
  7500. 'description' => 'TODO: please describe this table!',
  7501. 'fields' => array(
  7502. 'nd_experiment_contact_id' => array(
  7503. 'description' => 'TODO: please describe this field!',
  7504. 'type' => 'serial',
  7505. 'not null' => TRUE,
  7506. ),
  7507. 'nd_experiment_id' => array(
  7508. 'description' => 'TODO: please describe this field!',
  7509. 'type' => 'int',
  7510. 'not null' => TRUE,
  7511. ),
  7512. 'contact_id' => array(
  7513. 'description' => 'TODO: please describe this field!',
  7514. 'type' => 'int',
  7515. 'not null' => TRUE,
  7516. ),
  7517. ),
  7518. 'primary key' => array(
  7519. 0 => 'nd_experiment_contact_id',
  7520. ),
  7521. 'foreign keys' => array(
  7522. 'contact' => array(
  7523. 'table' => 'contact',
  7524. 'columns' => array(
  7525. 'contact_id' => 'contact_id',
  7526. ),
  7527. ),
  7528. 'nd_experiment' => array(
  7529. 'table' => 'nd_experiment',
  7530. 'columns' => array(
  7531. 'nd_experiment_id' => 'nd_experiment_id',
  7532. ),
  7533. ),
  7534. ),
  7535. );
  7536. return $description;
  7537. }
  7538. /**
  7539. * Implements hook_chado_schema_v1_2_nd_experiment_dbxref()
  7540. * Purpose: To describe the structure of 'nd_experiment_dbxref' to tripal
  7541. * @see tripal_core_chado_insert()
  7542. * @see tripal_core_chado_update()
  7543. * @see tripal_core_chado_select()
  7544. *
  7545. * @return
  7546. * An array describing the 'nd_experiment_dbxref' table
  7547. *
  7548. * @ingroup tripal_chado_v1.2_schema_api
  7549. *
  7550. */
  7551. function tripal_core_chado_schema_v1_2_nd_experiment_dbxref() {
  7552. $description = array(
  7553. 'description' => 'TODO: please describe this table!',
  7554. 'fields' => array(
  7555. 'nd_experiment_dbxref_id' => array(
  7556. 'description' => 'TODO: please describe this field!',
  7557. 'type' => 'serial',
  7558. 'not null' => TRUE,
  7559. ),
  7560. 'nd_experiment_id' => array(
  7561. 'description' => 'TODO: please describe this field!',
  7562. 'type' => 'int',
  7563. 'not null' => TRUE,
  7564. ),
  7565. 'dbxref_id' => array(
  7566. 'description' => 'TODO: please describe this field!',
  7567. 'type' => 'int',
  7568. 'not null' => TRUE,
  7569. ),
  7570. ),
  7571. 'primary key' => array(
  7572. 0 => 'nd_experiment_dbxref_id',
  7573. ),
  7574. 'foreign keys' => array(
  7575. 'dbxref' => array(
  7576. 'table' => 'dbxref',
  7577. 'columns' => array(
  7578. 'dbxref_id' => 'dbxref_id',
  7579. ),
  7580. ),
  7581. 'nd_experiment' => array(
  7582. 'table' => 'nd_experiment',
  7583. 'columns' => array(
  7584. 'nd_experiment_id' => 'nd_experiment_id',
  7585. ),
  7586. ),
  7587. ),
  7588. );
  7589. return $description;
  7590. }
  7591. /**
  7592. * Implements hook_chado_schema_v1_2_nd_experiment_genotype()
  7593. * Purpose: To describe the structure of 'nd_experiment_genotype' to tripal
  7594. * @see tripal_core_chado_insert()
  7595. * @see tripal_core_chado_update()
  7596. * @see tripal_core_chado_select()
  7597. *
  7598. * @return
  7599. * An array describing the 'nd_experiment_genotype' table
  7600. *
  7601. * @ingroup tripal_chado_v1.2_schema_api
  7602. *
  7603. */
  7604. function tripal_core_chado_schema_v1_2_nd_experiment_genotype() {
  7605. $description = array(
  7606. 'description' => 'TODO: please describe this table!',
  7607. 'fields' => array(
  7608. 'nd_experiment_genotype_id' => array(
  7609. 'description' => 'TODO: please describe this field!',
  7610. 'type' => 'serial',
  7611. 'not null' => TRUE,
  7612. ),
  7613. 'nd_experiment_id' => array(
  7614. 'description' => 'TODO: please describe this field!',
  7615. 'type' => 'int',
  7616. 'not null' => TRUE,
  7617. ),
  7618. 'genotype_id' => array(
  7619. 'description' => 'TODO: please describe this field!',
  7620. 'type' => 'int',
  7621. 'not null' => TRUE,
  7622. ),
  7623. ),
  7624. 'primary key' => array(
  7625. 0 => 'nd_experiment_genotype_id',
  7626. ),
  7627. 'unique keys' => array(
  7628. 'nd_experiment_genotype_c1' => array(
  7629. 0 => 'nd_experiment_id',
  7630. 1 => 'genotype_id',
  7631. ),
  7632. ),
  7633. 'foreign keys' => array(
  7634. 'genotype' => array(
  7635. 'table' => 'genotype',
  7636. 'columns' => array(
  7637. 'genotype_id' => 'genotype_id',
  7638. ),
  7639. ),
  7640. 'nd_experiment' => array(
  7641. 'table' => 'nd_experiment',
  7642. 'columns' => array(
  7643. 'nd_experiment_id' => 'nd_experiment_id',
  7644. ),
  7645. ),
  7646. ),
  7647. );
  7648. return $description;
  7649. }
  7650. /**
  7651. * Implements hook_chado_schema_v1_2_nd_experiment_phenotype()
  7652. * Purpose: To describe the structure of 'nd_experiment_phenotype' to tripal
  7653. * @see tripal_core_chado_insert()
  7654. * @see tripal_core_chado_update()
  7655. * @see tripal_core_chado_select()
  7656. *
  7657. * @return
  7658. * An array describing the 'nd_experiment_phenotype' table
  7659. *
  7660. * @ingroup tripal_chado_v1.2_schema_api
  7661. *
  7662. */
  7663. function tripal_core_chado_schema_v1_2_nd_experiment_phenotype() {
  7664. $description = array(
  7665. 'description' => 'TODO: please describe this table!',
  7666. 'fields' => array(
  7667. 'nd_experiment_phenotype_id' => array(
  7668. 'description' => 'TODO: please describe this field!',
  7669. 'type' => 'serial',
  7670. 'not null' => TRUE,
  7671. ),
  7672. 'nd_experiment_id' => array(
  7673. 'description' => 'TODO: please describe this field!',
  7674. 'type' => 'int',
  7675. 'not null' => TRUE,
  7676. ),
  7677. 'phenotype_id' => array(
  7678. 'description' => 'TODO: please describe this field!',
  7679. 'type' => 'int',
  7680. 'not null' => TRUE,
  7681. ),
  7682. ),
  7683. 'primary key' => array(
  7684. 0 => 'nd_experiment_phenotype_id',
  7685. ),
  7686. 'unique keys' => array(
  7687. 'nd_experiment_phenotype_c1' => array(
  7688. 0 => 'nd_experiment_id',
  7689. 1 => 'phenotype_id',
  7690. ),
  7691. ),
  7692. 'foreign keys' => array(
  7693. 'phenotype' => array(
  7694. 'table' => 'phenotype',
  7695. 'columns' => array(
  7696. 'phenotype_id' => 'phenotype_id',
  7697. ),
  7698. ),
  7699. 'nd_experiment' => array(
  7700. 'table' => 'nd_experiment',
  7701. 'columns' => array(
  7702. 'nd_experiment_id' => 'nd_experiment_id',
  7703. ),
  7704. ),
  7705. ),
  7706. );
  7707. return $description;
  7708. }
  7709. /**
  7710. * Implements hook_chado_schema_v1_2_nd_experiment_project()
  7711. * Purpose: To describe the structure of 'nd_experiment_project' to tripal
  7712. * @see tripal_core_chado_insert()
  7713. * @see tripal_core_chado_update()
  7714. * @see tripal_core_chado_select()
  7715. *
  7716. * @return
  7717. * An array describing the 'nd_experiment_project' table
  7718. *
  7719. * @ingroup tripal_chado_v1.2_schema_api
  7720. *
  7721. */
  7722. function tripal_core_chado_schema_v1_2_nd_experiment_project() {
  7723. $description = array(
  7724. 'description' => 'TODO: please describe this table!',
  7725. 'fields' => array(
  7726. 'nd_experiment_project_id' => array(
  7727. 'description' => 'TODO: please describe this field!',
  7728. 'type' => 'serial',
  7729. 'not null' => TRUE,
  7730. ),
  7731. 'project_id' => array(
  7732. 'description' => 'TODO: please describe this field!',
  7733. 'type' => 'int',
  7734. 'not null' => TRUE,
  7735. ),
  7736. 'nd_experiment_id' => array(
  7737. 'description' => 'TODO: please describe this field!',
  7738. 'type' => 'int',
  7739. 'not null' => TRUE,
  7740. ),
  7741. ),
  7742. 'primary key' => array(
  7743. 0 => 'nd_experiment_project_id',
  7744. ),
  7745. 'foreign keys' => array(
  7746. 'project' => array(
  7747. 'table' => 'project',
  7748. 'columns' => array(
  7749. 'project_id' => 'project_id',
  7750. ),
  7751. ),
  7752. 'nd_experiment' => array(
  7753. 'table' => 'nd_experiment',
  7754. 'columns' => array(
  7755. 'nd_experiment_id' => 'nd_experiment_id',
  7756. ),
  7757. ),
  7758. ),
  7759. );
  7760. return $description;
  7761. }
  7762. /**
  7763. * Implements hook_chado_schema_v1_2_nd_experiment_protocol()
  7764. * Purpose: To describe the structure of 'nd_experiment_protocol' to tripal
  7765. * @see tripal_core_chado_insert()
  7766. * @see tripal_core_chado_update()
  7767. * @see tripal_core_chado_select()
  7768. *
  7769. * @return
  7770. * An array describing the 'nd_experiment_protocol' table
  7771. *
  7772. * @ingroup tripal_chado_v1.2_schema_api
  7773. *
  7774. */
  7775. function tripal_core_chado_schema_v1_2_nd_experiment_protocol() {
  7776. $description = array(
  7777. 'description' => 'TODO: please describe this table!',
  7778. 'fields' => array(
  7779. 'nd_experiment_protocol_id' => array(
  7780. 'description' => 'TODO: please describe this field!',
  7781. 'type' => 'serial',
  7782. 'not null' => TRUE,
  7783. ),
  7784. 'nd_experiment_id' => array(
  7785. 'description' => 'TODO: please describe this field!',
  7786. 'type' => 'int',
  7787. 'not null' => TRUE,
  7788. ),
  7789. 'nd_protocol_id' => array(
  7790. 'description' => 'TODO: please describe this field!',
  7791. 'type' => 'int',
  7792. 'not null' => TRUE,
  7793. ),
  7794. ),
  7795. 'primary key' => array(
  7796. 0 => 'nd_experiment_protocol_id',
  7797. ),
  7798. 'foreign keys' => array(
  7799. 'nd_experiment' => array(
  7800. 'table' => 'nd_experiment',
  7801. 'columns' => array(
  7802. 'nd_experiment_id' => 'nd_experiment_id',
  7803. ),
  7804. ),
  7805. 'nd_protocol' => array(
  7806. 'table' => 'nd_protocol',
  7807. 'columns' => array(
  7808. 'nd_protocol_id' => 'nd_protocol_id',
  7809. ),
  7810. ),
  7811. ),
  7812. );
  7813. return $description;
  7814. }
  7815. /**
  7816. * Implements hook_chado_schema_v1_2_nd_experiment_pub()
  7817. * Purpose: To describe the structure of 'nd_experiment_pub' to tripal
  7818. * @see tripal_core_chado_insert()
  7819. * @see tripal_core_chado_update()
  7820. * @see tripal_core_chado_select()
  7821. *
  7822. * @return
  7823. * An array describing the 'nd_experiment_pub' table
  7824. *
  7825. * @ingroup tripal_chado_v1.2_schema_api
  7826. *
  7827. */
  7828. function tripal_core_chado_schema_v1_2_nd_experiment_pub() {
  7829. $description = array(
  7830. 'description' => 'TODO: please describe this table!',
  7831. 'fields' => array(
  7832. 'nd_experiment_pub_id' => array(
  7833. 'description' => 'TODO: please describe this field!',
  7834. 'type' => 'serial',
  7835. 'not null' => TRUE,
  7836. ),
  7837. 'nd_experiment_id' => array(
  7838. 'description' => 'TODO: please describe this field!',
  7839. 'type' => 'int',
  7840. 'not null' => TRUE,
  7841. ),
  7842. 'pub_id' => array(
  7843. 'description' => 'TODO: please describe this field!',
  7844. 'type' => 'int',
  7845. 'not null' => TRUE,
  7846. ),
  7847. ),
  7848. 'primary key' => array(
  7849. 0 => 'nd_experiment_pub_id',
  7850. ),
  7851. 'unique keys' => array(
  7852. 'nd_experiment_pub_c1' => array(
  7853. 0 => 'nd_experiment_id',
  7854. 1 => 'pub_id',
  7855. ),
  7856. ),
  7857. 'indexes' => array(
  7858. 'nd_experiment_pub_idx1' => array(
  7859. 0 => 'nd_experiment_id',
  7860. ),
  7861. 'nd_experiment_pub_idx2' => array(
  7862. 0 => 'pub_id',
  7863. ),
  7864. ),
  7865. 'foreign keys' => array(
  7866. 'pub' => array(
  7867. 'table' => 'pub',
  7868. 'columns' => array(
  7869. 'pub_id' => 'pub_id',
  7870. ),
  7871. ),
  7872. 'nd_experiment' => array(
  7873. 'table' => 'nd_experiment',
  7874. 'columns' => array(
  7875. 'nd_experiment_id' => 'nd_experiment_id',
  7876. ),
  7877. ),
  7878. ),
  7879. );
  7880. return $description;
  7881. }
  7882. /**
  7883. * Implements hook_chado_schema_v1_2_nd_experiment_stock()
  7884. * Purpose: To describe the structure of 'nd_experiment_stock' to tripal
  7885. * @see tripal_core_chado_insert()
  7886. * @see tripal_core_chado_update()
  7887. * @see tripal_core_chado_select()
  7888. *
  7889. * @return
  7890. * An array describing the 'nd_experiment_stock' table
  7891. *
  7892. * @ingroup tripal_chado_v1.2_schema_api
  7893. *
  7894. */
  7895. function tripal_core_chado_schema_v1_2_nd_experiment_stock() {
  7896. $description = array(
  7897. 'description' => 'TODO: please describe this table!',
  7898. 'fields' => array(
  7899. 'nd_experiment_stock_id' => array(
  7900. 'description' => 'TODO: please describe this field!',
  7901. 'type' => 'serial',
  7902. 'not null' => TRUE,
  7903. ),
  7904. 'nd_experiment_id' => array(
  7905. 'description' => 'TODO: please describe this field!',
  7906. 'type' => 'int',
  7907. 'not null' => TRUE,
  7908. ),
  7909. 'stock_id' => array(
  7910. 'description' => 'TODO: please describe this field!',
  7911. 'type' => 'int',
  7912. 'not null' => TRUE,
  7913. ),
  7914. 'type_id' => array(
  7915. 'description' => 'TODO: please describe this field!',
  7916. 'type' => 'int',
  7917. 'not null' => TRUE,
  7918. ),
  7919. ),
  7920. 'primary key' => array(
  7921. 0 => 'nd_experiment_stock_id',
  7922. ),
  7923. 'foreign keys' => array(
  7924. 'cvterm' => array(
  7925. 'table' => 'cvterm',
  7926. 'columns' => array(
  7927. 'type_id' => 'cvterm_id',
  7928. ),
  7929. ),
  7930. 'stock' => array(
  7931. 'table' => 'stock',
  7932. 'columns' => array(
  7933. 'stock_id' => 'stock_id',
  7934. ),
  7935. ),
  7936. 'nd_experiment' => array(
  7937. 'table' => 'nd_experiment',
  7938. 'columns' => array(
  7939. 'nd_experiment_id' => 'nd_experiment_id',
  7940. ),
  7941. ),
  7942. ),
  7943. );
  7944. return $description;
  7945. }
  7946. /**
  7947. * Implements hook_chado_schema_v1_2_nd_experiment_stock_dbxref()
  7948. * Purpose: To describe the structure of 'nd_experiment_stock_dbxref' to tripal
  7949. * @see tripal_core_chado_insert()
  7950. * @see tripal_core_chado_update()
  7951. * @see tripal_core_chado_select()
  7952. *
  7953. * @return
  7954. * An array describing the 'nd_experiment_stock_dbxref' table
  7955. *
  7956. * @ingroup tripal_chado_v1.2_schema_api
  7957. *
  7958. */
  7959. function tripal_core_chado_schema_v1_2_nd_experiment_stock_dbxref() {
  7960. $description = array(
  7961. 'description' => 'TODO: please describe this table!',
  7962. 'fields' => array(
  7963. 'nd_experiment_stock_dbxref_id' => array(
  7964. 'description' => 'TODO: please describe this field!',
  7965. 'type' => 'serial',
  7966. 'not null' => TRUE,
  7967. ),
  7968. 'nd_experiment_stock_id' => array(
  7969. 'description' => 'TODO: please describe this field!',
  7970. 'type' => 'int',
  7971. 'not null' => TRUE,
  7972. ),
  7973. 'dbxref_id' => array(
  7974. 'description' => 'TODO: please describe this field!',
  7975. 'type' => 'int',
  7976. 'not null' => TRUE,
  7977. ),
  7978. ),
  7979. 'primary key' => array(
  7980. 0 => 'nd_experiment_stock_dbxref_id',
  7981. ),
  7982. 'foreign keys' => array(
  7983. 'dbxref' => array(
  7984. 'table' => 'dbxref',
  7985. 'columns' => array(
  7986. 'dbxref_id' => 'dbxref_id',
  7987. ),
  7988. ),
  7989. 'nd_experiment_stock' => array(
  7990. 'table' => 'nd_experiment_stock',
  7991. 'columns' => array(
  7992. 'nd_experiment_stock_id' => 'nd_experiment_stock_id',
  7993. ),
  7994. ),
  7995. ),
  7996. );
  7997. return $description;
  7998. }
  7999. /**
  8000. * Implements hook_chado_schema_v1_2_nd_experiment_stockprop()
  8001. * Purpose: To describe the structure of 'nd_experiment_stockprop' to tripal
  8002. * @see tripal_core_chado_insert()
  8003. * @see tripal_core_chado_update()
  8004. * @see tripal_core_chado_select()
  8005. *
  8006. * @return
  8007. * An array describing the 'nd_experiment_stockprop' table
  8008. *
  8009. * @ingroup tripal_chado_v1.2_schema_api
  8010. *
  8011. */
  8012. function tripal_core_chado_schema_v1_2_nd_experiment_stockprop() {
  8013. $description = array(
  8014. 'description' => 'TODO: please describe this table!',
  8015. 'fields' => array(
  8016. 'nd_experiment_stockprop_id' => array(
  8017. 'description' => 'TODO: please describe this field!',
  8018. 'type' => 'serial',
  8019. 'not null' => TRUE,
  8020. ),
  8021. 'nd_experiment_stock_id' => array(
  8022. 'description' => 'TODO: please describe this field!',
  8023. 'type' => 'int',
  8024. 'not null' => TRUE,
  8025. ),
  8026. 'type_id' => array(
  8027. 'description' => 'TODO: please describe this field!',
  8028. 'type' => 'int',
  8029. 'not null' => TRUE,
  8030. ),
  8031. 'value' => array(
  8032. 'description' => 'TODO: please describe this field!',
  8033. 'type' => 'text',
  8034. 'not null' => FALSE,
  8035. ),
  8036. 'rank' => array(
  8037. 'description' => 'TODO: please describe this field!',
  8038. 'type' => 'int',
  8039. 'not null' => TRUE,
  8040. 'default' => 0,
  8041. ),
  8042. ),
  8043. 'primary key' => array(
  8044. 0 => 'nd_experiment_stockprop_id',
  8045. ),
  8046. 'unique keys' => array(
  8047. 'nd_experiment_stockprop_c1' => array(
  8048. 0 => 'nd_experiment_stock_id',
  8049. 1 => 'type_id',
  8050. 2 => 'rank',
  8051. ),
  8052. ),
  8053. 'foreign keys' => array(
  8054. 'cvterm' => array(
  8055. 'table' => 'cvterm',
  8056. 'columns' => array(
  8057. 'type_id' => 'cvterm_id',
  8058. ),
  8059. ),
  8060. 'nd_experiment_stock' => array(
  8061. 'table' => 'nd_experiment_stock',
  8062. 'columns' => array(
  8063. 'nd_experiment_stock_id' => 'nd_experiment_stock_id',
  8064. ),
  8065. ),
  8066. ),
  8067. );
  8068. return $description;
  8069. }
  8070. /**
  8071. * Implements hook_chado_schema_v1_2_nd_experimentprop()
  8072. * Purpose: To describe the structure of 'nd_experimentprop' to tripal
  8073. * @see tripal_core_chado_insert()
  8074. * @see tripal_core_chado_update()
  8075. * @see tripal_core_chado_select()
  8076. *
  8077. * @return
  8078. * An array describing the 'nd_experimentprop' table
  8079. *
  8080. * @ingroup tripal_chado_v1.2_schema_api
  8081. *
  8082. */
  8083. function tripal_core_chado_schema_v1_2_nd_experimentprop() {
  8084. $description = array(
  8085. 'description' => 'TODO: please describe this table!',
  8086. 'fields' => array(
  8087. 'nd_experimentprop_id' => array(
  8088. 'description' => 'TODO: please describe this field!',
  8089. 'type' => 'serial',
  8090. 'not null' => TRUE,
  8091. ),
  8092. 'nd_experiment_id' => array(
  8093. 'description' => 'TODO: please describe this field!',
  8094. 'type' => 'int',
  8095. 'not null' => TRUE,
  8096. ),
  8097. 'type_id' => array(
  8098. 'description' => 'TODO: please describe this field!',
  8099. 'type' => 'int',
  8100. 'not null' => TRUE,
  8101. ),
  8102. 'value' => array(
  8103. 'description' => 'TODO: please describe this field!',
  8104. 'type' => 'text',
  8105. 'not null' => FALSE,
  8106. ),
  8107. 'rank' => array(
  8108. 'description' => 'TODO: please describe this field!',
  8109. 'type' => 'int',
  8110. 'not null' => TRUE,
  8111. 'default' => 0,
  8112. ),
  8113. ),
  8114. 'primary key' => array(
  8115. 0 => 'nd_experimentprop_id',
  8116. ),
  8117. 'unique keys' => array(
  8118. 'nd_experimentprop_c1' => array(
  8119. 0 => 'nd_experiment_id',
  8120. 1 => 'type_id',
  8121. 2 => 'rank',
  8122. ),
  8123. ),
  8124. 'foreign keys' => array(
  8125. 'cvterm' => array(
  8126. 'table' => 'cvterm',
  8127. 'columns' => array(
  8128. 'type_id' => 'cvterm_id',
  8129. ),
  8130. ),
  8131. 'nd_experiment' => array(
  8132. 'table' => 'nd_experiment',
  8133. 'columns' => array(
  8134. 'nd_experiment_id' => 'nd_experiment_id',
  8135. ),
  8136. ),
  8137. ),
  8138. );
  8139. return $description;
  8140. }
  8141. /**
  8142. * Implements hook_chado_schema_v1_2_nd_geolocation()
  8143. * Purpose: To describe the structure of 'nd_geolocation' to tripal
  8144. * @see tripal_core_chado_insert()
  8145. * @see tripal_core_chado_update()
  8146. * @see tripal_core_chado_select()
  8147. *
  8148. * @return
  8149. * An array describing the 'nd_geolocation' table
  8150. *
  8151. * @ingroup tripal_chado_v1.2_schema_api
  8152. *
  8153. */
  8154. function tripal_core_chado_schema_v1_2_nd_geolocation() {
  8155. $description = array(
  8156. 'description' => 'TODO: please describe this table!',
  8157. 'fields' => array(
  8158. 'nd_geolocation_id' => array(
  8159. 'description' => 'TODO: please describe this field!',
  8160. 'type' => 'serial',
  8161. 'not null' => TRUE,
  8162. ),
  8163. 'description' => array(
  8164. 'description' => 'TODO: please describe this field!',
  8165. 'type' => 'varchar',
  8166. 'length' => '255',
  8167. 'not null' => FALSE,
  8168. ),
  8169. 'latitude' => array(
  8170. 'description' => 'TODO: please describe this field!',
  8171. 'type' => 'float',
  8172. 'not null' => FALSE,
  8173. ),
  8174. 'longitude' => array(
  8175. 'description' => 'TODO: please describe this field!',
  8176. 'type' => 'float',
  8177. 'not null' => FALSE,
  8178. ),
  8179. 'geodetic_datum' => array(
  8180. 'description' => 'TODO: please describe this field!',
  8181. 'type' => 'varchar',
  8182. 'length' => '32',
  8183. 'not null' => FALSE,
  8184. ),
  8185. 'altitude' => array(
  8186. 'description' => 'TODO: please describe this field!',
  8187. 'type' => 'float',
  8188. 'not null' => FALSE,
  8189. ),
  8190. ),
  8191. 'primary key' => array(
  8192. 0 => 'nd_geolocation_id',
  8193. ),
  8194. 'foreign keys' => array(
  8195. ),
  8196. );
  8197. return $description;
  8198. }
  8199. /**
  8200. * Implements hook_chado_schema_v1_2_nd_geolocationprop()
  8201. * Purpose: To describe the structure of 'nd_geolocationprop' to tripal
  8202. * @see tripal_core_chado_insert()
  8203. * @see tripal_core_chado_update()
  8204. * @see tripal_core_chado_select()
  8205. *
  8206. * @return
  8207. * An array describing the 'nd_geolocationprop' table
  8208. *
  8209. * @ingroup tripal_chado_v1.2_schema_api
  8210. *
  8211. */
  8212. function tripal_core_chado_schema_v1_2_nd_geolocationprop() {
  8213. $description = array(
  8214. 'description' => 'TODO: please describe this table!',
  8215. 'fields' => array(
  8216. 'nd_geolocationprop_id' => array(
  8217. 'description' => 'TODO: please describe this field!',
  8218. 'type' => 'serial',
  8219. 'not null' => TRUE,
  8220. ),
  8221. 'nd_geolocation_id' => array(
  8222. 'description' => 'TODO: please describe this field!',
  8223. 'type' => 'int',
  8224. 'not null' => TRUE,
  8225. ),
  8226. 'type_id' => array(
  8227. 'description' => 'TODO: please describe this field!',
  8228. 'type' => 'int',
  8229. 'not null' => TRUE,
  8230. ),
  8231. 'value' => array(
  8232. 'description' => 'TODO: please describe this field!',
  8233. 'type' => 'text',
  8234. 'not null' => FALSE,
  8235. ),
  8236. 'rank' => array(
  8237. 'description' => 'TODO: please describe this field!',
  8238. 'type' => 'int',
  8239. 'not null' => TRUE,
  8240. 'default' => 0,
  8241. ),
  8242. ),
  8243. 'primary key' => array(
  8244. 0 => 'nd_geolocationprop_id',
  8245. ),
  8246. 'unique keys' => array(
  8247. 'nd_geolocationprop_c1' => array(
  8248. 0 => 'nd_geolocation_id',
  8249. 1 => 'type_id',
  8250. 2 => 'rank',
  8251. ),
  8252. ),
  8253. 'foreign keys' => array(
  8254. 'cvterm' => array(
  8255. 'table' => 'cvterm',
  8256. 'columns' => array(
  8257. 'type_id' => 'cvterm_id',
  8258. ),
  8259. ),
  8260. 'nd_geolocation' => array(
  8261. 'table' => 'nd_geolocation',
  8262. 'columns' => array(
  8263. 'nd_geolocation_id' => 'nd_geolocation_id',
  8264. ),
  8265. ),
  8266. ),
  8267. );
  8268. return $description;
  8269. }
  8270. /**
  8271. * Implements hook_chado_schema_v1_2_nd_protocol()
  8272. * Purpose: To describe the structure of 'nd_protocol' to tripal
  8273. * @see tripal_core_chado_insert()
  8274. * @see tripal_core_chado_update()
  8275. * @see tripal_core_chado_select()
  8276. *
  8277. * @return
  8278. * An array describing the 'nd_protocol' table
  8279. *
  8280. * @ingroup tripal_chado_v1.2_schema_api
  8281. *
  8282. */
  8283. function tripal_core_chado_schema_v1_2_nd_protocol() {
  8284. $description = array(
  8285. 'description' => 'TODO: please describe this table!',
  8286. 'fields' => array(
  8287. 'nd_protocol_id' => array(
  8288. 'description' => 'TODO: please describe this field!',
  8289. 'type' => 'serial',
  8290. 'not null' => TRUE,
  8291. ),
  8292. 'name' => array(
  8293. 'description' => 'TODO: please describe this field!',
  8294. 'type' => 'varchar',
  8295. 'length' => '255',
  8296. 'not null' => TRUE,
  8297. ),
  8298. 'type_id' => array(
  8299. 'description' => 'TODO: please describe this field!',
  8300. 'type' => 'int',
  8301. 'not null' => TRUE,
  8302. ),
  8303. ),
  8304. 'primary key' => array(
  8305. 0 => 'nd_protocol_id',
  8306. ),
  8307. 'unique keys' => array(
  8308. 'name' => array(
  8309. 0 => 'name',
  8310. ),
  8311. ),
  8312. 'foreign keys' => array(
  8313. 'cvterm' => array(
  8314. 'table' => 'cvterm',
  8315. 'columns' => array(
  8316. 'type_id' => 'cvterm_id',
  8317. ),
  8318. ),
  8319. ),
  8320. );
  8321. return $description;
  8322. }
  8323. /**
  8324. * Implements hook_chado_schema_v1_2_nd_protocol_reagent()
  8325. * Purpose: To describe the structure of 'nd_protocol_reagent' to tripal
  8326. * @see tripal_core_chado_insert()
  8327. * @see tripal_core_chado_update()
  8328. * @see tripal_core_chado_select()
  8329. *
  8330. * @return
  8331. * An array describing the 'nd_protocol_reagent' table
  8332. *
  8333. * @ingroup tripal_chado_v1.2_schema_api
  8334. *
  8335. */
  8336. function tripal_core_chado_schema_v1_2_nd_protocol_reagent() {
  8337. $description = array(
  8338. 'description' => 'TODO: please describe this table!',
  8339. 'fields' => array(
  8340. 'nd_protocol_reagent_id' => array(
  8341. 'description' => 'TODO: please describe this field!',
  8342. 'type' => 'serial',
  8343. 'not null' => TRUE,
  8344. ),
  8345. 'nd_protocol_id' => array(
  8346. 'description' => 'TODO: please describe this field!',
  8347. 'type' => 'int',
  8348. 'not null' => TRUE,
  8349. ),
  8350. 'reagent_id' => array(
  8351. 'description' => 'TODO: please describe this field!',
  8352. 'type' => 'int',
  8353. 'not null' => TRUE,
  8354. ),
  8355. 'type_id' => array(
  8356. 'description' => 'TODO: please describe this field!',
  8357. 'type' => 'int',
  8358. 'not null' => TRUE,
  8359. ),
  8360. ),
  8361. 'primary key' => array(
  8362. 0 => 'nd_protocol_reagent_id',
  8363. ),
  8364. 'foreign keys' => array(
  8365. 'cvterm' => array(
  8366. 'table' => 'cvterm',
  8367. 'columns' => array(
  8368. 'type_id' => 'cvterm_id',
  8369. ),
  8370. ),
  8371. 'nd_protocol' => array(
  8372. 'table' => 'nd_protocol',
  8373. 'columns' => array(
  8374. 'nd_protocol_id' => 'nd_protocol_id',
  8375. ),
  8376. ),
  8377. 'nd_reagent' => array(
  8378. 'table' => 'nd_reagent',
  8379. 'columns' => array(
  8380. 'reagent_id' => 'nd_reagent_id',
  8381. ),
  8382. ),
  8383. ),
  8384. );
  8385. return $description;
  8386. }
  8387. /**
  8388. * Implements hook_chado_schema_v1_2_nd_protocolprop()
  8389. * Purpose: To describe the structure of 'nd_protocolprop' to tripal
  8390. * @see tripal_core_chado_insert()
  8391. * @see tripal_core_chado_update()
  8392. * @see tripal_core_chado_select()
  8393. *
  8394. * @return
  8395. * An array describing the 'nd_protocolprop' table
  8396. *
  8397. * @ingroup tripal_chado_v1.2_schema_api
  8398. *
  8399. */
  8400. function tripal_core_chado_schema_v1_2_nd_protocolprop() {
  8401. $description = array(
  8402. 'description' => 'TODO: please describe this table!',
  8403. 'fields' => array(
  8404. 'nd_protocolprop_id' => array(
  8405. 'description' => 'TODO: please describe this field!',
  8406. 'type' => 'serial',
  8407. 'not null' => TRUE,
  8408. ),
  8409. 'nd_protocol_id' => array(
  8410. 'description' => 'TODO: please describe this field!',
  8411. 'type' => 'int',
  8412. 'not null' => TRUE,
  8413. ),
  8414. 'type_id' => array(
  8415. 'description' => 'TODO: please describe this field!',
  8416. 'type' => 'int',
  8417. 'not null' => TRUE,
  8418. ),
  8419. 'value' => array(
  8420. 'description' => 'TODO: please describe this field!',
  8421. 'type' => 'text',
  8422. 'not null' => FALSE,
  8423. ),
  8424. 'rank' => array(
  8425. 'description' => 'TODO: please describe this field!',
  8426. 'type' => 'int',
  8427. 'not null' => TRUE,
  8428. 'default' => 0,
  8429. ),
  8430. ),
  8431. 'primary key' => array(
  8432. 0 => 'nd_protocolprop_id',
  8433. ),
  8434. 'unique keys' => array(
  8435. 'nd_protocolprop_c1' => array(
  8436. 0 => 'nd_protocol_id',
  8437. 1 => 'type_id',
  8438. 2 => 'rank',
  8439. ),
  8440. ),
  8441. 'foreign keys' => array(
  8442. 'cvterm' => array(
  8443. 'table' => 'cvterm',
  8444. 'columns' => array(
  8445. 'type_id' => 'cvterm_id',
  8446. ),
  8447. ),
  8448. 'nd_protocol' => array(
  8449. 'table' => 'nd_protocol',
  8450. 'columns' => array(
  8451. 'nd_protocol_id' => 'nd_protocol_id',
  8452. ),
  8453. ),
  8454. ),
  8455. );
  8456. return $description;
  8457. }
  8458. /**
  8459. * Implements hook_chado_schema_v1_2_nd_reagent()
  8460. * Purpose: To describe the structure of 'nd_reagent' to tripal
  8461. * @see tripal_core_chado_insert()
  8462. * @see tripal_core_chado_update()
  8463. * @see tripal_core_chado_select()
  8464. *
  8465. * @return
  8466. * An array describing the 'nd_reagent' table
  8467. *
  8468. * @ingroup tripal_chado_v1.2_schema_api
  8469. *
  8470. */
  8471. function tripal_core_chado_schema_v1_2_nd_reagent() {
  8472. $description = array(
  8473. 'description' => 'TODO: please describe this table!',
  8474. 'fields' => array(
  8475. 'nd_reagent_id' => array(
  8476. 'description' => 'TODO: please describe this field!',
  8477. 'type' => 'serial',
  8478. 'not null' => TRUE,
  8479. ),
  8480. 'name' => array(
  8481. 'description' => 'TODO: please describe this field!',
  8482. 'type' => 'varchar',
  8483. 'length' => '80',
  8484. 'not null' => TRUE,
  8485. ),
  8486. 'type_id' => array(
  8487. 'description' => 'TODO: please describe this field!',
  8488. 'type' => 'int',
  8489. 'not null' => TRUE,
  8490. ),
  8491. 'feature_id' => array(
  8492. 'description' => 'TODO: please describe this field!',
  8493. 'type' => 'int',
  8494. 'not null' => FALSE,
  8495. ),
  8496. ),
  8497. 'primary key' => array(
  8498. 0 => 'nd_reagent_id',
  8499. ),
  8500. 'foreign keys' => array(
  8501. 'cvterm' => array(
  8502. 'table' => 'cvterm',
  8503. 'columns' => array(
  8504. 'type_id' => 'cvterm_id',
  8505. ),
  8506. ),
  8507. ),
  8508. );
  8509. return $description;
  8510. }
  8511. /**
  8512. * Implements hook_chado_schema_v1_2_nd_reagent_relationship()
  8513. * Purpose: To describe the structure of 'nd_reagent_relationship' to tripal
  8514. * @see tripal_core_chado_insert()
  8515. * @see tripal_core_chado_update()
  8516. * @see tripal_core_chado_select()
  8517. *
  8518. * @return
  8519. * An array describing the 'nd_reagent_relationship' table
  8520. *
  8521. * @ingroup tripal_chado_v1.2_schema_api
  8522. *
  8523. */
  8524. function tripal_core_chado_schema_v1_2_nd_reagent_relationship() {
  8525. $description = array(
  8526. 'description' => 'TODO: please describe this table!',
  8527. 'fields' => array(
  8528. 'nd_reagent_relationship_id' => array(
  8529. 'description' => 'TODO: please describe this field!',
  8530. 'type' => 'serial',
  8531. 'not null' => TRUE,
  8532. ),
  8533. 'subject_reagent_id' => array(
  8534. 'description' => 'TODO: please describe this field!',
  8535. 'type' => 'int',
  8536. 'not null' => TRUE,
  8537. ),
  8538. 'object_reagent_id' => array(
  8539. 'description' => 'TODO: please describe this field!',
  8540. 'type' => 'int',
  8541. 'not null' => TRUE,
  8542. ),
  8543. 'type_id' => array(
  8544. 'description' => 'TODO: please describe this field!',
  8545. 'type' => 'int',
  8546. 'not null' => TRUE,
  8547. ),
  8548. ),
  8549. 'primary key' => array(
  8550. 0 => 'nd_reagent_relationship_id',
  8551. ),
  8552. 'foreign keys' => array(
  8553. 'cvterm' => array(
  8554. 'table' => 'cvterm',
  8555. 'columns' => array(
  8556. 'type_id' => 'cvterm_id',
  8557. ),
  8558. ),
  8559. 'nd_reagent' => array(
  8560. 'table' => 'nd_reagent',
  8561. 'columns' => array(
  8562. 'subject_reagent_id' => 'nd_reagent_id',
  8563. 'object_reagent_id' => 'nd_reagent_id',
  8564. ),
  8565. ),
  8566. ),
  8567. );
  8568. return $description;
  8569. }
  8570. /**
  8571. * Implements hook_chado_schema_v1_2_nd_reagentprop()
  8572. * Purpose: To describe the structure of 'nd_reagentprop' to tripal
  8573. * @see tripal_core_chado_insert()
  8574. * @see tripal_core_chado_update()
  8575. * @see tripal_core_chado_select()
  8576. *
  8577. * @return
  8578. * An array describing the 'nd_reagentprop' table
  8579. *
  8580. * @ingroup tripal_chado_v1.2_schema_api
  8581. *
  8582. */
  8583. function tripal_core_chado_schema_v1_2_nd_reagentprop() {
  8584. $description = array(
  8585. 'description' => 'TODO: please describe this table!',
  8586. 'fields' => array(
  8587. 'nd_reagentprop_id' => array(
  8588. 'description' => 'TODO: please describe this field!',
  8589. 'type' => 'serial',
  8590. 'not null' => TRUE,
  8591. ),
  8592. 'nd_reagent_id' => array(
  8593. 'description' => 'TODO: please describe this field!',
  8594. 'type' => 'int',
  8595. 'not null' => TRUE,
  8596. ),
  8597. 'type_id' => array(
  8598. 'description' => 'TODO: please describe this field!',
  8599. 'type' => 'int',
  8600. 'not null' => TRUE,
  8601. ),
  8602. 'value' => array(
  8603. 'description' => 'TODO: please describe this field!',
  8604. 'type' => 'text',
  8605. 'not null' => FALSE,
  8606. ),
  8607. 'rank' => array(
  8608. 'description' => 'TODO: please describe this field!',
  8609. 'type' => 'int',
  8610. 'not null' => TRUE,
  8611. 'default' => 0,
  8612. ),
  8613. ),
  8614. 'primary key' => array(
  8615. 0 => 'nd_reagentprop_id',
  8616. ),
  8617. 'unique keys' => array(
  8618. 'nd_reagentprop_c1' => array(
  8619. 0 => 'nd_reagent_id',
  8620. 1 => 'type_id',
  8621. 2 => 'rank',
  8622. ),
  8623. ),
  8624. 'foreign keys' => array(
  8625. 'cvterm' => array(
  8626. 'table' => 'cvterm',
  8627. 'columns' => array(
  8628. 'type_id' => 'cvterm_id',
  8629. ),
  8630. ),
  8631. 'nd_reagent' => array(
  8632. 'table' => 'nd_reagent',
  8633. 'columns' => array(
  8634. 'nd_reagent_id' => 'nd_reagent_id',
  8635. ),
  8636. ),
  8637. ),
  8638. );
  8639. return $description;
  8640. }
  8641. /**
  8642. * Implements hook_chado_schema_v1_2_organism()
  8643. * Purpose: To describe the structure of 'organism' to tripal
  8644. * @see tripal_core_chado_insert()
  8645. * @see tripal_core_chado_update()
  8646. * @see tripal_core_chado_select()
  8647. *
  8648. * @return
  8649. * An array describing the 'organism' table
  8650. *
  8651. * @ingroup tripal_chado_v1.2_schema_api
  8652. *
  8653. */
  8654. function tripal_core_chado_schema_v1_2_organism() {
  8655. $description = array(
  8656. 'description' => 'TODO: please describe this table!',
  8657. 'fields' => array(
  8658. 'organism_id' => array(
  8659. 'description' => 'TODO: please describe this field!',
  8660. 'type' => 'serial',
  8661. 'not null' => TRUE,
  8662. ),
  8663. 'abbreviation' => array(
  8664. 'description' => 'TODO: please describe this field!',
  8665. 'type' => 'varchar',
  8666. 'length' => '255',
  8667. 'not null' => FALSE,
  8668. ),
  8669. 'genus' => array(
  8670. 'description' => 'TODO: please describe this field!',
  8671. 'type' => 'varchar',
  8672. 'length' => '255',
  8673. 'not null' => TRUE,
  8674. ),
  8675. 'species' => array(
  8676. 'description' => 'TODO: please describe this field!',
  8677. 'type' => 'varchar',
  8678. 'length' => '255',
  8679. 'not null' => TRUE,
  8680. ),
  8681. 'common_name' => array(
  8682. 'description' => 'TODO: please describe this field!',
  8683. 'type' => 'varchar',
  8684. 'length' => '255',
  8685. 'not null' => FALSE,
  8686. ),
  8687. 'comment' => array(
  8688. 'description' => 'TODO: please describe this field!',
  8689. 'type' => 'text',
  8690. 'not null' => FALSE,
  8691. ),
  8692. ),
  8693. 'primary key' => array(
  8694. 0 => 'organism_id',
  8695. ),
  8696. 'unique keys' => array(
  8697. 'organism_c1' => array(
  8698. 0 => 'genus',
  8699. 1 => 'species',
  8700. ),
  8701. ),
  8702. 'foreign keys' => array(
  8703. ),
  8704. );
  8705. return $description;
  8706. }
  8707. /**
  8708. * Implements hook_chado_schema_v1_2_organism_dbxref()
  8709. * Purpose: To describe the structure of 'organism_dbxref' to tripal
  8710. * @see tripal_core_chado_insert()
  8711. * @see tripal_core_chado_update()
  8712. * @see tripal_core_chado_select()
  8713. *
  8714. * @return
  8715. * An array describing the 'organism_dbxref' table
  8716. *
  8717. * @ingroup tripal_chado_v1.2_schema_api
  8718. *
  8719. */
  8720. function tripal_core_chado_schema_v1_2_organism_dbxref() {
  8721. $description = array(
  8722. 'description' => 'TODO: please describe this table!',
  8723. 'fields' => array(
  8724. 'organism_dbxref_id' => array(
  8725. 'description' => 'TODO: please describe this field!',
  8726. 'type' => 'serial',
  8727. 'not null' => TRUE,
  8728. ),
  8729. 'organism_id' => array(
  8730. 'description' => 'TODO: please describe this field!',
  8731. 'type' => 'int',
  8732. 'not null' => TRUE,
  8733. ),
  8734. 'dbxref_id' => array(
  8735. 'description' => 'TODO: please describe this field!',
  8736. 'type' => 'int',
  8737. 'not null' => TRUE,
  8738. ),
  8739. ),
  8740. 'primary key' => array(
  8741. 0 => 'organism_dbxref_id',
  8742. ),
  8743. 'unique keys' => array(
  8744. 'organism_dbxref_c1' => array(
  8745. 0 => 'organism_id',
  8746. 1 => 'dbxref_id',
  8747. ),
  8748. ),
  8749. 'indexes' => array(
  8750. 'organism_dbxref_idx1' => array(
  8751. 0 => 'organism_id',
  8752. ),
  8753. 'organism_dbxref_idx2' => array(
  8754. 0 => 'dbxref_id',
  8755. ),
  8756. ),
  8757. 'foreign keys' => array(
  8758. 'organism' => array(
  8759. 'table' => 'organism',
  8760. 'columns' => array(
  8761. 'organism_id' => 'organism_id',
  8762. ),
  8763. ),
  8764. 'dbxref' => array(
  8765. 'table' => 'dbxref',
  8766. 'columns' => array(
  8767. 'dbxref_id' => 'dbxref_id',
  8768. ),
  8769. ),
  8770. ),
  8771. );
  8772. return $description;
  8773. }
  8774. /**
  8775. * Implements hook_chado_schema_v1_2_organism_feature_count()
  8776. * Purpose: To describe the structure of 'organism_feature_count' to tripal
  8777. * @see tripal_core_chado_insert()
  8778. * @see tripal_core_chado_update()
  8779. * @see tripal_core_chado_select()
  8780. *
  8781. * @return
  8782. * An array describing the 'organism_feature_count' table
  8783. *
  8784. * @ingroup tripal_chado_v1.2_schema_api
  8785. *
  8786. */
  8787. function tripal_core_chado_schema_v1_2_organism_feature_count() {
  8788. $description = array(
  8789. );
  8790. return $description;
  8791. }
  8792. /**
  8793. * Implements hook_chado_schema_v1_2_organismprop()
  8794. * Purpose: To describe the structure of 'organismprop' to tripal
  8795. * @see tripal_core_chado_insert()
  8796. * @see tripal_core_chado_update()
  8797. * @see tripal_core_chado_select()
  8798. *
  8799. * @return
  8800. * An array describing the 'organismprop' table
  8801. *
  8802. * @ingroup tripal_chado_v1.2_schema_api
  8803. *
  8804. */
  8805. function tripal_core_chado_schema_v1_2_organismprop() {
  8806. $description = array(
  8807. 'description' => 'TODO: please describe this table!',
  8808. 'fields' => array(
  8809. 'organismprop_id' => array(
  8810. 'description' => 'TODO: please describe this field!',
  8811. 'type' => 'serial',
  8812. 'not null' => TRUE,
  8813. ),
  8814. 'organism_id' => array(
  8815. 'description' => 'TODO: please describe this field!',
  8816. 'type' => 'int',
  8817. 'not null' => TRUE,
  8818. ),
  8819. 'type_id' => array(
  8820. 'description' => 'TODO: please describe this field!',
  8821. 'type' => 'int',
  8822. 'not null' => TRUE,
  8823. ),
  8824. 'value' => array(
  8825. 'description' => 'TODO: please describe this field!',
  8826. 'type' => 'text',
  8827. 'not null' => FALSE,
  8828. ),
  8829. 'rank' => array(
  8830. 'description' => 'TODO: please describe this field!',
  8831. 'type' => 'int',
  8832. 'not null' => TRUE,
  8833. 'default' => 0,
  8834. ),
  8835. ),
  8836. 'primary key' => array(
  8837. 0 => 'organismprop_id',
  8838. ),
  8839. 'unique keys' => array(
  8840. 'organismprop_c1' => array(
  8841. 0 => 'organism_id',
  8842. 1 => 'type_id',
  8843. 2 => 'rank',
  8844. ),
  8845. ),
  8846. 'indexes' => array(
  8847. 'organismprop_idx1' => array(
  8848. 0 => 'organism_id',
  8849. ),
  8850. 'organismprop_idx2' => array(
  8851. 0 => 'type_id',
  8852. ),
  8853. ),
  8854. 'foreign keys' => array(
  8855. 'organism' => array(
  8856. 'table' => 'organism',
  8857. 'columns' => array(
  8858. 'organism_id' => 'organism_id',
  8859. ),
  8860. ),
  8861. 'cvterm' => array(
  8862. 'table' => 'cvterm',
  8863. 'columns' => array(
  8864. 'type_id' => 'cvterm_id',
  8865. ),
  8866. ),
  8867. ),
  8868. );
  8869. return $description;
  8870. }
  8871. /**
  8872. * Implements hook_chado_schema_v1_2_phendesc()
  8873. * Purpose: To describe the structure of 'phendesc' to tripal
  8874. * @see tripal_core_chado_insert()
  8875. * @see tripal_core_chado_update()
  8876. * @see tripal_core_chado_select()
  8877. *
  8878. * @return
  8879. * An array describing the 'phendesc' table
  8880. *
  8881. * @ingroup tripal_chado_v1.2_schema_api
  8882. *
  8883. */
  8884. function tripal_core_chado_schema_v1_2_phendesc() {
  8885. $description = array(
  8886. 'description' => 'TODO: please describe this table!',
  8887. 'fields' => array(
  8888. 'phendesc_id' => array(
  8889. 'description' => 'TODO: please describe this field!',
  8890. 'type' => 'serial',
  8891. 'not null' => TRUE,
  8892. ),
  8893. 'genotype_id' => array(
  8894. 'description' => 'TODO: please describe this field!',
  8895. 'type' => 'int',
  8896. 'not null' => TRUE,
  8897. ),
  8898. 'environment_id' => array(
  8899. 'description' => 'TODO: please describe this field!',
  8900. 'type' => 'int',
  8901. 'not null' => TRUE,
  8902. ),
  8903. 'description' => array(
  8904. 'description' => 'TODO: please describe this field!',
  8905. 'type' => 'text',
  8906. 'not null' => TRUE,
  8907. ),
  8908. 'type_id' => array(
  8909. 'description' => 'TODO: please describe this field!',
  8910. 'type' => 'int',
  8911. 'not null' => TRUE,
  8912. ),
  8913. 'pub_id' => array(
  8914. 'description' => 'TODO: please describe this field!',
  8915. 'type' => 'int',
  8916. 'not null' => TRUE,
  8917. ),
  8918. ),
  8919. 'primary key' => array(
  8920. 0 => 'phendesc_id',
  8921. ),
  8922. 'unique keys' => array(
  8923. 'phendesc_c1' => array(
  8924. 0 => 'genotype_id',
  8925. 1 => 'environment_id',
  8926. 2 => 'type_id',
  8927. 3 => 'pub_id',
  8928. ),
  8929. ),
  8930. 'indexes' => array(
  8931. 'phendesc_idx1' => array(
  8932. 0 => 'genotype_id',
  8933. ),
  8934. 'phendesc_idx2' => array(
  8935. 0 => 'environment_id',
  8936. ),
  8937. 'phendesc_idx3' => array(
  8938. 0 => 'pub_id',
  8939. ),
  8940. ),
  8941. 'foreign keys' => array(
  8942. 'cvterm' => array(
  8943. 'table' => 'cvterm',
  8944. 'columns' => array(
  8945. 'type_id' => 'cvterm_id',
  8946. ),
  8947. ),
  8948. 'pub' => array(
  8949. 'table' => 'pub',
  8950. 'columns' => array(
  8951. 'pub_id' => 'pub_id',
  8952. ),
  8953. ),
  8954. 'genotype' => array(
  8955. 'table' => 'genotype',
  8956. 'columns' => array(
  8957. 'genotype_id' => 'genotype_id',
  8958. ),
  8959. ),
  8960. 'environment' => array(
  8961. 'table' => 'environment',
  8962. 'columns' => array(
  8963. 'environment_id' => 'environment_id',
  8964. ),
  8965. ),
  8966. ),
  8967. );
  8968. return $description;
  8969. }
  8970. /**
  8971. * Implements hook_chado_schema_v1_2_phenotype()
  8972. * Purpose: To describe the structure of 'phenotype' to tripal
  8973. * @see tripal_core_chado_insert()
  8974. * @see tripal_core_chado_update()
  8975. * @see tripal_core_chado_select()
  8976. *
  8977. * @return
  8978. * An array describing the 'phenotype' table
  8979. *
  8980. * @ingroup tripal_chado_v1.2_schema_api
  8981. *
  8982. */
  8983. function tripal_core_chado_schema_v1_2_phenotype() {
  8984. $description = array(
  8985. 'description' => 'TODO: please describe this table!',
  8986. 'fields' => array(
  8987. 'phenotype_id' => array(
  8988. 'description' => 'TODO: please describe this field!',
  8989. 'type' => 'serial',
  8990. 'not null' => TRUE,
  8991. ),
  8992. 'uniquename' => array(
  8993. 'description' => 'TODO: please describe this field!',
  8994. 'type' => 'text',
  8995. 'not null' => TRUE,
  8996. ),
  8997. 'name' => array(
  8998. 'description' => 'TODO: please describe this field!',
  8999. 'type' => 'text',
  9000. 'not null' => FALSE,
  9001. ),
  9002. 'observable_id' => array(
  9003. 'description' => 'TODO: please describe this field!',
  9004. 'type' => 'int',
  9005. 'not null' => FALSE,
  9006. ),
  9007. 'attr_id' => array(
  9008. 'description' => 'TODO: please describe this field!',
  9009. 'type' => 'int',
  9010. 'not null' => FALSE,
  9011. ),
  9012. 'value' => array(
  9013. 'description' => 'TODO: please describe this field!',
  9014. 'type' => 'text',
  9015. 'not null' => FALSE,
  9016. ),
  9017. 'cvalue_id' => array(
  9018. 'description' => 'TODO: please describe this field!',
  9019. 'type' => 'int',
  9020. 'not null' => FALSE,
  9021. ),
  9022. 'assay_id' => array(
  9023. 'description' => 'TODO: please describe this field!',
  9024. 'type' => 'int',
  9025. 'not null' => FALSE,
  9026. ),
  9027. ),
  9028. 'primary key' => array(
  9029. 0 => 'phenotype_id',
  9030. ),
  9031. 'unique keys' => array(
  9032. 'phenotype_c1' => array(
  9033. 0 => 'uniquename',
  9034. ),
  9035. ),
  9036. 'indexes' => array(
  9037. 'phenotype_idx1' => array(
  9038. 0 => 'cvalue_id',
  9039. ),
  9040. 'phenotype_idx2' => array(
  9041. 0 => 'observable_id',
  9042. ),
  9043. 'phenotype_idx3' => array(
  9044. 0 => 'attr_id',
  9045. ),
  9046. ),
  9047. 'foreign keys' => array(
  9048. 'cvterm' => array(
  9049. 'table' => 'cvterm',
  9050. 'columns' => array(
  9051. 'observable_id' => 'cvterm_id',
  9052. 'attr_id' => 'cvterm_id',
  9053. 'cvalue_id' => 'cvterm_id',
  9054. 'assay_id' => 'cvterm_id',
  9055. ),
  9056. ),
  9057. ),
  9058. );
  9059. return $description;
  9060. }
  9061. /**
  9062. * Implements hook_chado_schema_v1_2_phenotype_comparison()
  9063. * Purpose: To describe the structure of 'phenotype_comparison' to tripal
  9064. * @see tripal_core_chado_insert()
  9065. * @see tripal_core_chado_update()
  9066. * @see tripal_core_chado_select()
  9067. *
  9068. * @return
  9069. * An array describing the 'phenotype_comparison' table
  9070. *
  9071. * @ingroup tripal_chado_v1.2_schema_api
  9072. *
  9073. */
  9074. function tripal_core_chado_schema_v1_2_phenotype_comparison() {
  9075. $description = array(
  9076. 'description' => 'TODO: please describe this table!',
  9077. 'fields' => array(
  9078. 'phenotype_comparison_id' => array(
  9079. 'description' => 'TODO: please describe this field!',
  9080. 'type' => 'serial',
  9081. 'not null' => TRUE,
  9082. ),
  9083. 'genotype1_id' => array(
  9084. 'description' => 'TODO: please describe this field!',
  9085. 'type' => 'int',
  9086. 'not null' => TRUE,
  9087. ),
  9088. 'environment1_id' => array(
  9089. 'description' => 'TODO: please describe this field!',
  9090. 'type' => 'int',
  9091. 'not null' => TRUE,
  9092. ),
  9093. 'genotype2_id' => array(
  9094. 'description' => 'TODO: please describe this field!',
  9095. 'type' => 'int',
  9096. 'not null' => TRUE,
  9097. ),
  9098. 'environment2_id' => array(
  9099. 'description' => 'TODO: please describe this field!',
  9100. 'type' => 'int',
  9101. 'not null' => TRUE,
  9102. ),
  9103. 'phenotype1_id' => array(
  9104. 'description' => 'TODO: please describe this field!',
  9105. 'type' => 'int',
  9106. 'not null' => TRUE,
  9107. ),
  9108. 'phenotype2_id' => array(
  9109. 'description' => 'TODO: please describe this field!',
  9110. 'type' => 'int',
  9111. 'not null' => FALSE,
  9112. ),
  9113. 'pub_id' => array(
  9114. 'description' => 'TODO: please describe this field!',
  9115. 'type' => 'int',
  9116. 'not null' => TRUE,
  9117. ),
  9118. 'organism_id' => array(
  9119. 'description' => 'TODO: please describe this field!',
  9120. 'type' => 'int',
  9121. 'not null' => TRUE,
  9122. ),
  9123. ),
  9124. 'primary key' => array(
  9125. 0 => 'phenotype_comparison_id',
  9126. ),
  9127. 'unique keys' => array(
  9128. 'phenotype_comparison_c1' => array(
  9129. 0 => 'genotype1_id',
  9130. 1 => 'environment1_id',
  9131. 2 => 'genotype2_id',
  9132. 3 => 'environment2_id',
  9133. 4 => 'phenotype1_id',
  9134. 5 => 'pub_id',
  9135. ),
  9136. ),
  9137. 'indexes' => array(
  9138. 'phenotype_comparison_idx1' => array(
  9139. 0 => 'genotype1_id',
  9140. ),
  9141. 'phenotype_comparison_idx2' => array(
  9142. 0 => 'genotype2_id',
  9143. ),
  9144. 'phenotype_comparison_idx4' => array(
  9145. 0 => 'pub_id',
  9146. ),
  9147. ),
  9148. 'foreign keys' => array(
  9149. 'organism' => array(
  9150. 'table' => 'organism',
  9151. 'columns' => array(
  9152. 'organism_id' => 'organism_id',
  9153. ),
  9154. ),
  9155. 'pub' => array(
  9156. 'table' => 'pub',
  9157. 'columns' => array(
  9158. 'pub_id' => 'pub_id',
  9159. ),
  9160. ),
  9161. 'genotype' => array(
  9162. 'table' => 'genotype',
  9163. 'columns' => array(
  9164. 'genotype1_id' => 'genotype_id',
  9165. 'genotype2_id' => 'genotype_id',
  9166. ),
  9167. ),
  9168. 'environment' => array(
  9169. 'table' => 'environment',
  9170. 'columns' => array(
  9171. 'environment1_id' => 'environment_id',
  9172. 'environment2_id' => 'environment_id',
  9173. ),
  9174. ),
  9175. 'phenotype' => array(
  9176. 'table' => 'phenotype',
  9177. 'columns' => array(
  9178. 'phenotype1_id' => 'phenotype_id',
  9179. 'phenotype2_id' => 'phenotype_id',
  9180. ),
  9181. ),
  9182. ),
  9183. );
  9184. return $description;
  9185. }
  9186. /**
  9187. * Implements hook_chado_schema_v1_2_phenotype_comparison_cvterm()
  9188. * Purpose: To describe the structure of 'phenotype_comparison_cvterm' to tripal
  9189. * @see tripal_core_chado_insert()
  9190. * @see tripal_core_chado_update()
  9191. * @see tripal_core_chado_select()
  9192. *
  9193. * @return
  9194. * An array describing the 'phenotype_comparison_cvterm' table
  9195. *
  9196. * @ingroup tripal_chado_v1.2_schema_api
  9197. *
  9198. */
  9199. function tripal_core_chado_schema_v1_2_phenotype_comparison_cvterm() {
  9200. $description = array(
  9201. 'description' => 'TODO: please describe this table!',
  9202. 'fields' => array(
  9203. 'phenotype_comparison_cvterm_id' => array(
  9204. 'description' => 'TODO: please describe this field!',
  9205. 'type' => 'serial',
  9206. 'not null' => TRUE,
  9207. ),
  9208. 'phenotype_comparison_id' => array(
  9209. 'description' => 'TODO: please describe this field!',
  9210. 'type' => 'int',
  9211. 'not null' => TRUE,
  9212. ),
  9213. 'cvterm_id' => array(
  9214. 'description' => 'TODO: please describe this field!',
  9215. 'type' => 'int',
  9216. 'not null' => TRUE,
  9217. ),
  9218. 'pub_id' => array(
  9219. 'description' => 'TODO: please describe this field!',
  9220. 'type' => 'int',
  9221. 'not null' => TRUE,
  9222. ),
  9223. 'rank' => array(
  9224. 'description' => 'TODO: please describe this field!',
  9225. 'type' => 'int',
  9226. 'not null' => TRUE,
  9227. 'default' => 0,
  9228. ),
  9229. ),
  9230. 'primary key' => array(
  9231. 0 => 'phenotype_comparison_cvterm_id',
  9232. ),
  9233. 'unique keys' => array(
  9234. 'phenotype_comparison_cvterm_c1' => array(
  9235. 0 => 'phenotype_comparison_id',
  9236. 1 => 'cvterm_id',
  9237. ),
  9238. ),
  9239. 'indexes' => array(
  9240. 'phenotype_comparison_cvterm_idx1' => array(
  9241. 0 => 'phenotype_comparison_id',
  9242. ),
  9243. 'phenotype_comparison_cvterm_idx2' => array(
  9244. 0 => 'cvterm_id',
  9245. ),
  9246. ),
  9247. 'foreign keys' => array(
  9248. 'cvterm' => array(
  9249. 'table' => 'cvterm',
  9250. 'columns' => array(
  9251. 'cvterm_id' => 'cvterm_id',
  9252. ),
  9253. ),
  9254. 'pub' => array(
  9255. 'table' => 'pub',
  9256. 'columns' => array(
  9257. 'pub_id' => 'pub_id',
  9258. ),
  9259. ),
  9260. 'phenotype_comparison' => array(
  9261. 'table' => 'phenotype_comparison',
  9262. 'columns' => array(
  9263. 'phenotype_comparison_id' => 'phenotype_comparison_id',
  9264. ),
  9265. ),
  9266. ),
  9267. );
  9268. return $description;
  9269. }
  9270. /**
  9271. * Implements hook_chado_schema_v1_2_phenotype_cvterm()
  9272. * Purpose: To describe the structure of 'phenotype_cvterm' to tripal
  9273. * @see tripal_core_chado_insert()
  9274. * @see tripal_core_chado_update()
  9275. * @see tripal_core_chado_select()
  9276. *
  9277. * @return
  9278. * An array describing the 'phenotype_cvterm' table
  9279. *
  9280. * @ingroup tripal_chado_v1.2_schema_api
  9281. *
  9282. */
  9283. function tripal_core_chado_schema_v1_2_phenotype_cvterm() {
  9284. $description = array(
  9285. 'description' => 'TODO: please describe this table!',
  9286. 'fields' => array(
  9287. 'phenotype_cvterm_id' => array(
  9288. 'description' => 'TODO: please describe this field!',
  9289. 'type' => 'serial',
  9290. 'not null' => TRUE,
  9291. ),
  9292. 'phenotype_id' => array(
  9293. 'description' => 'TODO: please describe this field!',
  9294. 'type' => 'int',
  9295. 'not null' => TRUE,
  9296. ),
  9297. 'cvterm_id' => array(
  9298. 'description' => 'TODO: please describe this field!',
  9299. 'type' => 'int',
  9300. 'not null' => TRUE,
  9301. ),
  9302. 'rank' => array(
  9303. 'description' => 'TODO: please describe this field!',
  9304. 'type' => 'int',
  9305. 'not null' => TRUE,
  9306. 'default' => 0,
  9307. ),
  9308. ),
  9309. 'primary key' => array(
  9310. 0 => 'phenotype_cvterm_id',
  9311. ),
  9312. 'unique keys' => array(
  9313. 'phenotype_cvterm_c1' => array(
  9314. 0 => 'phenotype_id',
  9315. 1 => 'cvterm_id',
  9316. 2 => 'rank',
  9317. ),
  9318. ),
  9319. 'indexes' => array(
  9320. 'phenotype_cvterm_idx1' => array(
  9321. 0 => 'phenotype_id',
  9322. ),
  9323. 'phenotype_cvterm_idx2' => array(
  9324. 0 => 'cvterm_id',
  9325. ),
  9326. ),
  9327. 'foreign keys' => array(
  9328. 'cvterm' => array(
  9329. 'table' => 'cvterm',
  9330. 'columns' => array(
  9331. 'cvterm_id' => 'cvterm_id',
  9332. ),
  9333. ),
  9334. 'phenotype' => array(
  9335. 'table' => 'phenotype',
  9336. 'columns' => array(
  9337. 'phenotype_id' => 'phenotype_id',
  9338. ),
  9339. ),
  9340. ),
  9341. );
  9342. return $description;
  9343. }
  9344. /**
  9345. * Implements hook_chado_schema_v1_2_phenstatement()
  9346. * Purpose: To describe the structure of 'phenstatement' to tripal
  9347. * @see tripal_core_chado_insert()
  9348. * @see tripal_core_chado_update()
  9349. * @see tripal_core_chado_select()
  9350. *
  9351. * @return
  9352. * An array describing the 'phenstatement' table
  9353. *
  9354. * @ingroup tripal_chado_v1.2_schema_api
  9355. *
  9356. */
  9357. function tripal_core_chado_schema_v1_2_phenstatement() {
  9358. $description = array(
  9359. 'description' => 'TODO: please describe this table!',
  9360. 'fields' => array(
  9361. 'phenstatement_id' => array(
  9362. 'description' => 'TODO: please describe this field!',
  9363. 'type' => 'serial',
  9364. 'not null' => TRUE,
  9365. ),
  9366. 'genotype_id' => array(
  9367. 'description' => 'TODO: please describe this field!',
  9368. 'type' => 'int',
  9369. 'not null' => TRUE,
  9370. ),
  9371. 'environment_id' => array(
  9372. 'description' => 'TODO: please describe this field!',
  9373. 'type' => 'int',
  9374. 'not null' => TRUE,
  9375. ),
  9376. 'phenotype_id' => array(
  9377. 'description' => 'TODO: please describe this field!',
  9378. 'type' => 'int',
  9379. 'not null' => TRUE,
  9380. ),
  9381. 'type_id' => array(
  9382. 'description' => 'TODO: please describe this field!',
  9383. 'type' => 'int',
  9384. 'not null' => TRUE,
  9385. ),
  9386. 'pub_id' => array(
  9387. 'description' => 'TODO: please describe this field!',
  9388. 'type' => 'int',
  9389. 'not null' => TRUE,
  9390. ),
  9391. ),
  9392. 'primary key' => array(
  9393. 0 => 'phenstatement_id',
  9394. ),
  9395. 'unique keys' => array(
  9396. 'phenstatement_c1' => array(
  9397. 0 => 'genotype_id',
  9398. 1 => 'phenotype_id',
  9399. 2 => 'environment_id',
  9400. 3 => 'type_id',
  9401. 4 => 'pub_id',
  9402. ),
  9403. ),
  9404. 'indexes' => array(
  9405. 'phenstatement_idx1' => array(
  9406. 0 => 'genotype_id',
  9407. ),
  9408. 'phenstatement_idx2' => array(
  9409. 0 => 'phenotype_id',
  9410. ),
  9411. ),
  9412. 'foreign keys' => array(
  9413. 'cvterm' => array(
  9414. 'table' => 'cvterm',
  9415. 'columns' => array(
  9416. 'type_id' => 'cvterm_id',
  9417. ),
  9418. ),
  9419. 'pub' => array(
  9420. 'table' => 'pub',
  9421. 'columns' => array(
  9422. 'pub_id' => 'pub_id',
  9423. ),
  9424. ),
  9425. 'genotype' => array(
  9426. 'table' => 'genotype',
  9427. 'columns' => array(
  9428. 'genotype_id' => 'genotype_id',
  9429. ),
  9430. ),
  9431. 'environment' => array(
  9432. 'table' => 'environment',
  9433. 'columns' => array(
  9434. 'environment_id' => 'environment_id',
  9435. ),
  9436. ),
  9437. 'phenotype' => array(
  9438. 'table' => 'phenotype',
  9439. 'columns' => array(
  9440. 'phenotype_id' => 'phenotype_id',
  9441. ),
  9442. ),
  9443. ),
  9444. );
  9445. return $description;
  9446. }
  9447. /**
  9448. * Implements hook_chado_schema_v1_2_phylonode()
  9449. * Purpose: To describe the structure of 'phylonode' to tripal
  9450. * @see tripal_core_chado_insert()
  9451. * @see tripal_core_chado_update()
  9452. * @see tripal_core_chado_select()
  9453. *
  9454. * @return
  9455. * An array describing the 'phylonode' table
  9456. *
  9457. * @ingroup tripal_chado_v1.2_schema_api
  9458. *
  9459. */
  9460. function tripal_core_chado_schema_v1_2_phylonode() {
  9461. $description = array(
  9462. 'description' => 'TODO: please describe this table!',
  9463. 'fields' => array(
  9464. 'phylonode_id' => array(
  9465. 'description' => 'TODO: please describe this field!',
  9466. 'type' => 'serial',
  9467. 'not null' => TRUE,
  9468. ),
  9469. 'phylotree_id' => array(
  9470. 'description' => 'TODO: please describe this field!',
  9471. 'type' => 'int',
  9472. 'not null' => TRUE,
  9473. ),
  9474. 'parent_phylonode_id' => array(
  9475. 'description' => 'TODO: please describe this field!',
  9476. 'type' => 'int',
  9477. 'not null' => FALSE,
  9478. ),
  9479. 'left_idx' => array(
  9480. 'description' => 'TODO: please describe this field!',
  9481. 'type' => 'int',
  9482. 'not null' => TRUE,
  9483. ),
  9484. 'right_idx' => array(
  9485. 'description' => 'TODO: please describe this field!',
  9486. 'type' => 'int',
  9487. 'not null' => TRUE,
  9488. ),
  9489. 'type_id' => array(
  9490. 'description' => 'TODO: please describe this field!',
  9491. 'type' => 'int',
  9492. 'not null' => FALSE,
  9493. ),
  9494. 'feature_id' => array(
  9495. 'description' => 'TODO: please describe this field!',
  9496. 'type' => 'int',
  9497. 'not null' => FALSE,
  9498. ),
  9499. 'label' => array(
  9500. 'description' => 'TODO: please describe this field!',
  9501. 'type' => 'varchar',
  9502. 'length' => '255',
  9503. 'not null' => FALSE,
  9504. ),
  9505. 'distance' => array(
  9506. 'description' => 'TODO: please describe this field!',
  9507. 'type' => 'float',
  9508. 'size' => 'big',
  9509. 'not null' => FALSE,
  9510. ),
  9511. ),
  9512. 'primary key' => array(
  9513. 0 => 'phylonode_id',
  9514. ),
  9515. 'unique keys' => array(
  9516. 'phylotree_id' => array(
  9517. 0 => 'phylotree_id',
  9518. 1 => 'left_idx',
  9519. ),
  9520. 'phylonode_phylotree_id_key1' => array(
  9521. 0 => 'phylotree_id',
  9522. 1 => 'right_idx',
  9523. ),
  9524. ),
  9525. 'foreign keys' => array(
  9526. 'cvterm' => array(
  9527. 'table' => 'cvterm',
  9528. 'columns' => array(
  9529. 'type_id' => 'cvterm_id',
  9530. ),
  9531. ),
  9532. 'feature' => array(
  9533. 'table' => 'feature',
  9534. 'columns' => array(
  9535. 'feature_id' => 'feature_id',
  9536. ),
  9537. ),
  9538. 'phylonode' => array(
  9539. 'table' => 'phylonode',
  9540. 'columns' => array(
  9541. 'parent_phylonode_id' => 'phylonode_id',
  9542. ),
  9543. ),
  9544. 'phylotree' => array(
  9545. 'table' => 'phylotree',
  9546. 'columns' => array(
  9547. 'phylotree_id' => 'phylotree_id',
  9548. ),
  9549. ),
  9550. ),
  9551. );
  9552. return $description;
  9553. }
  9554. /**
  9555. * Implements hook_chado_schema_v1_2_phylonode_dbxref()
  9556. * Purpose: To describe the structure of 'phylonode_dbxref' to tripal
  9557. * @see tripal_core_chado_insert()
  9558. * @see tripal_core_chado_update()
  9559. * @see tripal_core_chado_select()
  9560. *
  9561. * @return
  9562. * An array describing the 'phylonode_dbxref' table
  9563. *
  9564. * @ingroup tripal_chado_v1.2_schema_api
  9565. *
  9566. */
  9567. function tripal_core_chado_schema_v1_2_phylonode_dbxref() {
  9568. $description = array(
  9569. 'description' => 'TODO: please describe this table!',
  9570. 'fields' => array(
  9571. 'phylonode_dbxref_id' => array(
  9572. 'description' => 'TODO: please describe this field!',
  9573. 'type' => 'serial',
  9574. 'not null' => TRUE,
  9575. ),
  9576. 'phylonode_id' => array(
  9577. 'description' => 'TODO: please describe this field!',
  9578. 'type' => 'int',
  9579. 'not null' => TRUE,
  9580. ),
  9581. 'dbxref_id' => array(
  9582. 'description' => 'TODO: please describe this field!',
  9583. 'type' => 'int',
  9584. 'not null' => TRUE,
  9585. ),
  9586. ),
  9587. 'primary key' => array(
  9588. 0 => 'phylonode_dbxref_id',
  9589. ),
  9590. 'unique keys' => array(
  9591. 'phylonode_id' => array(
  9592. 0 => 'phylonode_id',
  9593. 1 => 'dbxref_id',
  9594. ),
  9595. ),
  9596. 'indexes' => array(
  9597. 'phylonode_dbxref_idx1' => array(
  9598. 0 => 'phylonode_id',
  9599. ),
  9600. 'phylonode_dbxref_idx2' => array(
  9601. 0 => 'dbxref_id',
  9602. ),
  9603. ),
  9604. 'foreign keys' => array(
  9605. 'dbxref' => array(
  9606. 'table' => 'dbxref',
  9607. 'columns' => array(
  9608. 'dbxref_id' => 'dbxref_id',
  9609. ),
  9610. ),
  9611. 'phylonode' => array(
  9612. 'table' => 'phylonode',
  9613. 'columns' => array(
  9614. 'phylonode_id' => 'phylonode_id',
  9615. ),
  9616. ),
  9617. ),
  9618. );
  9619. return $description;
  9620. }
  9621. /**
  9622. * Implements hook_chado_schema_v1_2_phylonode_organism()
  9623. * Purpose: To describe the structure of 'phylonode_organism' to tripal
  9624. * @see tripal_core_chado_insert()
  9625. * @see tripal_core_chado_update()
  9626. * @see tripal_core_chado_select()
  9627. *
  9628. * @return
  9629. * An array describing the 'phylonode_organism' table
  9630. *
  9631. * @ingroup tripal_chado_v1.2_schema_api
  9632. *
  9633. */
  9634. function tripal_core_chado_schema_v1_2_phylonode_organism() {
  9635. $description = array(
  9636. 'description' => 'TODO: please describe this table!',
  9637. 'fields' => array(
  9638. 'phylonode_organism_id' => array(
  9639. 'description' => 'TODO: please describe this field!',
  9640. 'type' => 'serial',
  9641. 'not null' => TRUE,
  9642. ),
  9643. 'phylonode_id' => array(
  9644. 'description' => 'TODO: please describe this field!',
  9645. 'type' => 'int',
  9646. 'not null' => TRUE,
  9647. ),
  9648. 'organism_id' => array(
  9649. 'description' => 'TODO: please describe this field!',
  9650. 'type' => 'int',
  9651. 'not null' => TRUE,
  9652. ),
  9653. ),
  9654. 'primary key' => array(
  9655. 0 => 'phylonode_organism_id',
  9656. ),
  9657. 'unique keys' => array(
  9658. 'phylonode_id' => array(
  9659. 0 => 'phylonode_id',
  9660. ),
  9661. ),
  9662. 'indexes' => array(
  9663. 'phylonode_organism_idx1' => array(
  9664. 0 => 'phylonode_id',
  9665. ),
  9666. 'phylonode_organism_idx2' => array(
  9667. 0 => 'organism_id',
  9668. ),
  9669. ),
  9670. 'foreign keys' => array(
  9671. 'organism' => array(
  9672. 'table' => 'organism',
  9673. 'columns' => array(
  9674. 'organism_id' => 'organism_id',
  9675. ),
  9676. ),
  9677. 'phylonode' => array(
  9678. 'table' => 'phylonode',
  9679. 'columns' => array(
  9680. 'phylonode_id' => 'phylonode_id',
  9681. ),
  9682. ),
  9683. ),
  9684. );
  9685. return $description;
  9686. }
  9687. /**
  9688. * Implements hook_chado_schema_v1_2_phylonode_pub()
  9689. * Purpose: To describe the structure of 'phylonode_pub' to tripal
  9690. * @see tripal_core_chado_insert()
  9691. * @see tripal_core_chado_update()
  9692. * @see tripal_core_chado_select()
  9693. *
  9694. * @return
  9695. * An array describing the 'phylonode_pub' table
  9696. *
  9697. * @ingroup tripal_chado_v1.2_schema_api
  9698. *
  9699. */
  9700. function tripal_core_chado_schema_v1_2_phylonode_pub() {
  9701. $description = array(
  9702. 'description' => 'TODO: please describe this table!',
  9703. 'fields' => array(
  9704. 'phylonode_pub_id' => array(
  9705. 'description' => 'TODO: please describe this field!',
  9706. 'type' => 'serial',
  9707. 'not null' => TRUE,
  9708. ),
  9709. 'phylonode_id' => array(
  9710. 'description' => 'TODO: please describe this field!',
  9711. 'type' => 'int',
  9712. 'not null' => TRUE,
  9713. ),
  9714. 'pub_id' => array(
  9715. 'description' => 'TODO: please describe this field!',
  9716. 'type' => 'int',
  9717. 'not null' => TRUE,
  9718. ),
  9719. ),
  9720. 'primary key' => array(
  9721. 0 => 'phylonode_pub_id',
  9722. ),
  9723. 'unique keys' => array(
  9724. 'phylonode_id' => array(
  9725. 0 => 'phylonode_id',
  9726. 1 => 'pub_id',
  9727. ),
  9728. ),
  9729. 'indexes' => array(
  9730. 'phylonode_pub_idx1' => array(
  9731. 0 => 'phylonode_id',
  9732. ),
  9733. 'phylonode_pub_idx2' => array(
  9734. 0 => 'pub_id',
  9735. ),
  9736. ),
  9737. 'foreign keys' => array(
  9738. 'pub' => array(
  9739. 'table' => 'pub',
  9740. 'columns' => array(
  9741. 'pub_id' => 'pub_id',
  9742. ),
  9743. ),
  9744. 'phylonode' => array(
  9745. 'table' => 'phylonode',
  9746. 'columns' => array(
  9747. 'phylonode_id' => 'phylonode_id',
  9748. ),
  9749. ),
  9750. ),
  9751. );
  9752. return $description;
  9753. }
  9754. /**
  9755. * Implements hook_chado_schema_v1_2_phylonode_relationship()
  9756. * Purpose: To describe the structure of 'phylonode_relationship' to tripal
  9757. * @see tripal_core_chado_insert()
  9758. * @see tripal_core_chado_update()
  9759. * @see tripal_core_chado_select()
  9760. *
  9761. * @return
  9762. * An array describing the 'phylonode_relationship' table
  9763. *
  9764. * @ingroup tripal_chado_v1.2_schema_api
  9765. *
  9766. */
  9767. function tripal_core_chado_schema_v1_2_phylonode_relationship() {
  9768. $description = array(
  9769. 'description' => 'TODO: please describe this table!',
  9770. 'fields' => array(
  9771. 'phylonode_relationship_id' => array(
  9772. 'description' => 'TODO: please describe this field!',
  9773. 'type' => 'serial',
  9774. 'not null' => TRUE,
  9775. ),
  9776. 'subject_id' => array(
  9777. 'description' => 'TODO: please describe this field!',
  9778. 'type' => 'int',
  9779. 'not null' => TRUE,
  9780. ),
  9781. 'object_id' => array(
  9782. 'description' => 'TODO: please describe this field!',
  9783. 'type' => 'int',
  9784. 'not null' => TRUE,
  9785. ),
  9786. 'type_id' => array(
  9787. 'description' => 'TODO: please describe this field!',
  9788. 'type' => 'int',
  9789. 'not null' => TRUE,
  9790. ),
  9791. 'rank' => array(
  9792. 'description' => 'TODO: please describe this field!',
  9793. 'type' => 'int',
  9794. 'not null' => FALSE,
  9795. ),
  9796. 'phylotree_id' => array(
  9797. 'description' => 'TODO: please describe this field!',
  9798. 'type' => 'int',
  9799. 'not null' => TRUE,
  9800. ),
  9801. ),
  9802. 'primary key' => array(
  9803. 0 => 'phylonode_relationship_id',
  9804. ),
  9805. 'unique keys' => array(
  9806. 'subject_id' => array(
  9807. 0 => 'subject_id',
  9808. 1 => 'object_id',
  9809. 2 => 'type_id',
  9810. ),
  9811. ),
  9812. 'indexes' => array(
  9813. 'phylonode_relationship_idx1' => array(
  9814. 0 => 'subject_id',
  9815. ),
  9816. 'phylonode_relationship_idx2' => array(
  9817. 0 => 'object_id',
  9818. ),
  9819. 'phylonode_relationship_idx3' => array(
  9820. 0 => 'type_id',
  9821. ),
  9822. ),
  9823. 'foreign keys' => array(
  9824. 'cvterm' => array(
  9825. 'table' => 'cvterm',
  9826. 'columns' => array(
  9827. 'type_id' => 'cvterm_id',
  9828. ),
  9829. ),
  9830. 'phylonode' => array(
  9831. 'table' => 'phylonode',
  9832. 'columns' => array(
  9833. 'subject_id' => 'phylonode_id',
  9834. 'object_id' => 'phylonode_id',
  9835. ),
  9836. ),
  9837. 'phylotree' => array(
  9838. 'table' => 'phylotree',
  9839. 'columns' => array(
  9840. 'phylotree_id' => 'phylotree_id',
  9841. ),
  9842. ),
  9843. ),
  9844. );
  9845. return $description;
  9846. }
  9847. /**
  9848. * Implements hook_chado_schema_v1_2_phylonodeprop()
  9849. * Purpose: To describe the structure of 'phylonodeprop' to tripal
  9850. * @see tripal_core_chado_insert()
  9851. * @see tripal_core_chado_update()
  9852. * @see tripal_core_chado_select()
  9853. *
  9854. * @return
  9855. * An array describing the 'phylonodeprop' table
  9856. *
  9857. * @ingroup tripal_chado_v1.2_schema_api
  9858. *
  9859. */
  9860. function tripal_core_chado_schema_v1_2_phylonodeprop() {
  9861. $description = array(
  9862. 'description' => 'TODO: please describe this table!',
  9863. 'fields' => array(
  9864. 'phylonodeprop_id' => array(
  9865. 'description' => 'TODO: please describe this field!',
  9866. 'type' => 'serial',
  9867. 'not null' => TRUE,
  9868. ),
  9869. 'phylonode_id' => array(
  9870. 'description' => 'TODO: please describe this field!',
  9871. 'type' => 'int',
  9872. 'not null' => TRUE,
  9873. ),
  9874. 'type_id' => array(
  9875. 'description' => 'TODO: please describe this field!',
  9876. 'type' => 'int',
  9877. 'not null' => TRUE,
  9878. ),
  9879. 'value' => array(
  9880. 'description' => 'TODO: please describe this field!',
  9881. 'type' => 'text',
  9882. 'not null' => TRUE,
  9883. 'default' => '',
  9884. ),
  9885. 'rank' => array(
  9886. 'description' => 'TODO: please describe this field!',
  9887. 'type' => 'int',
  9888. 'not null' => TRUE,
  9889. 'default' => 0,
  9890. ),
  9891. ),
  9892. 'primary key' => array(
  9893. 0 => 'phylonodeprop_id',
  9894. ),
  9895. 'unique keys' => array(
  9896. 'phylonode_id' => array(
  9897. 0 => 'phylonode_id',
  9898. 1 => 'type_id',
  9899. 2 => 'value',
  9900. 3 => 'rank',
  9901. ),
  9902. ),
  9903. 'indexes' => array(
  9904. 'phylonodeprop_idx1' => array(
  9905. 0 => 'phylonode_id',
  9906. ),
  9907. 'phylonodeprop_idx2' => array(
  9908. 0 => 'type_id',
  9909. ),
  9910. ),
  9911. 'foreign keys' => array(
  9912. 'cvterm' => array(
  9913. 'table' => 'cvterm',
  9914. 'columns' => array(
  9915. 'type_id' => 'cvterm_id',
  9916. ),
  9917. ),
  9918. 'phylonode' => array(
  9919. 'table' => 'phylonode',
  9920. 'columns' => array(
  9921. 'phylonode_id' => 'phylonode_id',
  9922. ),
  9923. ),
  9924. ),
  9925. );
  9926. return $description;
  9927. }
  9928. /**
  9929. * Implements hook_chado_schema_v1_2_phylotree()
  9930. * Purpose: To describe the structure of 'phylotree' to tripal
  9931. * @see tripal_core_chado_insert()
  9932. * @see tripal_core_chado_update()
  9933. * @see tripal_core_chado_select()
  9934. *
  9935. * @return
  9936. * An array describing the 'phylotree' table
  9937. *
  9938. * @ingroup tripal_chado_v1.2_schema_api
  9939. *
  9940. */
  9941. function tripal_core_chado_schema_v1_2_phylotree() {
  9942. $description = array(
  9943. 'description' => 'TODO: please describe this table!',
  9944. 'fields' => array(
  9945. 'phylotree_id' => array(
  9946. 'description' => 'TODO: please describe this field!',
  9947. 'type' => 'serial',
  9948. 'not null' => TRUE,
  9949. ),
  9950. 'dbxref_id' => array(
  9951. 'description' => 'TODO: please describe this field!',
  9952. 'type' => 'int',
  9953. 'not null' => TRUE,
  9954. ),
  9955. 'name' => array(
  9956. 'description' => 'TODO: please describe this field!',
  9957. 'type' => 'varchar',
  9958. 'length' => '255',
  9959. 'not null' => FALSE,
  9960. ),
  9961. 'type_id' => array(
  9962. 'description' => 'TODO: please describe this field!',
  9963. 'type' => 'int',
  9964. 'not null' => FALSE,
  9965. ),
  9966. 'analysis_id' => array(
  9967. 'description' => 'TODO: please describe this field!',
  9968. 'type' => 'int',
  9969. 'not null' => FALSE,
  9970. ),
  9971. 'comment' => array(
  9972. 'description' => 'TODO: please describe this field!',
  9973. 'type' => 'text',
  9974. 'not null' => FALSE,
  9975. ),
  9976. ),
  9977. 'primary key' => array(
  9978. 0 => 'phylotree_id',
  9979. ),
  9980. 'indexes' => array(
  9981. 'phylotree_idx1' => array(
  9982. 0 => 'phylotree_id',
  9983. ),
  9984. ),
  9985. 'foreign keys' => array(
  9986. 'cvterm' => array(
  9987. 'table' => 'cvterm',
  9988. 'columns' => array(
  9989. 'type_id' => 'cvterm_id',
  9990. ),
  9991. ),
  9992. 'dbxref' => array(
  9993. 'table' => 'dbxref',
  9994. 'columns' => array(
  9995. 'dbxref_id' => 'dbxref_id',
  9996. ),
  9997. ),
  9998. 'analysis' => array(
  9999. 'table' => 'analysis',
  10000. 'columns' => array(
  10001. 'analysis_id' => 'analysis_id',
  10002. ),
  10003. ),
  10004. ),
  10005. );
  10006. return $description;
  10007. }
  10008. /**
  10009. * Implements hook_chado_schema_v1_2_phylotree_pub()
  10010. * Purpose: To describe the structure of 'phylotree_pub' to tripal
  10011. * @see tripal_core_chado_insert()
  10012. * @see tripal_core_chado_update()
  10013. * @see tripal_core_chado_select()
  10014. *
  10015. * @return
  10016. * An array describing the 'phylotree_pub' table
  10017. *
  10018. * @ingroup tripal_chado_v1.2_schema_api
  10019. *
  10020. */
  10021. function tripal_core_chado_schema_v1_2_phylotree_pub() {
  10022. $description = array(
  10023. 'description' => 'TODO: please describe this table!',
  10024. 'fields' => array(
  10025. 'phylotree_pub_id' => array(
  10026. 'description' => 'TODO: please describe this field!',
  10027. 'type' => 'serial',
  10028. 'not null' => TRUE,
  10029. ),
  10030. 'phylotree_id' => array(
  10031. 'description' => 'TODO: please describe this field!',
  10032. 'type' => 'int',
  10033. 'not null' => TRUE,
  10034. ),
  10035. 'pub_id' => array(
  10036. 'description' => 'TODO: please describe this field!',
  10037. 'type' => 'int',
  10038. 'not null' => TRUE,
  10039. ),
  10040. ),
  10041. 'primary key' => array(
  10042. 0 => 'phylotree_pub_id',
  10043. ),
  10044. 'unique keys' => array(
  10045. 'phylotree_id' => array(
  10046. 0 => 'phylotree_id',
  10047. 1 => 'pub_id',
  10048. ),
  10049. ),
  10050. 'indexes' => array(
  10051. 'phylotree_pub_idx1' => array(
  10052. 0 => 'phylotree_id',
  10053. ),
  10054. 'phylotree_pub_idx2' => array(
  10055. 0 => 'pub_id',
  10056. ),
  10057. ),
  10058. 'foreign keys' => array(
  10059. 'pub' => array(
  10060. 'table' => 'pub',
  10061. 'columns' => array(
  10062. 'pub_id' => 'pub_id',
  10063. ),
  10064. ),
  10065. 'phylotree' => array(
  10066. 'table' => 'phylotree',
  10067. 'columns' => array(
  10068. 'phylotree_id' => 'phylotree_id',
  10069. ),
  10070. ),
  10071. ),
  10072. );
  10073. return $description;
  10074. }
  10075. /**
  10076. * Implements hook_chado_schema_v1_2_project()
  10077. * Purpose: To describe the structure of 'project' to tripal
  10078. * @see tripal_core_chado_insert()
  10079. * @see tripal_core_chado_update()
  10080. * @see tripal_core_chado_select()
  10081. *
  10082. * @return
  10083. * An array describing the 'project' table
  10084. *
  10085. * @ingroup tripal_chado_v1.2_schema_api
  10086. *
  10087. */
  10088. function tripal_core_chado_schema_v1_2_project() {
  10089. $description = array(
  10090. 'description' => 'TODO: please describe this table!',
  10091. 'fields' => array(
  10092. 'project_id' => array(
  10093. 'description' => 'TODO: please describe this field!',
  10094. 'type' => 'serial',
  10095. 'not null' => TRUE,
  10096. ),
  10097. 'name' => array(
  10098. 'description' => 'TODO: please describe this field!',
  10099. 'type' => 'varchar',
  10100. 'length' => '255',
  10101. 'not null' => TRUE,
  10102. ),
  10103. 'description' => array(
  10104. 'description' => 'TODO: please describe this field!',
  10105. 'type' => 'varchar',
  10106. 'length' => '255',
  10107. 'not null' => TRUE,
  10108. ),
  10109. ),
  10110. 'primary key' => array(
  10111. 0 => 'project_id',
  10112. ),
  10113. 'unique keys' => array(
  10114. 'project_c1' => array(
  10115. 0 => 'name',
  10116. ),
  10117. ),
  10118. 'foreign keys' => array(
  10119. ),
  10120. );
  10121. return $description;
  10122. }
  10123. /**
  10124. * Implements hook_chado_schema_v1_2_project_contact()
  10125. * Purpose: To describe the structure of 'project_contact' to tripal
  10126. * @see tripal_core_chado_insert()
  10127. * @see tripal_core_chado_update()
  10128. * @see tripal_core_chado_select()
  10129. *
  10130. * @return
  10131. * An array describing the 'project_contact' table
  10132. *
  10133. * @ingroup tripal_chado_v1.2_schema_api
  10134. *
  10135. */
  10136. function tripal_core_chado_schema_v1_2_project_contact() {
  10137. $description = array(
  10138. 'description' => 'TODO: please describe this table!',
  10139. 'fields' => array(
  10140. 'project_contact_id' => array(
  10141. 'description' => 'TODO: please describe this field!',
  10142. 'type' => 'serial',
  10143. 'not null' => TRUE,
  10144. ),
  10145. 'project_id' => array(
  10146. 'description' => 'TODO: please describe this field!',
  10147. 'type' => 'int',
  10148. 'not null' => TRUE,
  10149. ),
  10150. 'contact_id' => array(
  10151. 'description' => 'TODO: please describe this field!',
  10152. 'type' => 'int',
  10153. 'not null' => TRUE,
  10154. ),
  10155. ),
  10156. 'primary key' => array(
  10157. 0 => 'project_contact_id',
  10158. ),
  10159. 'unique keys' => array(
  10160. 'project_contact_c1' => array(
  10161. 0 => 'project_id',
  10162. 1 => 'contact_id',
  10163. ),
  10164. ),
  10165. 'indexes' => array(
  10166. 'project_contact_idx1' => array(
  10167. 0 => 'project_id',
  10168. ),
  10169. 'project_contact_idx2' => array(
  10170. 0 => 'contact_id',
  10171. ),
  10172. ),
  10173. 'foreign keys' => array(
  10174. 'contact' => array(
  10175. 'table' => 'contact',
  10176. 'columns' => array(
  10177. 'contact_id' => 'contact_id',
  10178. ),
  10179. ),
  10180. 'project' => array(
  10181. 'table' => 'project',
  10182. 'columns' => array(
  10183. 'project_id' => 'project_id',
  10184. ),
  10185. ),
  10186. ),
  10187. );
  10188. return $description;
  10189. }
  10190. /**
  10191. * Implements hook_chado_schema_v1_2_project_pub()
  10192. * Purpose: To describe the structure of 'project_pub' to tripal
  10193. * @see tripal_core_chado_insert()
  10194. * @see tripal_core_chado_update()
  10195. * @see tripal_core_chado_select()
  10196. *
  10197. * @return
  10198. * An array describing the 'project_pub' table
  10199. *
  10200. * @ingroup tripal_chado_v1.2_schema_api
  10201. *
  10202. */
  10203. function tripal_core_chado_schema_v1_2_project_pub() {
  10204. $description = array(
  10205. 'description' => 'TODO: please describe this table!',
  10206. 'fields' => array(
  10207. 'project_pub_id' => array(
  10208. 'description' => 'TODO: please describe this field!',
  10209. 'type' => 'serial',
  10210. 'not null' => TRUE,
  10211. ),
  10212. 'project_id' => array(
  10213. 'description' => 'TODO: please describe this field!',
  10214. 'type' => 'int',
  10215. 'not null' => TRUE,
  10216. ),
  10217. 'pub_id' => array(
  10218. 'description' => 'TODO: please describe this field!',
  10219. 'type' => 'int',
  10220. 'not null' => TRUE,
  10221. ),
  10222. ),
  10223. 'primary key' => array(
  10224. 0 => 'project_pub_id',
  10225. ),
  10226. 'unique keys' => array(
  10227. 'project_pub_c1' => array(
  10228. 0 => 'project_id',
  10229. 1 => 'pub_id',
  10230. ),
  10231. ),
  10232. 'indexes' => array(
  10233. 'project_pub_idx1' => array(
  10234. 0 => 'project_id',
  10235. ),
  10236. 'project_pub_idx2' => array(
  10237. 0 => 'pub_id',
  10238. ),
  10239. ),
  10240. 'foreign keys' => array(
  10241. 'pub' => array(
  10242. 'table' => 'pub',
  10243. 'columns' => array(
  10244. 'pub_id' => 'pub_id',
  10245. ),
  10246. ),
  10247. 'project' => array(
  10248. 'table' => 'project',
  10249. 'columns' => array(
  10250. 'project_id' => 'project_id',
  10251. ),
  10252. ),
  10253. ),
  10254. );
  10255. return $description;
  10256. }
  10257. /**
  10258. * Implements hook_chado_schema_v1_2_project_relationship()
  10259. * Purpose: To describe the structure of 'project_relationship' to tripal
  10260. * @see tripal_core_chado_insert()
  10261. * @see tripal_core_chado_update()
  10262. * @see tripal_core_chado_select()
  10263. *
  10264. * @return
  10265. * An array describing the 'project_relationship' table
  10266. *
  10267. * @ingroup tripal_chado_v1.2_schema_api
  10268. *
  10269. */
  10270. function tripal_core_chado_schema_v1_2_project_relationship() {
  10271. $description = array(
  10272. 'description' => 'TODO: please describe this table!',
  10273. 'fields' => array(
  10274. 'project_relationship_id' => array(
  10275. 'description' => 'TODO: please describe this field!',
  10276. 'type' => 'serial',
  10277. 'not null' => TRUE,
  10278. ),
  10279. 'subject_project_id' => array(
  10280. 'description' => 'TODO: please describe this field!',
  10281. 'type' => 'int',
  10282. 'not null' => TRUE,
  10283. ),
  10284. 'object_project_id' => array(
  10285. 'description' => 'TODO: please describe this field!',
  10286. 'type' => 'int',
  10287. 'not null' => TRUE,
  10288. ),
  10289. 'type_id' => array(
  10290. 'description' => 'TODO: please describe this field!',
  10291. 'type' => 'int',
  10292. 'not null' => TRUE,
  10293. ),
  10294. ),
  10295. 'primary key' => array(
  10296. 0 => 'project_relationship_id',
  10297. ),
  10298. 'unique keys' => array(
  10299. 'project_relationship_c1' => array(
  10300. 0 => 'subject_project_id',
  10301. 1 => 'object_project_id',
  10302. 2 => 'type_id',
  10303. ),
  10304. ),
  10305. 'foreign keys' => array(
  10306. 'cvterm' => array(
  10307. 'table' => 'cvterm',
  10308. 'columns' => array(
  10309. 'type_id' => 'cvterm_id',
  10310. ),
  10311. ),
  10312. 'project' => array(
  10313. 'table' => 'project',
  10314. 'columns' => array(
  10315. 'subject_project_id' => 'project_id',
  10316. 'object_project_id' => 'project_id',
  10317. ),
  10318. ),
  10319. ),
  10320. );
  10321. return $description;
  10322. }
  10323. /**
  10324. * Implements hook_chado_schema_v1_2_projectprop()
  10325. * Purpose: To describe the structure of 'projectprop' to tripal
  10326. * @see tripal_core_chado_insert()
  10327. * @see tripal_core_chado_update()
  10328. * @see tripal_core_chado_select()
  10329. *
  10330. * @return
  10331. * An array describing the 'projectprop' table
  10332. *
  10333. * @ingroup tripal_chado_v1.2_schema_api
  10334. *
  10335. */
  10336. function tripal_core_chado_schema_v1_2_projectprop() {
  10337. $description = array(
  10338. 'description' => 'TODO: please describe this table!',
  10339. 'fields' => array(
  10340. 'projectprop_id' => array(
  10341. 'description' => 'TODO: please describe this field!',
  10342. 'type' => 'serial',
  10343. 'not null' => TRUE,
  10344. ),
  10345. 'project_id' => array(
  10346. 'description' => 'TODO: please describe this field!',
  10347. 'type' => 'int',
  10348. 'not null' => TRUE,
  10349. ),
  10350. 'type_id' => array(
  10351. 'description' => 'TODO: please describe this field!',
  10352. 'type' => 'int',
  10353. 'not null' => TRUE,
  10354. ),
  10355. 'value' => array(
  10356. 'description' => 'TODO: please describe this field!',
  10357. 'type' => 'text',
  10358. 'not null' => FALSE,
  10359. ),
  10360. 'rank' => array(
  10361. 'description' => 'TODO: please describe this field!',
  10362. 'type' => 'int',
  10363. 'not null' => TRUE,
  10364. 'default' => 0,
  10365. ),
  10366. ),
  10367. 'primary key' => array(
  10368. 0 => 'projectprop_id',
  10369. ),
  10370. 'unique keys' => array(
  10371. 'projectprop_c1' => array(
  10372. 0 => 'project_id',
  10373. 1 => 'type_id',
  10374. 2 => 'rank',
  10375. ),
  10376. ),
  10377. 'foreign keys' => array(
  10378. 'cvterm' => array(
  10379. 'table' => 'cvterm',
  10380. 'columns' => array(
  10381. 'type_id' => 'cvterm_id',
  10382. ),
  10383. ),
  10384. 'project' => array(
  10385. 'table' => 'project',
  10386. 'columns' => array(
  10387. 'project_id' => 'project_id',
  10388. ),
  10389. ),
  10390. ),
  10391. );
  10392. return $description;
  10393. }
  10394. /**
  10395. * Implements hook_chado_schema_v1_2_protocol()
  10396. * Purpose: To describe the structure of 'protocol' to tripal
  10397. * @see tripal_core_chado_insert()
  10398. * @see tripal_core_chado_update()
  10399. * @see tripal_core_chado_select()
  10400. *
  10401. * @return
  10402. * An array describing the 'protocol' table
  10403. *
  10404. * @ingroup tripal_chado_v1.2_schema_api
  10405. *
  10406. */
  10407. function tripal_core_chado_schema_v1_2_protocol() {
  10408. $description = array(
  10409. 'description' => 'TODO: please describe this table!',
  10410. 'fields' => array(
  10411. 'protocol_id' => array(
  10412. 'description' => 'TODO: please describe this field!',
  10413. 'type' => 'serial',
  10414. 'not null' => TRUE,
  10415. ),
  10416. 'type_id' => array(
  10417. 'description' => 'TODO: please describe this field!',
  10418. 'type' => 'int',
  10419. 'not null' => TRUE,
  10420. ),
  10421. 'pub_id' => array(
  10422. 'description' => 'TODO: please describe this field!',
  10423. 'type' => 'int',
  10424. 'not null' => FALSE,
  10425. ),
  10426. 'dbxref_id' => array(
  10427. 'description' => 'TODO: please describe this field!',
  10428. 'type' => 'int',
  10429. 'not null' => FALSE,
  10430. ),
  10431. 'name' => array(
  10432. 'description' => 'TODO: please describe this field!',
  10433. 'type' => 'text',
  10434. 'not null' => TRUE,
  10435. ),
  10436. 'uri' => array(
  10437. 'description' => 'TODO: please describe this field!',
  10438. 'type' => 'text',
  10439. 'not null' => FALSE,
  10440. ),
  10441. 'protocoldescription' => array(
  10442. 'description' => 'TODO: please describe this field!',
  10443. 'type' => 'text',
  10444. 'not null' => FALSE,
  10445. ),
  10446. 'hardwaredescription' => array(
  10447. 'description' => 'TODO: please describe this field!',
  10448. 'type' => 'text',
  10449. 'not null' => FALSE,
  10450. ),
  10451. 'softwaredescription' => array(
  10452. 'description' => 'TODO: please describe this field!',
  10453. 'type' => 'text',
  10454. 'not null' => FALSE,
  10455. ),
  10456. ),
  10457. 'primary key' => array(
  10458. 0 => 'protocol_id',
  10459. ),
  10460. 'unique keys' => array(
  10461. 'protocol_c1' => array(
  10462. 0 => 'name',
  10463. ),
  10464. ),
  10465. 'indexes' => array(
  10466. 'protocol_idx1' => array(
  10467. 0 => 'type_id',
  10468. ),
  10469. 'protocol_idx2' => array(
  10470. 0 => 'pub_id',
  10471. ),
  10472. 'protocol_idx3' => array(
  10473. 0 => 'dbxref_id',
  10474. ),
  10475. ),
  10476. 'foreign keys' => array(
  10477. 'cvterm' => array(
  10478. 'table' => 'cvterm',
  10479. 'columns' => array(
  10480. 'type_id' => 'cvterm_id',
  10481. ),
  10482. ),
  10483. 'dbxref' => array(
  10484. 'table' => 'dbxref',
  10485. 'columns' => array(
  10486. 'dbxref_id' => 'dbxref_id',
  10487. ),
  10488. ),
  10489. 'pub' => array(
  10490. 'table' => 'pub',
  10491. 'columns' => array(
  10492. 'pub_id' => 'pub_id',
  10493. ),
  10494. ),
  10495. ),
  10496. );
  10497. return $description;
  10498. }
  10499. /**
  10500. * Implements hook_chado_schema_v1_2_protocolparam()
  10501. * Purpose: To describe the structure of 'protocolparam' to tripal
  10502. * @see tripal_core_chado_insert()
  10503. * @see tripal_core_chado_update()
  10504. * @see tripal_core_chado_select()
  10505. *
  10506. * @return
  10507. * An array describing the 'protocolparam' table
  10508. *
  10509. * @ingroup tripal_chado_v1.2_schema_api
  10510. *
  10511. */
  10512. function tripal_core_chado_schema_v1_2_protocolparam() {
  10513. $description = array(
  10514. 'description' => 'TODO: please describe this table!',
  10515. 'fields' => array(
  10516. 'protocolparam_id' => array(
  10517. 'description' => 'TODO: please describe this field!',
  10518. 'type' => 'serial',
  10519. 'not null' => TRUE,
  10520. ),
  10521. 'protocol_id' => array(
  10522. 'description' => 'TODO: please describe this field!',
  10523. 'type' => 'int',
  10524. 'not null' => TRUE,
  10525. ),
  10526. 'name' => array(
  10527. 'description' => 'TODO: please describe this field!',
  10528. 'type' => 'text',
  10529. 'not null' => TRUE,
  10530. ),
  10531. 'datatype_id' => array(
  10532. 'description' => 'TODO: please describe this field!',
  10533. 'type' => 'int',
  10534. 'not null' => FALSE,
  10535. ),
  10536. 'unittype_id' => array(
  10537. 'description' => 'TODO: please describe this field!',
  10538. 'type' => 'int',
  10539. 'not null' => FALSE,
  10540. ),
  10541. 'value' => array(
  10542. 'description' => 'TODO: please describe this field!',
  10543. 'type' => 'text',
  10544. 'not null' => FALSE,
  10545. ),
  10546. 'rank' => array(
  10547. 'description' => 'TODO: please describe this field!',
  10548. 'type' => 'int',
  10549. 'not null' => TRUE,
  10550. 'default' => 0,
  10551. ),
  10552. ),
  10553. 'primary key' => array(
  10554. 0 => 'protocolparam_id',
  10555. ),
  10556. 'indexes' => array(
  10557. 'protocolparam_idx1' => array(
  10558. 0 => 'protocol_id',
  10559. ),
  10560. 'protocolparam_idx2' => array(
  10561. 0 => 'datatype_id',
  10562. ),
  10563. 'protocolparam_idx3' => array(
  10564. 0 => 'unittype_id',
  10565. ),
  10566. ),
  10567. 'foreign keys' => array(
  10568. 'cvterm' => array(
  10569. 'table' => 'cvterm',
  10570. 'columns' => array(
  10571. 'datatype_id' => 'cvterm_id',
  10572. 'unittype_id' => 'cvterm_id',
  10573. ),
  10574. ),
  10575. 'protocol' => array(
  10576. 'table' => 'protocol',
  10577. 'columns' => array(
  10578. 'protocol_id' => 'protocol_id',
  10579. ),
  10580. ),
  10581. ),
  10582. );
  10583. return $description;
  10584. }
  10585. /**
  10586. * Implements hook_chado_schema_v1_2_pub()
  10587. * Purpose: To describe the structure of 'pub' to tripal
  10588. * @see tripal_core_chado_insert()
  10589. * @see tripal_core_chado_update()
  10590. * @see tripal_core_chado_select()
  10591. *
  10592. * @return
  10593. * An array describing the 'pub' table
  10594. *
  10595. * @ingroup tripal_chado_v1.2_schema_api
  10596. *
  10597. */
  10598. function tripal_core_chado_schema_v1_2_pub() {
  10599. $description = array(
  10600. 'description' => 'TODO: please describe this table!',
  10601. 'fields' => array(
  10602. 'pub_id' => array(
  10603. 'description' => 'TODO: please describe this field!',
  10604. 'type' => 'serial',
  10605. 'not null' => TRUE,
  10606. ),
  10607. 'title' => array(
  10608. 'description' => 'TODO: please describe this field!',
  10609. 'type' => 'text',
  10610. 'not null' => FALSE,
  10611. ),
  10612. 'volumetitle' => array(
  10613. 'description' => 'TODO: please describe this field!',
  10614. 'type' => 'text',
  10615. 'not null' => FALSE,
  10616. ),
  10617. 'volume' => array(
  10618. 'description' => 'TODO: please describe this field!',
  10619. 'type' => 'varchar',
  10620. 'length' => '255',
  10621. 'not null' => FALSE,
  10622. ),
  10623. 'series_name' => array(
  10624. 'description' => 'TODO: please describe this field!',
  10625. 'type' => 'varchar',
  10626. 'length' => '255',
  10627. 'not null' => FALSE,
  10628. ),
  10629. 'issue' => array(
  10630. 'description' => 'TODO: please describe this field!',
  10631. 'type' => 'varchar',
  10632. 'length' => '255',
  10633. 'not null' => FALSE,
  10634. ),
  10635. 'pyear' => array(
  10636. 'description' => 'TODO: please describe this field!',
  10637. 'type' => 'varchar',
  10638. 'length' => '255',
  10639. 'not null' => FALSE,
  10640. ),
  10641. 'pages' => array(
  10642. 'description' => 'TODO: please describe this field!',
  10643. 'type' => 'varchar',
  10644. 'length' => '255',
  10645. 'not null' => FALSE,
  10646. ),
  10647. 'miniref' => array(
  10648. 'description' => 'TODO: please describe this field!',
  10649. 'type' => 'varchar',
  10650. 'length' => '255',
  10651. 'not null' => FALSE,
  10652. ),
  10653. 'uniquename' => array(
  10654. 'description' => 'TODO: please describe this field!',
  10655. 'type' => 'text',
  10656. 'not null' => TRUE,
  10657. ),
  10658. 'type_id' => array(
  10659. 'description' => 'TODO: please describe this field!',
  10660. 'type' => 'int',
  10661. 'not null' => TRUE,
  10662. ),
  10663. 'is_obsolete' => array(
  10664. 'description' => 'TODO: please describe this field!',
  10665. 'type' => 'boolean',
  10666. 'not null' => FALSE,
  10667. 'default' => 'als',
  10668. ),
  10669. 'publisher' => array(
  10670. 'description' => 'TODO: please describe this field!',
  10671. 'type' => 'varchar',
  10672. 'length' => '255',
  10673. 'not null' => FALSE,
  10674. ),
  10675. 'pubplace' => array(
  10676. 'description' => 'TODO: please describe this field!',
  10677. 'type' => 'varchar',
  10678. 'length' => '255',
  10679. 'not null' => FALSE,
  10680. ),
  10681. ),
  10682. 'primary key' => array(
  10683. 0 => 'pub_id',
  10684. ),
  10685. 'unique keys' => array(
  10686. 'pub_c1' => array(
  10687. 0 => 'uniquename',
  10688. ),
  10689. ),
  10690. 'indexes' => array(
  10691. 'pub_idx1' => array(
  10692. 0 => 'type_id',
  10693. ),
  10694. ),
  10695. 'foreign keys' => array(
  10696. 'cvterm' => array(
  10697. 'table' => 'cvterm',
  10698. 'columns' => array(
  10699. 'type_id' => 'cvterm_id',
  10700. ),
  10701. ),
  10702. ),
  10703. );
  10704. return $description;
  10705. }
  10706. /**
  10707. * Implements hook_chado_schema_v1_2_pub_dbxref()
  10708. * Purpose: To describe the structure of 'pub_dbxref' to tripal
  10709. * @see tripal_core_chado_insert()
  10710. * @see tripal_core_chado_update()
  10711. * @see tripal_core_chado_select()
  10712. *
  10713. * @return
  10714. * An array describing the 'pub_dbxref' table
  10715. *
  10716. * @ingroup tripal_chado_v1.2_schema_api
  10717. *
  10718. */
  10719. function tripal_core_chado_schema_v1_2_pub_dbxref() {
  10720. $description = array(
  10721. 'description' => 'TODO: please describe this table!',
  10722. 'fields' => array(
  10723. 'pub_dbxref_id' => array(
  10724. 'description' => 'TODO: please describe this field!',
  10725. 'type' => 'serial',
  10726. 'not null' => TRUE,
  10727. ),
  10728. 'pub_id' => array(
  10729. 'description' => 'TODO: please describe this field!',
  10730. 'type' => 'int',
  10731. 'not null' => TRUE,
  10732. ),
  10733. 'dbxref_id' => array(
  10734. 'description' => 'TODO: please describe this field!',
  10735. 'type' => 'int',
  10736. 'not null' => TRUE,
  10737. ),
  10738. 'is_current' => array(
  10739. 'description' => 'TODO: please describe this field!',
  10740. 'type' => 'boolean',
  10741. 'not null' => TRUE,
  10742. 'default' => 'ru',
  10743. ),
  10744. ),
  10745. 'primary key' => array(
  10746. 0 => 'pub_dbxref_id',
  10747. ),
  10748. 'unique keys' => array(
  10749. 'pub_dbxref_c1' => array(
  10750. 0 => 'pub_id',
  10751. 1 => 'dbxref_id',
  10752. ),
  10753. ),
  10754. 'indexes' => array(
  10755. 'pub_dbxref_idx1' => array(
  10756. 0 => 'pub_id',
  10757. ),
  10758. 'pub_dbxref_idx2' => array(
  10759. 0 => 'dbxref_id',
  10760. ),
  10761. ),
  10762. 'foreign keys' => array(
  10763. 'dbxref' => array(
  10764. 'table' => 'dbxref',
  10765. 'columns' => array(
  10766. 'dbxref_id' => 'dbxref_id',
  10767. ),
  10768. ),
  10769. 'pub' => array(
  10770. 'table' => 'pub',
  10771. 'columns' => array(
  10772. 'pub_id' => 'pub_id',
  10773. ),
  10774. ),
  10775. ),
  10776. );
  10777. return $description;
  10778. }
  10779. /**
  10780. * Implements hook_chado_schema_v1_2_pub_relationship()
  10781. * Purpose: To describe the structure of 'pub_relationship' to tripal
  10782. * @see tripal_core_chado_insert()
  10783. * @see tripal_core_chado_update()
  10784. * @see tripal_core_chado_select()
  10785. *
  10786. * @return
  10787. * An array describing the 'pub_relationship' table
  10788. *
  10789. * @ingroup tripal_chado_v1.2_schema_api
  10790. *
  10791. */
  10792. function tripal_core_chado_schema_v1_2_pub_relationship() {
  10793. $description = array(
  10794. 'description' => 'TODO: please describe this table!',
  10795. 'fields' => array(
  10796. 'pub_relationship_id' => array(
  10797. 'description' => 'TODO: please describe this field!',
  10798. 'type' => 'serial',
  10799. 'not null' => TRUE,
  10800. ),
  10801. 'subject_id' => array(
  10802. 'description' => 'TODO: please describe this field!',
  10803. 'type' => 'int',
  10804. 'not null' => TRUE,
  10805. ),
  10806. 'object_id' => array(
  10807. 'description' => 'TODO: please describe this field!',
  10808. 'type' => 'int',
  10809. 'not null' => TRUE,
  10810. ),
  10811. 'type_id' => array(
  10812. 'description' => 'TODO: please describe this field!',
  10813. 'type' => 'int',
  10814. 'not null' => TRUE,
  10815. ),
  10816. ),
  10817. 'primary key' => array(
  10818. 0 => 'pub_relationship_id',
  10819. ),
  10820. 'unique keys' => array(
  10821. 'pub_relationship_c1' => array(
  10822. 0 => 'subject_id',
  10823. 1 => 'object_id',
  10824. 2 => 'type_id',
  10825. ),
  10826. ),
  10827. 'indexes' => array(
  10828. 'pub_relationship_idx1' => array(
  10829. 0 => 'subject_id',
  10830. ),
  10831. 'pub_relationship_idx2' => array(
  10832. 0 => 'object_id',
  10833. ),
  10834. 'pub_relationship_idx3' => array(
  10835. 0 => 'type_id',
  10836. ),
  10837. ),
  10838. 'foreign keys' => array(
  10839. 'cvterm' => array(
  10840. 'table' => 'cvterm',
  10841. 'columns' => array(
  10842. 'type_id' => 'cvterm_id',
  10843. ),
  10844. ),
  10845. 'pub' => array(
  10846. 'table' => 'pub',
  10847. 'columns' => array(
  10848. 'subject_id' => 'pub_id',
  10849. 'object_id' => 'pub_id',
  10850. ),
  10851. ),
  10852. ),
  10853. );
  10854. return $description;
  10855. }
  10856. /**
  10857. * Implements hook_chado_schema_v1_2_pubauthor()
  10858. * Purpose: To describe the structure of 'pubauthor' to tripal
  10859. * @see tripal_core_chado_insert()
  10860. * @see tripal_core_chado_update()
  10861. * @see tripal_core_chado_select()
  10862. *
  10863. * @return
  10864. * An array describing the 'pubauthor' table
  10865. *
  10866. * @ingroup tripal_chado_v1.2_schema_api
  10867. *
  10868. */
  10869. function tripal_core_chado_schema_v1_2_pubauthor() {
  10870. $description = array(
  10871. 'description' => 'TODO: please describe this table!',
  10872. 'fields' => array(
  10873. 'pubauthor_id' => array(
  10874. 'description' => 'TODO: please describe this field!',
  10875. 'type' => 'serial',
  10876. 'not null' => TRUE,
  10877. ),
  10878. 'pub_id' => array(
  10879. 'description' => 'TODO: please describe this field!',
  10880. 'type' => 'int',
  10881. 'not null' => TRUE,
  10882. ),
  10883. 'rank' => array(
  10884. 'description' => 'TODO: please describe this field!',
  10885. 'type' => 'int',
  10886. 'not null' => TRUE,
  10887. ),
  10888. 'editor' => array(
  10889. 'description' => 'TODO: please describe this field!',
  10890. 'type' => 'boolean',
  10891. 'not null' => FALSE,
  10892. 'default' => 'als',
  10893. ),
  10894. 'surname' => array(
  10895. 'description' => 'TODO: please describe this field!',
  10896. 'type' => 'varchar',
  10897. 'length' => '100',
  10898. 'not null' => TRUE,
  10899. ),
  10900. 'givennames' => array(
  10901. 'description' => 'TODO: please describe this field!',
  10902. 'type' => 'varchar',
  10903. 'length' => '100',
  10904. 'not null' => FALSE,
  10905. ),
  10906. 'suffix' => array(
  10907. 'description' => 'TODO: please describe this field!',
  10908. 'type' => 'varchar',
  10909. 'length' => '100',
  10910. 'not null' => FALSE,
  10911. ),
  10912. ),
  10913. 'primary key' => array(
  10914. 0 => 'pubauthor_id',
  10915. ),
  10916. 'unique keys' => array(
  10917. 'pubauthor_c1' => array(
  10918. 0 => 'pub_id',
  10919. 1 => 'rank',
  10920. ),
  10921. ),
  10922. 'indexes' => array(
  10923. 'pubauthor_idx2' => array(
  10924. 0 => 'pub_id',
  10925. ),
  10926. ),
  10927. 'foreign keys' => array(
  10928. 'pub' => array(
  10929. 'table' => 'pub',
  10930. 'columns' => array(
  10931. 'pub_id' => 'pub_id',
  10932. ),
  10933. ),
  10934. ),
  10935. );
  10936. return $description;
  10937. }
  10938. /**
  10939. * Implements hook_chado_schema_v1_2_pubprop()
  10940. * Purpose: To describe the structure of 'pubprop' to tripal
  10941. * @see tripal_core_chado_insert()
  10942. * @see tripal_core_chado_update()
  10943. * @see tripal_core_chado_select()
  10944. *
  10945. * @return
  10946. * An array describing the 'pubprop' table
  10947. *
  10948. * @ingroup tripal_chado_v1.2_schema_api
  10949. *
  10950. */
  10951. function tripal_core_chado_schema_v1_2_pubprop() {
  10952. $description = array(
  10953. 'description' => 'TODO: please describe this table!',
  10954. 'fields' => array(
  10955. 'pubprop_id' => array(
  10956. 'description' => 'TODO: please describe this field!',
  10957. 'type' => 'serial',
  10958. 'not null' => TRUE,
  10959. ),
  10960. 'pub_id' => array(
  10961. 'description' => 'TODO: please describe this field!',
  10962. 'type' => 'int',
  10963. 'not null' => TRUE,
  10964. ),
  10965. 'type_id' => array(
  10966. 'description' => 'TODO: please describe this field!',
  10967. 'type' => 'int',
  10968. 'not null' => TRUE,
  10969. ),
  10970. 'value' => array(
  10971. 'description' => 'TODO: please describe this field!',
  10972. 'type' => 'text',
  10973. 'not null' => TRUE,
  10974. ),
  10975. 'rank' => array(
  10976. 'description' => 'TODO: please describe this field!',
  10977. 'type' => 'int',
  10978. 'not null' => FALSE,
  10979. ),
  10980. ),
  10981. 'primary key' => array(
  10982. 0 => 'pubprop_id',
  10983. ),
  10984. 'unique keys' => array(
  10985. 'pubprop_c1' => array(
  10986. 0 => 'pub_id',
  10987. 1 => 'type_id',
  10988. 2 => 'rank',
  10989. ),
  10990. ),
  10991. 'indexes' => array(
  10992. 'pubprop_idx1' => array(
  10993. 0 => 'pub_id',
  10994. ),
  10995. 'pubprop_idx2' => array(
  10996. 0 => 'type_id',
  10997. ),
  10998. ),
  10999. 'foreign keys' => array(
  11000. 'cvterm' => array(
  11001. 'table' => 'cvterm',
  11002. 'columns' => array(
  11003. 'type_id' => 'cvterm_id',
  11004. ),
  11005. ),
  11006. 'pub' => array(
  11007. 'table' => 'pub',
  11008. 'columns' => array(
  11009. 'pub_id' => 'pub_id',
  11010. ),
  11011. ),
  11012. ),
  11013. );
  11014. return $description;
  11015. }
  11016. /**
  11017. * Implements hook_chado_schema_v1_2_quantification()
  11018. * Purpose: To describe the structure of 'quantification' to tripal
  11019. * @see tripal_core_chado_insert()
  11020. * @see tripal_core_chado_update()
  11021. * @see tripal_core_chado_select()
  11022. *
  11023. * @return
  11024. * An array describing the 'quantification' table
  11025. *
  11026. * @ingroup tripal_chado_v1.2_schema_api
  11027. *
  11028. */
  11029. function tripal_core_chado_schema_v1_2_quantification() {
  11030. $description = array(
  11031. 'description' => 'TODO: please describe this table!',
  11032. 'fields' => array(
  11033. 'quantification_id' => array(
  11034. 'description' => 'TODO: please describe this field!',
  11035. 'type' => 'serial',
  11036. 'not null' => TRUE,
  11037. ),
  11038. 'acquisition_id' => array(
  11039. 'description' => 'TODO: please describe this field!',
  11040. 'type' => 'int',
  11041. 'not null' => TRUE,
  11042. ),
  11043. 'operator_id' => array(
  11044. 'description' => 'TODO: please describe this field!',
  11045. 'type' => 'int',
  11046. 'not null' => FALSE,
  11047. ),
  11048. 'protocol_id' => array(
  11049. 'description' => 'TODO: please describe this field!',
  11050. 'type' => 'int',
  11051. 'not null' => FALSE,
  11052. ),
  11053. 'analysis_id' => array(
  11054. 'description' => 'TODO: please describe this field!',
  11055. 'type' => 'int',
  11056. 'not null' => TRUE,
  11057. ),
  11058. 'quantificationdate' => array(
  11059. 'description' => 'TODO: please describe this field!',
  11060. 'type' => 'datetime',
  11061. 'not null' => FALSE,
  11062. 'default' => 'ow(',
  11063. ),
  11064. 'name' => array(
  11065. 'description' => 'TODO: please describe this field!',
  11066. 'type' => 'text',
  11067. 'not null' => FALSE,
  11068. ),
  11069. 'uri' => array(
  11070. 'description' => 'TODO: please describe this field!',
  11071. 'type' => 'text',
  11072. 'not null' => FALSE,
  11073. ),
  11074. ),
  11075. 'primary key' => array(
  11076. 0 => 'quantification_id',
  11077. ),
  11078. 'unique keys' => array(
  11079. 'quantification_c1' => array(
  11080. 0 => 'name',
  11081. 1 => 'analysis_id',
  11082. ),
  11083. ),
  11084. 'indexes' => array(
  11085. 'quantification_idx1' => array(
  11086. 0 => 'acquisition_id',
  11087. ),
  11088. 'quantification_idx2' => array(
  11089. 0 => 'operator_id',
  11090. ),
  11091. 'quantification_idx3' => array(
  11092. 0 => 'protocol_id',
  11093. ),
  11094. 'quantification_idx4' => array(
  11095. 0 => 'analysis_id',
  11096. ),
  11097. ),
  11098. 'foreign keys' => array(
  11099. 'analysis' => array(
  11100. 'table' => 'analysis',
  11101. 'columns' => array(
  11102. 'analysis_id' => 'analysis_id',
  11103. ),
  11104. ),
  11105. 'contact' => array(
  11106. 'table' => 'contact',
  11107. 'columns' => array(
  11108. 'operator_id' => 'contact_id',
  11109. ),
  11110. ),
  11111. 'protocol' => array(
  11112. 'table' => 'protocol',
  11113. 'columns' => array(
  11114. 'protocol_id' => 'protocol_id',
  11115. ),
  11116. ),
  11117. 'acquisition' => array(
  11118. 'table' => 'acquisition',
  11119. 'columns' => array(
  11120. 'acquisition_id' => 'acquisition_id',
  11121. ),
  11122. ),
  11123. ),
  11124. );
  11125. return $description;
  11126. }
  11127. /**
  11128. * Implements hook_chado_schema_v1_2_quantification_relationship()
  11129. * Purpose: To describe the structure of 'quantification_relationship' to tripal
  11130. * @see tripal_core_chado_insert()
  11131. * @see tripal_core_chado_update()
  11132. * @see tripal_core_chado_select()
  11133. *
  11134. * @return
  11135. * An array describing the 'quantification_relationship' table
  11136. *
  11137. * @ingroup tripal_chado_v1.2_schema_api
  11138. *
  11139. */
  11140. function tripal_core_chado_schema_v1_2_quantification_relationship() {
  11141. $description = array(
  11142. 'description' => 'TODO: please describe this table!',
  11143. 'fields' => array(
  11144. 'quantification_relationship_id' => array(
  11145. 'description' => 'TODO: please describe this field!',
  11146. 'type' => 'serial',
  11147. 'not null' => TRUE,
  11148. ),
  11149. 'subject_id' => array(
  11150. 'description' => 'TODO: please describe this field!',
  11151. 'type' => 'int',
  11152. 'not null' => TRUE,
  11153. ),
  11154. 'type_id' => array(
  11155. 'description' => 'TODO: please describe this field!',
  11156. 'type' => 'int',
  11157. 'not null' => TRUE,
  11158. ),
  11159. 'object_id' => array(
  11160. 'description' => 'TODO: please describe this field!',
  11161. 'type' => 'int',
  11162. 'not null' => TRUE,
  11163. ),
  11164. ),
  11165. 'primary key' => array(
  11166. 0 => 'quantification_relationship_id',
  11167. ),
  11168. 'unique keys' => array(
  11169. 'quantification_relationship_c1' => array(
  11170. 0 => 'subject_id',
  11171. 1 => 'object_id',
  11172. 2 => 'type_id',
  11173. ),
  11174. ),
  11175. 'indexes' => array(
  11176. 'quantification_relationship_idx1' => array(
  11177. 0 => 'subject_id',
  11178. ),
  11179. 'quantification_relationship_idx2' => array(
  11180. 0 => 'type_id',
  11181. ),
  11182. 'quantification_relationship_idx3' => array(
  11183. 0 => 'object_id',
  11184. ),
  11185. ),
  11186. 'foreign keys' => array(
  11187. 'cvterm' => array(
  11188. 'table' => 'cvterm',
  11189. 'columns' => array(
  11190. 'type_id' => 'cvterm_id',
  11191. ),
  11192. ),
  11193. 'quantification' => array(
  11194. 'table' => 'quantification',
  11195. 'columns' => array(
  11196. 'subject_id' => 'quantification_id',
  11197. 'object_id' => 'quantification_id',
  11198. ),
  11199. ),
  11200. ),
  11201. );
  11202. return $description;
  11203. }
  11204. /**
  11205. * Implements hook_chado_schema_v1_2_quantificationprop()
  11206. * Purpose: To describe the structure of 'quantificationprop' to tripal
  11207. * @see tripal_core_chado_insert()
  11208. * @see tripal_core_chado_update()
  11209. * @see tripal_core_chado_select()
  11210. *
  11211. * @return
  11212. * An array describing the 'quantificationprop' table
  11213. *
  11214. * @ingroup tripal_chado_v1.2_schema_api
  11215. *
  11216. */
  11217. function tripal_core_chado_schema_v1_2_quantificationprop() {
  11218. $description = array(
  11219. 'description' => 'TODO: please describe this table!',
  11220. 'fields' => array(
  11221. 'quantificationprop_id' => array(
  11222. 'description' => 'TODO: please describe this field!',
  11223. 'type' => 'serial',
  11224. 'not null' => TRUE,
  11225. ),
  11226. 'quantification_id' => array(
  11227. 'description' => 'TODO: please describe this field!',
  11228. 'type' => 'int',
  11229. 'not null' => TRUE,
  11230. ),
  11231. 'type_id' => array(
  11232. 'description' => 'TODO: please describe this field!',
  11233. 'type' => 'int',
  11234. 'not null' => TRUE,
  11235. ),
  11236. 'value' => array(
  11237. 'description' => 'TODO: please describe this field!',
  11238. 'type' => 'text',
  11239. 'not null' => FALSE,
  11240. ),
  11241. 'rank' => array(
  11242. 'description' => 'TODO: please describe this field!',
  11243. 'type' => 'int',
  11244. 'not null' => TRUE,
  11245. 'default' => 0,
  11246. ),
  11247. ),
  11248. 'primary key' => array(
  11249. 0 => 'quantificationprop_id',
  11250. ),
  11251. 'unique keys' => array(
  11252. 'quantificationprop_c1' => array(
  11253. 0 => 'quantification_id',
  11254. 1 => 'type_id',
  11255. 2 => 'rank',
  11256. ),
  11257. ),
  11258. 'indexes' => array(
  11259. 'quantificationprop_idx1' => array(
  11260. 0 => 'quantification_id',
  11261. ),
  11262. 'quantificationprop_idx2' => array(
  11263. 0 => 'type_id',
  11264. ),
  11265. ),
  11266. 'foreign keys' => array(
  11267. 'cvterm' => array(
  11268. 'table' => 'cvterm',
  11269. 'columns' => array(
  11270. 'type_id' => 'cvterm_id',
  11271. ),
  11272. ),
  11273. 'quantification' => array(
  11274. 'table' => 'quantification',
  11275. 'columns' => array(
  11276. 'quantification_id' => 'quantification_id',
  11277. ),
  11278. ),
  11279. ),
  11280. );
  11281. return $description;
  11282. }
  11283. /**
  11284. * Implements hook_chado_schema_v1_2_stock()
  11285. * Purpose: To describe the structure of 'stock' to tripal
  11286. * @see tripal_core_chado_insert()
  11287. * @see tripal_core_chado_update()
  11288. * @see tripal_core_chado_select()
  11289. *
  11290. * @return
  11291. * An array describing the 'stock' table
  11292. *
  11293. * @ingroup tripal_chado_v1.2_schema_api
  11294. *
  11295. */
  11296. function tripal_core_chado_schema_v1_2_stock() {
  11297. $description = array(
  11298. 'description' => 'TODO: please describe this table!',
  11299. 'fields' => array(
  11300. 'stock_id' => array(
  11301. 'description' => 'TODO: please describe this field!',
  11302. 'type' => 'serial',
  11303. 'not null' => TRUE,
  11304. ),
  11305. 'dbxref_id' => array(
  11306. 'description' => 'TODO: please describe this field!',
  11307. 'type' => 'int',
  11308. 'not null' => FALSE,
  11309. ),
  11310. 'organism_id' => array(
  11311. 'description' => 'TODO: please describe this field!',
  11312. 'type' => 'int',
  11313. 'not null' => FALSE,
  11314. ),
  11315. 'name' => array(
  11316. 'description' => 'TODO: please describe this field!',
  11317. 'type' => 'varchar',
  11318. 'length' => '255',
  11319. 'not null' => FALSE,
  11320. ),
  11321. 'uniquename' => array(
  11322. 'description' => 'TODO: please describe this field!',
  11323. 'type' => 'text',
  11324. 'not null' => TRUE,
  11325. ),
  11326. 'description' => array(
  11327. 'description' => 'TODO: please describe this field!',
  11328. 'type' => 'text',
  11329. 'not null' => FALSE,
  11330. ),
  11331. 'type_id' => array(
  11332. 'description' => 'TODO: please describe this field!',
  11333. 'type' => 'int',
  11334. 'not null' => TRUE,
  11335. ),
  11336. 'is_obsolete' => array(
  11337. 'description' => 'TODO: please describe this field!',
  11338. 'type' => 'boolean',
  11339. 'not null' => TRUE,
  11340. 'default' => 'als',
  11341. ),
  11342. ),
  11343. 'primary key' => array(
  11344. 0 => 'stock_id',
  11345. ),
  11346. 'unique keys' => array(
  11347. 'stock_c1' => array(
  11348. 0 => 'organism_id',
  11349. 1 => 'uniquename',
  11350. 2 => 'type_id',
  11351. ),
  11352. ),
  11353. 'indexes' => array(
  11354. 'stock_idx1' => array(
  11355. 0 => 'dbxref_id',
  11356. ),
  11357. 'stock_idx2' => array(
  11358. 0 => 'organism_id',
  11359. ),
  11360. 'stock_idx3' => array(
  11361. 0 => 'type_id',
  11362. ),
  11363. 'stock_idx4' => array(
  11364. 0 => 'uniquename',
  11365. ),
  11366. 'stock_name_ind1' => array(
  11367. 0 => 'name',
  11368. ),
  11369. ),
  11370. 'foreign keys' => array(
  11371. 'organism' => array(
  11372. 'table' => 'organism',
  11373. 'columns' => array(
  11374. 'organism_id' => 'organism_id',
  11375. ),
  11376. ),
  11377. 'cvterm' => array(
  11378. 'table' => 'cvterm',
  11379. 'columns' => array(
  11380. 'type_id' => 'cvterm_id',
  11381. ),
  11382. ),
  11383. 'dbxref' => array(
  11384. 'table' => 'dbxref',
  11385. 'columns' => array(
  11386. 'dbxref_id' => 'dbxref_id',
  11387. ),
  11388. ),
  11389. ),
  11390. );
  11391. return $description;
  11392. }
  11393. /**
  11394. * Implements hook_chado_schema_v1_2_stock_cvterm()
  11395. * Purpose: To describe the structure of 'stock_cvterm' to tripal
  11396. * @see tripal_core_chado_insert()
  11397. * @see tripal_core_chado_update()
  11398. * @see tripal_core_chado_select()
  11399. *
  11400. * @return
  11401. * An array describing the 'stock_cvterm' table
  11402. *
  11403. * @ingroup tripal_chado_v1.2_schema_api
  11404. *
  11405. */
  11406. function tripal_core_chado_schema_v1_2_stock_cvterm() {
  11407. $description = array(
  11408. 'description' => 'TODO: please describe this table!',
  11409. 'fields' => array(
  11410. 'stock_cvterm_id' => array(
  11411. 'description' => 'TODO: please describe this field!',
  11412. 'type' => 'serial',
  11413. 'not null' => TRUE,
  11414. ),
  11415. 'stock_id' => array(
  11416. 'description' => 'TODO: please describe this field!',
  11417. 'type' => 'int',
  11418. 'not null' => TRUE,
  11419. ),
  11420. 'cvterm_id' => array(
  11421. 'description' => 'TODO: please describe this field!',
  11422. 'type' => 'int',
  11423. 'not null' => TRUE,
  11424. ),
  11425. 'pub_id' => array(
  11426. 'description' => 'TODO: please describe this field!',
  11427. 'type' => 'int',
  11428. 'not null' => TRUE,
  11429. ),
  11430. 'is_not' => array(
  11431. 'description' => 'TODO: please describe this field!',
  11432. 'type' => 'boolean',
  11433. 'not null' => TRUE,
  11434. 'default' => 'als',
  11435. ),
  11436. 'rank' => array(
  11437. 'description' => 'TODO: please describe this field!',
  11438. 'type' => 'int',
  11439. 'not null' => TRUE,
  11440. 'default' => 0,
  11441. ),
  11442. ),
  11443. 'primary key' => array(
  11444. 0 => 'stock_cvterm_id',
  11445. ),
  11446. 'unique keys' => array(
  11447. 'stock_cvterm_c1' => array(
  11448. 0 => 'stock_id',
  11449. 1 => 'cvterm_id',
  11450. 2 => 'pub_id',
  11451. 3 => 'rank',
  11452. ),
  11453. ),
  11454. 'indexes' => array(
  11455. 'stock_cvterm_idx1' => array(
  11456. 0 => 'stock_id',
  11457. ),
  11458. 'stock_cvterm_idx2' => array(
  11459. 0 => 'cvterm_id',
  11460. ),
  11461. 'stock_cvterm_idx3' => array(
  11462. 0 => 'pub_id',
  11463. ),
  11464. ),
  11465. 'foreign keys' => array(
  11466. 'cvterm' => array(
  11467. 'table' => 'cvterm',
  11468. 'columns' => array(
  11469. 'cvterm_id' => 'cvterm_id',
  11470. ),
  11471. ),
  11472. 'pub' => array(
  11473. 'table' => 'pub',
  11474. 'columns' => array(
  11475. 'pub_id' => 'pub_id',
  11476. ),
  11477. ),
  11478. 'stock' => array(
  11479. 'table' => 'stock',
  11480. 'columns' => array(
  11481. 'stock_id' => 'stock_id',
  11482. ),
  11483. ),
  11484. ),
  11485. );
  11486. return $description;
  11487. }
  11488. /**
  11489. * Implements hook_chado_schema_v1_2_stock_cvtermprop()
  11490. * Purpose: To describe the structure of 'stock_cvtermprop' to tripal
  11491. * @see tripal_core_chado_insert()
  11492. * @see tripal_core_chado_update()
  11493. * @see tripal_core_chado_select()
  11494. *
  11495. * @return
  11496. * An array describing the 'stock_cvtermprop' table
  11497. *
  11498. * @ingroup tripal_chado_v1.2_schema_api
  11499. *
  11500. */
  11501. function tripal_core_chado_schema_v1_2_stock_cvtermprop() {
  11502. $description = array(
  11503. 'description' => 'TODO: please describe this table!',
  11504. 'fields' => array(
  11505. 'stock_cvtermprop_id' => array(
  11506. 'description' => 'TODO: please describe this field!',
  11507. 'type' => 'serial',
  11508. 'not null' => TRUE,
  11509. ),
  11510. 'stock_cvterm_id' => array(
  11511. 'description' => 'TODO: please describe this field!',
  11512. 'type' => 'int',
  11513. 'not null' => TRUE,
  11514. ),
  11515. 'type_id' => array(
  11516. 'description' => 'TODO: please describe this field!',
  11517. 'type' => 'int',
  11518. 'not null' => TRUE,
  11519. ),
  11520. 'value' => array(
  11521. 'description' => 'TODO: please describe this field!',
  11522. 'type' => 'text',
  11523. 'not null' => FALSE,
  11524. ),
  11525. 'rank' => array(
  11526. 'description' => 'TODO: please describe this field!',
  11527. 'type' => 'int',
  11528. 'not null' => TRUE,
  11529. 'default' => 0,
  11530. ),
  11531. ),
  11532. 'primary key' => array(
  11533. 0 => 'stock_cvtermprop_id',
  11534. ),
  11535. 'unique keys' => array(
  11536. 'stock_cvtermprop_c1' => array(
  11537. 0 => 'stock_cvterm_id',
  11538. 1 => 'type_id',
  11539. 2 => 'rank',
  11540. ),
  11541. ),
  11542. 'indexes' => array(
  11543. 'stock_cvtermprop_idx1' => array(
  11544. 0 => 'stock_cvterm_id',
  11545. ),
  11546. 'stock_cvtermprop_idx2' => array(
  11547. 0 => 'type_id',
  11548. ),
  11549. ),
  11550. 'foreign keys' => array(
  11551. 'cvterm' => array(
  11552. 'table' => 'cvterm',
  11553. 'columns' => array(
  11554. 'type_id' => 'cvterm_id',
  11555. ),
  11556. ),
  11557. 'stock_cvterm' => array(
  11558. 'table' => 'stock_cvterm',
  11559. 'columns' => array(
  11560. 'stock_cvterm_id' => 'stock_cvterm_id',
  11561. ),
  11562. ),
  11563. ),
  11564. );
  11565. return $description;
  11566. }
  11567. /**
  11568. * Implements hook_chado_schema_v1_2_stock_dbxref()
  11569. * Purpose: To describe the structure of 'stock_dbxref' to tripal
  11570. * @see tripal_core_chado_insert()
  11571. * @see tripal_core_chado_update()
  11572. * @see tripal_core_chado_select()
  11573. *
  11574. * @return
  11575. * An array describing the 'stock_dbxref' table
  11576. *
  11577. * @ingroup tripal_chado_v1.2_schema_api
  11578. *
  11579. */
  11580. function tripal_core_chado_schema_v1_2_stock_dbxref() {
  11581. $description = array(
  11582. 'description' => 'TODO: please describe this table!',
  11583. 'fields' => array(
  11584. 'stock_dbxref_id' => array(
  11585. 'description' => 'TODO: please describe this field!',
  11586. 'type' => 'serial',
  11587. 'not null' => TRUE,
  11588. ),
  11589. 'stock_id' => array(
  11590. 'description' => 'TODO: please describe this field!',
  11591. 'type' => 'int',
  11592. 'not null' => TRUE,
  11593. ),
  11594. 'dbxref_id' => array(
  11595. 'description' => 'TODO: please describe this field!',
  11596. 'type' => 'int',
  11597. 'not null' => TRUE,
  11598. ),
  11599. 'is_current' => array(
  11600. 'description' => 'TODO: please describe this field!',
  11601. 'type' => 'boolean',
  11602. 'not null' => TRUE,
  11603. 'default' => 'ru',
  11604. ),
  11605. ),
  11606. 'primary key' => array(
  11607. 0 => 'stock_dbxref_id',
  11608. ),
  11609. 'unique keys' => array(
  11610. 'stock_dbxref_c1' => array(
  11611. 0 => 'stock_id',
  11612. 1 => 'dbxref_id',
  11613. ),
  11614. ),
  11615. 'indexes' => array(
  11616. 'stock_dbxref_idx1' => array(
  11617. 0 => 'stock_id',
  11618. ),
  11619. 'stock_dbxref_idx2' => array(
  11620. 0 => 'dbxref_id',
  11621. ),
  11622. ),
  11623. 'foreign keys' => array(
  11624. 'dbxref' => array(
  11625. 'table' => 'dbxref',
  11626. 'columns' => array(
  11627. 'dbxref_id' => 'dbxref_id',
  11628. ),
  11629. ),
  11630. 'stock' => array(
  11631. 'table' => 'stock',
  11632. 'columns' => array(
  11633. 'stock_id' => 'stock_id',
  11634. ),
  11635. ),
  11636. ),
  11637. );
  11638. return $description;
  11639. }
  11640. /**
  11641. * Implements hook_chado_schema_v1_2_stock_dbxrefprop()
  11642. * Purpose: To describe the structure of 'stock_dbxrefprop' to tripal
  11643. * @see tripal_core_chado_insert()
  11644. * @see tripal_core_chado_update()
  11645. * @see tripal_core_chado_select()
  11646. *
  11647. * @return
  11648. * An array describing the 'stock_dbxrefprop' table
  11649. *
  11650. * @ingroup tripal_chado_v1.2_schema_api
  11651. *
  11652. */
  11653. function tripal_core_chado_schema_v1_2_stock_dbxrefprop() {
  11654. $description = array(
  11655. 'description' => 'TODO: please describe this table!',
  11656. 'fields' => array(
  11657. 'stock_dbxrefprop_id' => array(
  11658. 'description' => 'TODO: please describe this field!',
  11659. 'type' => 'serial',
  11660. 'not null' => TRUE,
  11661. ),
  11662. 'stock_dbxref_id' => array(
  11663. 'description' => 'TODO: please describe this field!',
  11664. 'type' => 'int',
  11665. 'not null' => TRUE,
  11666. ),
  11667. 'type_id' => array(
  11668. 'description' => 'TODO: please describe this field!',
  11669. 'type' => 'int',
  11670. 'not null' => TRUE,
  11671. ),
  11672. 'value' => array(
  11673. 'description' => 'TODO: please describe this field!',
  11674. 'type' => 'text',
  11675. 'not null' => FALSE,
  11676. ),
  11677. 'rank' => array(
  11678. 'description' => 'TODO: please describe this field!',
  11679. 'type' => 'int',
  11680. 'not null' => TRUE,
  11681. 'default' => 0,
  11682. ),
  11683. ),
  11684. 'primary key' => array(
  11685. 0 => 'stock_dbxrefprop_id',
  11686. ),
  11687. 'unique keys' => array(
  11688. 'stock_dbxrefprop_c1' => array(
  11689. 0 => 'stock_dbxref_id',
  11690. 1 => 'type_id',
  11691. 2 => 'rank',
  11692. ),
  11693. ),
  11694. 'indexes' => array(
  11695. 'stock_dbxrefprop_idx1' => array(
  11696. 0 => 'stock_dbxref_id',
  11697. ),
  11698. 'stock_dbxrefprop_idx2' => array(
  11699. 0 => 'type_id',
  11700. ),
  11701. ),
  11702. 'foreign keys' => array(
  11703. 'cvterm' => array(
  11704. 'table' => 'cvterm',
  11705. 'columns' => array(
  11706. 'type_id' => 'cvterm_id',
  11707. ),
  11708. ),
  11709. 'stock_dbxref' => array(
  11710. 'table' => 'stock_dbxref',
  11711. 'columns' => array(
  11712. 'stock_dbxref_id' => 'stock_dbxref_id',
  11713. ),
  11714. ),
  11715. ),
  11716. );
  11717. return $description;
  11718. }
  11719. /**
  11720. * Implements hook_chado_schema_v1_2_stock_genotype()
  11721. * Purpose: To describe the structure of 'stock_genotype' to tripal
  11722. * @see tripal_core_chado_insert()
  11723. * @see tripal_core_chado_update()
  11724. * @see tripal_core_chado_select()
  11725. *
  11726. * @return
  11727. * An array describing the 'stock_genotype' table
  11728. *
  11729. * @ingroup tripal_chado_v1.2_schema_api
  11730. *
  11731. */
  11732. function tripal_core_chado_schema_v1_2_stock_genotype() {
  11733. $description = array(
  11734. 'description' => 'TODO: please describe this table!',
  11735. 'fields' => array(
  11736. 'stock_genotype_id' => array(
  11737. 'description' => 'TODO: please describe this field!',
  11738. 'type' => 'serial',
  11739. 'not null' => TRUE,
  11740. ),
  11741. 'stock_id' => array(
  11742. 'description' => 'TODO: please describe this field!',
  11743. 'type' => 'int',
  11744. 'not null' => TRUE,
  11745. ),
  11746. 'genotype_id' => array(
  11747. 'description' => 'TODO: please describe this field!',
  11748. 'type' => 'int',
  11749. 'not null' => TRUE,
  11750. ),
  11751. ),
  11752. 'primary key' => array(
  11753. 0 => 'stock_genotype_id',
  11754. ),
  11755. 'unique keys' => array(
  11756. 'stock_genotype_c1' => array(
  11757. 0 => 'stock_id',
  11758. 1 => 'genotype_id',
  11759. ),
  11760. ),
  11761. 'indexes' => array(
  11762. 'stock_genotype_idx1' => array(
  11763. 0 => 'stock_id',
  11764. ),
  11765. 'stock_genotype_idx2' => array(
  11766. 0 => 'genotype_id',
  11767. ),
  11768. ),
  11769. 'foreign keys' => array(
  11770. 'genotype' => array(
  11771. 'table' => 'genotype',
  11772. 'columns' => array(
  11773. 'genotype_id' => 'genotype_id',
  11774. ),
  11775. ),
  11776. 'stock' => array(
  11777. 'table' => 'stock',
  11778. 'columns' => array(
  11779. 'stock_id' => 'stock_id',
  11780. ),
  11781. ),
  11782. ),
  11783. );
  11784. return $description;
  11785. }
  11786. /**
  11787. * Implements hook_chado_schema_v1_2_stock_pub()
  11788. * Purpose: To describe the structure of 'stock_pub' to tripal
  11789. * @see tripal_core_chado_insert()
  11790. * @see tripal_core_chado_update()
  11791. * @see tripal_core_chado_select()
  11792. *
  11793. * @return
  11794. * An array describing the 'stock_pub' table
  11795. *
  11796. * @ingroup tripal_chado_v1.2_schema_api
  11797. *
  11798. */
  11799. function tripal_core_chado_schema_v1_2_stock_pub() {
  11800. $description = array(
  11801. 'description' => 'TODO: please describe this table!',
  11802. 'fields' => array(
  11803. 'stock_pub_id' => array(
  11804. 'description' => 'TODO: please describe this field!',
  11805. 'type' => 'serial',
  11806. 'not null' => TRUE,
  11807. ),
  11808. 'stock_id' => array(
  11809. 'description' => 'TODO: please describe this field!',
  11810. 'type' => 'int',
  11811. 'not null' => TRUE,
  11812. ),
  11813. 'pub_id' => array(
  11814. 'description' => 'TODO: please describe this field!',
  11815. 'type' => 'int',
  11816. 'not null' => TRUE,
  11817. ),
  11818. ),
  11819. 'primary key' => array(
  11820. 0 => 'stock_pub_id',
  11821. ),
  11822. 'unique keys' => array(
  11823. 'stock_pub_c1' => array(
  11824. 0 => 'stock_id',
  11825. 1 => 'pub_id',
  11826. ),
  11827. ),
  11828. 'indexes' => array(
  11829. 'stock_pub_idx1' => array(
  11830. 0 => 'stock_id',
  11831. ),
  11832. 'stock_pub_idx2' => array(
  11833. 0 => 'pub_id',
  11834. ),
  11835. ),
  11836. 'foreign keys' => array(
  11837. 'pub' => array(
  11838. 'table' => 'pub',
  11839. 'columns' => array(
  11840. 'pub_id' => 'pub_id',
  11841. ),
  11842. ),
  11843. 'stock' => array(
  11844. 'table' => 'stock',
  11845. 'columns' => array(
  11846. 'stock_id' => 'stock_id',
  11847. ),
  11848. ),
  11849. ),
  11850. );
  11851. return $description;
  11852. }
  11853. /**
  11854. * Implements hook_chado_schema_v1_2_stock_relationship()
  11855. * Purpose: To describe the structure of 'stock_relationship' to tripal
  11856. * @see tripal_core_chado_insert()
  11857. * @see tripal_core_chado_update()
  11858. * @see tripal_core_chado_select()
  11859. *
  11860. * @return
  11861. * An array describing the 'stock_relationship' table
  11862. *
  11863. * @ingroup tripal_chado_v1.2_schema_api
  11864. *
  11865. */
  11866. function tripal_core_chado_schema_v1_2_stock_relationship() {
  11867. $description = array(
  11868. 'description' => 'TODO: please describe this table!',
  11869. 'fields' => array(
  11870. 'stock_relationship_id' => array(
  11871. 'description' => 'TODO: please describe this field!',
  11872. 'type' => 'serial',
  11873. 'not null' => TRUE,
  11874. ),
  11875. 'subject_id' => array(
  11876. 'description' => 'TODO: please describe this field!',
  11877. 'type' => 'int',
  11878. 'not null' => TRUE,
  11879. ),
  11880. 'object_id' => array(
  11881. 'description' => 'TODO: please describe this field!',
  11882. 'type' => 'int',
  11883. 'not null' => TRUE,
  11884. ),
  11885. 'type_id' => array(
  11886. 'description' => 'TODO: please describe this field!',
  11887. 'type' => 'int',
  11888. 'not null' => TRUE,
  11889. ),
  11890. 'value' => array(
  11891. 'description' => 'TODO: please describe this field!',
  11892. 'type' => 'text',
  11893. 'not null' => FALSE,
  11894. ),
  11895. 'rank' => array(
  11896. 'description' => 'TODO: please describe this field!',
  11897. 'type' => 'int',
  11898. 'not null' => TRUE,
  11899. 'default' => 0,
  11900. ),
  11901. ),
  11902. 'primary key' => array(
  11903. 0 => 'stock_relationship_id',
  11904. ),
  11905. 'unique keys' => array(
  11906. 'stock_relationship_c1' => array(
  11907. 0 => 'subject_id',
  11908. 1 => 'object_id',
  11909. 2 => 'type_id',
  11910. 3 => 'rank',
  11911. ),
  11912. ),
  11913. 'indexes' => array(
  11914. 'stock_relationship_idx1' => array(
  11915. 0 => 'subject_id',
  11916. ),
  11917. 'stock_relationship_idx2' => array(
  11918. 0 => 'object_id',
  11919. ),
  11920. 'stock_relationship_idx3' => array(
  11921. 0 => 'type_id',
  11922. ),
  11923. ),
  11924. 'foreign keys' => array(
  11925. 'cvterm' => array(
  11926. 'table' => 'cvterm',
  11927. 'columns' => array(
  11928. 'type_id' => 'cvterm_id',
  11929. ),
  11930. ),
  11931. 'stock' => array(
  11932. 'table' => 'stock',
  11933. 'columns' => array(
  11934. 'subject_id' => 'stock_id',
  11935. 'object_id' => 'stock_id',
  11936. ),
  11937. ),
  11938. ),
  11939. );
  11940. return $description;
  11941. }
  11942. /**
  11943. * Implements hook_chado_schema_v1_2_stock_relationship_cvterm()
  11944. * Purpose: To describe the structure of 'stock_relationship_cvterm' to tripal
  11945. * @see tripal_core_chado_insert()
  11946. * @see tripal_core_chado_update()
  11947. * @see tripal_core_chado_select()
  11948. *
  11949. * @return
  11950. * An array describing the 'stock_relationship_cvterm' table
  11951. *
  11952. * @ingroup tripal_chado_v1.2_schema_api
  11953. *
  11954. */
  11955. function tripal_core_chado_schema_v1_2_stock_relationship_cvterm() {
  11956. $description = array(
  11957. 'description' => 'TODO: please describe this table!',
  11958. 'fields' => array(
  11959. 'stock_relationship_cvterm_id' => array(
  11960. 'description' => 'TODO: please describe this field!',
  11961. 'type' => 'serial',
  11962. 'not null' => TRUE,
  11963. ),
  11964. 'stock_relationship_id' => array(
  11965. 'description' => 'TODO: please describe this field!',
  11966. 'type' => 'int',
  11967. 'not null' => TRUE,
  11968. ),
  11969. 'cvterm_id' => array(
  11970. 'description' => 'TODO: please describe this field!',
  11971. 'type' => 'int',
  11972. 'not null' => TRUE,
  11973. ),
  11974. 'pub_id' => array(
  11975. 'description' => 'TODO: please describe this field!',
  11976. 'type' => 'int',
  11977. 'not null' => FALSE,
  11978. ),
  11979. ),
  11980. 'primary key' => array(
  11981. 0 => 'stock_relationship_cvterm_id',
  11982. ),
  11983. 'foreign keys' => array(
  11984. 'cvterm' => array(
  11985. 'table' => 'cvterm',
  11986. 'columns' => array(
  11987. 'cvterm_id' => 'cvterm_id',
  11988. ),
  11989. ),
  11990. 'pub' => array(
  11991. 'table' => 'pub',
  11992. 'columns' => array(
  11993. 'pub_id' => 'pub_id',
  11994. ),
  11995. ),
  11996. 'stock_relationship' => array(
  11997. 'table' => 'stock_relationship',
  11998. 'columns' => array(
  11999. 'stock_relationship_id' => 'stock_relationship_id',
  12000. ),
  12001. ),
  12002. ),
  12003. );
  12004. return $description;
  12005. }
  12006. /**
  12007. * Implements hook_chado_schema_v1_2_stock_relationship_pub()
  12008. * Purpose: To describe the structure of 'stock_relationship_pub' to tripal
  12009. * @see tripal_core_chado_insert()
  12010. * @see tripal_core_chado_update()
  12011. * @see tripal_core_chado_select()
  12012. *
  12013. * @return
  12014. * An array describing the 'stock_relationship_pub' table
  12015. *
  12016. * @ingroup tripal_chado_v1.2_schema_api
  12017. *
  12018. */
  12019. function tripal_core_chado_schema_v1_2_stock_relationship_pub() {
  12020. $description = array(
  12021. 'description' => 'TODO: please describe this table!',
  12022. 'fields' => array(
  12023. 'stock_relationship_pub_id' => array(
  12024. 'description' => 'TODO: please describe this field!',
  12025. 'type' => 'serial',
  12026. 'not null' => TRUE,
  12027. ),
  12028. 'stock_relationship_id' => array(
  12029. 'description' => 'TODO: please describe this field!',
  12030. 'type' => 'int',
  12031. 'not null' => TRUE,
  12032. ),
  12033. 'pub_id' => array(
  12034. 'description' => 'TODO: please describe this field!',
  12035. 'type' => 'int',
  12036. 'not null' => TRUE,
  12037. ),
  12038. ),
  12039. 'primary key' => array(
  12040. 0 => 'stock_relationship_pub_id',
  12041. ),
  12042. 'unique keys' => array(
  12043. 'stock_relationship_pub_c1' => array(
  12044. 0 => 'stock_relationship_id',
  12045. 1 => 'pub_id',
  12046. ),
  12047. ),
  12048. 'indexes' => array(
  12049. 'stock_relationship_pub_idx1' => array(
  12050. 0 => 'stock_relationship_id',
  12051. ),
  12052. 'stock_relationship_pub_idx2' => array(
  12053. 0 => 'pub_id',
  12054. ),
  12055. ),
  12056. 'foreign keys' => array(
  12057. 'pub' => array(
  12058. 'table' => 'pub',
  12059. 'columns' => array(
  12060. 'pub_id' => 'pub_id',
  12061. ),
  12062. ),
  12063. 'stock_relationship' => array(
  12064. 'table' => 'stock_relationship',
  12065. 'columns' => array(
  12066. 'stock_relationship_id' => 'stock_relationship_id',
  12067. ),
  12068. ),
  12069. ),
  12070. );
  12071. return $description;
  12072. }
  12073. /**
  12074. * Implements hook_chado_schema_v1_2_stockcollection()
  12075. * Purpose: To describe the structure of 'stockcollection' to tripal
  12076. * @see tripal_core_chado_insert()
  12077. * @see tripal_core_chado_update()
  12078. * @see tripal_core_chado_select()
  12079. *
  12080. * @return
  12081. * An array describing the 'stockcollection' table
  12082. *
  12083. * @ingroup tripal_chado_v1.2_schema_api
  12084. *
  12085. */
  12086. function tripal_core_chado_schema_v1_2_stockcollection() {
  12087. $description = array(
  12088. 'description' => 'TODO: please describe this table!',
  12089. 'fields' => array(
  12090. 'stockcollection_id' => array(
  12091. 'description' => 'TODO: please describe this field!',
  12092. 'type' => 'serial',
  12093. 'not null' => TRUE,
  12094. ),
  12095. 'type_id' => array(
  12096. 'description' => 'TODO: please describe this field!',
  12097. 'type' => 'int',
  12098. 'not null' => TRUE,
  12099. ),
  12100. 'contact_id' => array(
  12101. 'description' => 'TODO: please describe this field!',
  12102. 'type' => 'int',
  12103. 'not null' => FALSE,
  12104. ),
  12105. 'name' => array(
  12106. 'description' => 'TODO: please describe this field!',
  12107. 'type' => 'varchar',
  12108. 'length' => '255',
  12109. 'not null' => FALSE,
  12110. ),
  12111. 'uniquename' => array(
  12112. 'description' => 'TODO: please describe this field!',
  12113. 'type' => 'text',
  12114. 'not null' => TRUE,
  12115. ),
  12116. ),
  12117. 'primary key' => array(
  12118. 0 => 'stockcollection_id',
  12119. ),
  12120. 'unique keys' => array(
  12121. 'stockcollection_c1' => array(
  12122. 0 => 'uniquename',
  12123. 1 => 'type_id',
  12124. ),
  12125. ),
  12126. 'indexes' => array(
  12127. 'stockcollection_idx1' => array(
  12128. 0 => 'contact_id',
  12129. ),
  12130. 'stockcollection_idx2' => array(
  12131. 0 => 'type_id',
  12132. ),
  12133. 'stockcollection_idx3' => array(
  12134. 0 => 'uniquename',
  12135. ),
  12136. 'stockcollection_name_ind1' => array(
  12137. 0 => 'name',
  12138. ),
  12139. ),
  12140. 'foreign keys' => array(
  12141. 'cvterm' => array(
  12142. 'table' => 'cvterm',
  12143. 'columns' => array(
  12144. 'type_id' => 'cvterm_id',
  12145. ),
  12146. ),
  12147. 'contact' => array(
  12148. 'table' => 'contact',
  12149. 'columns' => array(
  12150. 'contact_id' => 'contact_id',
  12151. ),
  12152. ),
  12153. ),
  12154. );
  12155. return $description;
  12156. }
  12157. /**
  12158. * Implements hook_chado_schema_v1_2_stockcollection_stock()
  12159. * Purpose: To describe the structure of 'stockcollection_stock' to tripal
  12160. * @see tripal_core_chado_insert()
  12161. * @see tripal_core_chado_update()
  12162. * @see tripal_core_chado_select()
  12163. *
  12164. * @return
  12165. * An array describing the 'stockcollection_stock' table
  12166. *
  12167. * @ingroup tripal_chado_v1.2_schema_api
  12168. *
  12169. */
  12170. function tripal_core_chado_schema_v1_2_stockcollection_stock() {
  12171. $description = array(
  12172. 'description' => 'TODO: please describe this table!',
  12173. 'fields' => array(
  12174. 'stockcollection_stock_id' => array(
  12175. 'description' => 'TODO: please describe this field!',
  12176. 'type' => 'serial',
  12177. 'not null' => TRUE,
  12178. ),
  12179. 'stockcollection_id' => array(
  12180. 'description' => 'TODO: please describe this field!',
  12181. 'type' => 'int',
  12182. 'not null' => TRUE,
  12183. ),
  12184. 'stock_id' => array(
  12185. 'description' => 'TODO: please describe this field!',
  12186. 'type' => 'int',
  12187. 'not null' => TRUE,
  12188. ),
  12189. ),
  12190. 'primary key' => array(
  12191. 0 => 'stockcollection_stock_id',
  12192. ),
  12193. 'unique keys' => array(
  12194. 'stockcollection_stock_c1' => array(
  12195. 0 => 'stockcollection_id',
  12196. 1 => 'stock_id',
  12197. ),
  12198. ),
  12199. 'indexes' => array(
  12200. 'stockcollection_stock_idx1' => array(
  12201. 0 => 'stockcollection_id',
  12202. ),
  12203. 'stockcollection_stock_idx2' => array(
  12204. 0 => 'stock_id',
  12205. ),
  12206. ),
  12207. 'foreign keys' => array(
  12208. 'stock' => array(
  12209. 'table' => 'stock',
  12210. 'columns' => array(
  12211. 'stock_id' => 'stock_id',
  12212. ),
  12213. ),
  12214. 'stockcollection' => array(
  12215. 'table' => 'stockcollection',
  12216. 'columns' => array(
  12217. 'stockcollection_id' => 'stockcollection_id',
  12218. ),
  12219. ),
  12220. ),
  12221. );
  12222. return $description;
  12223. }
  12224. /**
  12225. * Implements hook_chado_schema_v1_2_stockcollectionprop()
  12226. * Purpose: To describe the structure of 'stockcollectionprop' to tripal
  12227. * @see tripal_core_chado_insert()
  12228. * @see tripal_core_chado_update()
  12229. * @see tripal_core_chado_select()
  12230. *
  12231. * @return
  12232. * An array describing the 'stockcollectionprop' table
  12233. *
  12234. * @ingroup tripal_chado_v1.2_schema_api
  12235. *
  12236. */
  12237. function tripal_core_chado_schema_v1_2_stockcollectionprop() {
  12238. $description = array(
  12239. 'description' => 'TODO: please describe this table!',
  12240. 'fields' => array(
  12241. 'stockcollectionprop_id' => array(
  12242. 'description' => 'TODO: please describe this field!',
  12243. 'type' => 'serial',
  12244. 'not null' => TRUE,
  12245. ),
  12246. 'stockcollection_id' => array(
  12247. 'description' => 'TODO: please describe this field!',
  12248. 'type' => 'int',
  12249. 'not null' => TRUE,
  12250. ),
  12251. 'type_id' => array(
  12252. 'description' => 'TODO: please describe this field!',
  12253. 'type' => 'int',
  12254. 'not null' => TRUE,
  12255. ),
  12256. 'value' => array(
  12257. 'description' => 'TODO: please describe this field!',
  12258. 'type' => 'text',
  12259. 'not null' => FALSE,
  12260. ),
  12261. 'rank' => array(
  12262. 'description' => 'TODO: please describe this field!',
  12263. 'type' => 'int',
  12264. 'not null' => TRUE,
  12265. 'default' => 0,
  12266. ),
  12267. ),
  12268. 'primary key' => array(
  12269. 0 => 'stockcollectionprop_id',
  12270. ),
  12271. 'unique keys' => array(
  12272. 'stockcollectionprop_c1' => array(
  12273. 0 => 'stockcollection_id',
  12274. 1 => 'type_id',
  12275. 2 => 'rank',
  12276. ),
  12277. ),
  12278. 'indexes' => array(
  12279. 'stockcollectionprop_idx1' => array(
  12280. 0 => 'stockcollection_id',
  12281. ),
  12282. 'stockcollectionprop_idx2' => array(
  12283. 0 => 'type_id',
  12284. ),
  12285. ),
  12286. 'foreign keys' => array(
  12287. 'cvterm' => array(
  12288. 'table' => 'cvterm',
  12289. 'columns' => array(
  12290. 'type_id' => 'cvterm_id',
  12291. ),
  12292. ),
  12293. 'stockcollection' => array(
  12294. 'table' => 'stockcollection',
  12295. 'columns' => array(
  12296. 'stockcollection_id' => 'stockcollection_id',
  12297. ),
  12298. ),
  12299. ),
  12300. );
  12301. return $description;
  12302. }
  12303. /**
  12304. * Implements hook_chado_schema_v1_2_stockprop()
  12305. * Purpose: To describe the structure of 'stockprop' to tripal
  12306. * @see tripal_core_chado_insert()
  12307. * @see tripal_core_chado_update()
  12308. * @see tripal_core_chado_select()
  12309. *
  12310. * @return
  12311. * An array describing the 'stockprop' table
  12312. *
  12313. * @ingroup tripal_chado_v1.2_schema_api
  12314. *
  12315. */
  12316. function tripal_core_chado_schema_v1_2_stockprop() {
  12317. $description = array(
  12318. 'description' => 'TODO: please describe this table!',
  12319. 'fields' => array(
  12320. 'stockprop_id' => array(
  12321. 'description' => 'TODO: please describe this field!',
  12322. 'type' => 'serial',
  12323. 'not null' => TRUE,
  12324. ),
  12325. 'stock_id' => array(
  12326. 'description' => 'TODO: please describe this field!',
  12327. 'type' => 'int',
  12328. 'not null' => TRUE,
  12329. ),
  12330. 'type_id' => array(
  12331. 'description' => 'TODO: please describe this field!',
  12332. 'type' => 'int',
  12333. 'not null' => TRUE,
  12334. ),
  12335. 'value' => array(
  12336. 'description' => 'TODO: please describe this field!',
  12337. 'type' => 'text',
  12338. 'not null' => FALSE,
  12339. ),
  12340. 'rank' => array(
  12341. 'description' => 'TODO: please describe this field!',
  12342. 'type' => 'int',
  12343. 'not null' => TRUE,
  12344. 'default' => 0,
  12345. ),
  12346. ),
  12347. 'primary key' => array(
  12348. 0 => 'stockprop_id',
  12349. ),
  12350. 'unique keys' => array(
  12351. 'stockprop_c1' => array(
  12352. 0 => 'stock_id',
  12353. 1 => 'type_id',
  12354. 2 => 'rank',
  12355. ),
  12356. ),
  12357. 'indexes' => array(
  12358. 'stockprop_idx1' => array(
  12359. 0 => 'stock_id',
  12360. ),
  12361. 'stockprop_idx2' => array(
  12362. 0 => 'type_id',
  12363. ),
  12364. ),
  12365. 'foreign keys' => array(
  12366. 'cvterm' => array(
  12367. 'table' => 'cvterm',
  12368. 'columns' => array(
  12369. 'type_id' => 'cvterm_id',
  12370. ),
  12371. ),
  12372. 'stock' => array(
  12373. 'table' => 'stock',
  12374. 'columns' => array(
  12375. 'stock_id' => 'stock_id',
  12376. ),
  12377. ),
  12378. ),
  12379. );
  12380. return $description;
  12381. }
  12382. /**
  12383. * Implements hook_chado_schema_v1_2_stockprop_pub()
  12384. * Purpose: To describe the structure of 'stockprop_pub' to tripal
  12385. * @see tripal_core_chado_insert()
  12386. * @see tripal_core_chado_update()
  12387. * @see tripal_core_chado_select()
  12388. *
  12389. * @return
  12390. * An array describing the 'stockprop_pub' table
  12391. *
  12392. * @ingroup tripal_chado_v1.2_schema_api
  12393. *
  12394. */
  12395. function tripal_core_chado_schema_v1_2_stockprop_pub() {
  12396. $description = array(
  12397. 'description' => 'TODO: please describe this table!',
  12398. 'fields' => array(
  12399. 'stockprop_pub_id' => array(
  12400. 'description' => 'TODO: please describe this field!',
  12401. 'type' => 'serial',
  12402. 'not null' => TRUE,
  12403. ),
  12404. 'stockprop_id' => array(
  12405. 'description' => 'TODO: please describe this field!',
  12406. 'type' => 'int',
  12407. 'not null' => TRUE,
  12408. ),
  12409. 'pub_id' => array(
  12410. 'description' => 'TODO: please describe this field!',
  12411. 'type' => 'int',
  12412. 'not null' => TRUE,
  12413. ),
  12414. ),
  12415. 'primary key' => array(
  12416. 0 => 'stockprop_pub_id',
  12417. ),
  12418. 'unique keys' => array(
  12419. 'stockprop_pub_c1' => array(
  12420. 0 => 'stockprop_id',
  12421. 1 => 'pub_id',
  12422. ),
  12423. ),
  12424. 'indexes' => array(
  12425. 'stockprop_pub_idx1' => array(
  12426. 0 => 'stockprop_id',
  12427. ),
  12428. 'stockprop_pub_idx2' => array(
  12429. 0 => 'pub_id',
  12430. ),
  12431. ),
  12432. 'foreign keys' => array(
  12433. 'pub' => array(
  12434. 'table' => 'pub',
  12435. 'columns' => array(
  12436. 'pub_id' => 'pub_id',
  12437. ),
  12438. ),
  12439. 'stockprop' => array(
  12440. 'table' => 'stockprop',
  12441. 'columns' => array(
  12442. 'stockprop_id' => 'stockprop_id',
  12443. ),
  12444. ),
  12445. ),
  12446. );
  12447. return $description;
  12448. }
  12449. /**
  12450. * Implements hook_chado_schema_v1_2_study()
  12451. * Purpose: To describe the structure of 'study' to tripal
  12452. * @see tripal_core_chado_insert()
  12453. * @see tripal_core_chado_update()
  12454. * @see tripal_core_chado_select()
  12455. *
  12456. * @return
  12457. * An array describing the 'study' table
  12458. *
  12459. * @ingroup tripal_chado_v1.2_schema_api
  12460. *
  12461. */
  12462. function tripal_core_chado_schema_v1_2_study() {
  12463. $description = array(
  12464. 'description' => 'TODO: please describe this table!',
  12465. 'fields' => array(
  12466. 'study_id' => array(
  12467. 'description' => 'TODO: please describe this field!',
  12468. 'type' => 'serial',
  12469. 'not null' => TRUE,
  12470. ),
  12471. 'contact_id' => array(
  12472. 'description' => 'TODO: please describe this field!',
  12473. 'type' => 'int',
  12474. 'not null' => TRUE,
  12475. ),
  12476. 'pub_id' => array(
  12477. 'description' => 'TODO: please describe this field!',
  12478. 'type' => 'int',
  12479. 'not null' => FALSE,
  12480. ),
  12481. 'dbxref_id' => array(
  12482. 'description' => 'TODO: please describe this field!',
  12483. 'type' => 'int',
  12484. 'not null' => FALSE,
  12485. ),
  12486. 'name' => array(
  12487. 'description' => 'TODO: please describe this field!',
  12488. 'type' => 'text',
  12489. 'not null' => TRUE,
  12490. ),
  12491. 'description' => array(
  12492. 'description' => 'TODO: please describe this field!',
  12493. 'type' => 'text',
  12494. 'not null' => FALSE,
  12495. ),
  12496. ),
  12497. 'primary key' => array(
  12498. 0 => 'study_id',
  12499. ),
  12500. 'unique keys' => array(
  12501. 'study_c1' => array(
  12502. 0 => 'name',
  12503. ),
  12504. ),
  12505. 'indexes' => array(
  12506. 'study_idx1' => array(
  12507. 0 => 'contact_id',
  12508. ),
  12509. 'study_idx2' => array(
  12510. 0 => 'pub_id',
  12511. ),
  12512. 'study_idx3' => array(
  12513. 0 => 'dbxref_id',
  12514. ),
  12515. ),
  12516. 'foreign keys' => array(
  12517. 'dbxref' => array(
  12518. 'table' => 'dbxref',
  12519. 'columns' => array(
  12520. 'dbxref_id' => 'dbxref_id',
  12521. ),
  12522. ),
  12523. 'pub' => array(
  12524. 'table' => 'pub',
  12525. 'columns' => array(
  12526. 'pub_id' => 'pub_id',
  12527. ),
  12528. ),
  12529. 'contact' => array(
  12530. 'table' => 'contact',
  12531. 'columns' => array(
  12532. 'contact_id' => 'contact_id',
  12533. ),
  12534. ),
  12535. ),
  12536. );
  12537. return $description;
  12538. }
  12539. /**
  12540. * Implements hook_chado_schema_v1_2_study_assay()
  12541. * Purpose: To describe the structure of 'study_assay' to tripal
  12542. * @see tripal_core_chado_insert()
  12543. * @see tripal_core_chado_update()
  12544. * @see tripal_core_chado_select()
  12545. *
  12546. * @return
  12547. * An array describing the 'study_assay' table
  12548. *
  12549. * @ingroup tripal_chado_v1.2_schema_api
  12550. *
  12551. */
  12552. function tripal_core_chado_schema_v1_2_study_assay() {
  12553. $description = array(
  12554. 'description' => 'TODO: please describe this table!',
  12555. 'fields' => array(
  12556. 'study_assay_id' => array(
  12557. 'description' => 'TODO: please describe this field!',
  12558. 'type' => 'serial',
  12559. 'not null' => TRUE,
  12560. ),
  12561. 'study_id' => array(
  12562. 'description' => 'TODO: please describe this field!',
  12563. 'type' => 'int',
  12564. 'not null' => TRUE,
  12565. ),
  12566. 'assay_id' => array(
  12567. 'description' => 'TODO: please describe this field!',
  12568. 'type' => 'int',
  12569. 'not null' => TRUE,
  12570. ),
  12571. ),
  12572. 'primary key' => array(
  12573. 0 => 'study_assay_id',
  12574. ),
  12575. 'unique keys' => array(
  12576. 'study_assay_c1' => array(
  12577. 0 => 'study_id',
  12578. 1 => 'assay_id',
  12579. ),
  12580. ),
  12581. 'indexes' => array(
  12582. 'study_assay_idx1' => array(
  12583. 0 => 'study_id',
  12584. ),
  12585. 'study_assay_idx2' => array(
  12586. 0 => 'assay_id',
  12587. ),
  12588. ),
  12589. 'foreign keys' => array(
  12590. 'assay' => array(
  12591. 'table' => 'assay',
  12592. 'columns' => array(
  12593. 'assay_id' => 'assay_id',
  12594. ),
  12595. ),
  12596. 'study' => array(
  12597. 'table' => 'study',
  12598. 'columns' => array(
  12599. 'study_id' => 'study_id',
  12600. ),
  12601. ),
  12602. ),
  12603. );
  12604. return $description;
  12605. }
  12606. /**
  12607. * Implements hook_chado_schema_v1_2_studydesign()
  12608. * Purpose: To describe the structure of 'studydesign' to tripal
  12609. * @see tripal_core_chado_insert()
  12610. * @see tripal_core_chado_update()
  12611. * @see tripal_core_chado_select()
  12612. *
  12613. * @return
  12614. * An array describing the 'studydesign' table
  12615. *
  12616. * @ingroup tripal_chado_v1.2_schema_api
  12617. *
  12618. */
  12619. function tripal_core_chado_schema_v1_2_studydesign() {
  12620. $description = array(
  12621. 'description' => 'TODO: please describe this table!',
  12622. 'fields' => array(
  12623. 'studydesign_id' => array(
  12624. 'description' => 'TODO: please describe this field!',
  12625. 'type' => 'serial',
  12626. 'not null' => TRUE,
  12627. ),
  12628. 'study_id' => array(
  12629. 'description' => 'TODO: please describe this field!',
  12630. 'type' => 'int',
  12631. 'not null' => TRUE,
  12632. ),
  12633. 'description' => array(
  12634. 'description' => 'TODO: please describe this field!',
  12635. 'type' => 'text',
  12636. 'not null' => FALSE,
  12637. ),
  12638. ),
  12639. 'primary key' => array(
  12640. 0 => 'studydesign_id',
  12641. ),
  12642. 'indexes' => array(
  12643. 'studydesign_idx1' => array(
  12644. 0 => 'study_id',
  12645. ),
  12646. ),
  12647. 'foreign keys' => array(
  12648. 'study' => array(
  12649. 'table' => 'study',
  12650. 'columns' => array(
  12651. 'study_id' => 'study_id',
  12652. ),
  12653. ),
  12654. ),
  12655. );
  12656. return $description;
  12657. }
  12658. /**
  12659. * Implements hook_chado_schema_v1_2_studydesignprop()
  12660. * Purpose: To describe the structure of 'studydesignprop' to tripal
  12661. * @see tripal_core_chado_insert()
  12662. * @see tripal_core_chado_update()
  12663. * @see tripal_core_chado_select()
  12664. *
  12665. * @return
  12666. * An array describing the 'studydesignprop' table
  12667. *
  12668. * @ingroup tripal_chado_v1.2_schema_api
  12669. *
  12670. */
  12671. function tripal_core_chado_schema_v1_2_studydesignprop() {
  12672. $description = array(
  12673. 'description' => 'TODO: please describe this table!',
  12674. 'fields' => array(
  12675. 'studydesignprop_id' => array(
  12676. 'description' => 'TODO: please describe this field!',
  12677. 'type' => 'serial',
  12678. 'not null' => TRUE,
  12679. ),
  12680. 'studydesign_id' => array(
  12681. 'description' => 'TODO: please describe this field!',
  12682. 'type' => 'int',
  12683. 'not null' => TRUE,
  12684. ),
  12685. 'type_id' => array(
  12686. 'description' => 'TODO: please describe this field!',
  12687. 'type' => 'int',
  12688. 'not null' => TRUE,
  12689. ),
  12690. 'value' => array(
  12691. 'description' => 'TODO: please describe this field!',
  12692. 'type' => 'text',
  12693. 'not null' => FALSE,
  12694. ),
  12695. 'rank' => array(
  12696. 'description' => 'TODO: please describe this field!',
  12697. 'type' => 'int',
  12698. 'not null' => TRUE,
  12699. 'default' => 0,
  12700. ),
  12701. ),
  12702. 'primary key' => array(
  12703. 0 => 'studydesignprop_id',
  12704. ),
  12705. 'unique keys' => array(
  12706. 'studydesignprop_c1' => array(
  12707. 0 => 'studydesign_id',
  12708. 1 => 'type_id',
  12709. 2 => 'rank',
  12710. ),
  12711. ),
  12712. 'indexes' => array(
  12713. 'studydesignprop_idx1' => array(
  12714. 0 => 'studydesign_id',
  12715. ),
  12716. 'studydesignprop_idx2' => array(
  12717. 0 => 'type_id',
  12718. ),
  12719. ),
  12720. 'foreign keys' => array(
  12721. 'cvterm' => array(
  12722. 'table' => 'cvterm',
  12723. 'columns' => array(
  12724. 'type_id' => 'cvterm_id',
  12725. ),
  12726. ),
  12727. 'studydesign' => array(
  12728. 'table' => 'studydesign',
  12729. 'columns' => array(
  12730. 'studydesign_id' => 'studydesign_id',
  12731. ),
  12732. ),
  12733. ),
  12734. );
  12735. return $description;
  12736. }
  12737. /**
  12738. * Implements hook_chado_schema_v1_2_studyfactor()
  12739. * Purpose: To describe the structure of 'studyfactor' to tripal
  12740. * @see tripal_core_chado_insert()
  12741. * @see tripal_core_chado_update()
  12742. * @see tripal_core_chado_select()
  12743. *
  12744. * @return
  12745. * An array describing the 'studyfactor' table
  12746. *
  12747. * @ingroup tripal_chado_v1.2_schema_api
  12748. *
  12749. */
  12750. function tripal_core_chado_schema_v1_2_studyfactor() {
  12751. $description = array(
  12752. 'description' => 'TODO: please describe this table!',
  12753. 'fields' => array(
  12754. 'studyfactor_id' => array(
  12755. 'description' => 'TODO: please describe this field!',
  12756. 'type' => 'serial',
  12757. 'not null' => TRUE,
  12758. ),
  12759. 'studydesign_id' => array(
  12760. 'description' => 'TODO: please describe this field!',
  12761. 'type' => 'int',
  12762. 'not null' => TRUE,
  12763. ),
  12764. 'type_id' => array(
  12765. 'description' => 'TODO: please describe this field!',
  12766. 'type' => 'int',
  12767. 'not null' => FALSE,
  12768. ),
  12769. 'name' => array(
  12770. 'description' => 'TODO: please describe this field!',
  12771. 'type' => 'text',
  12772. 'not null' => TRUE,
  12773. ),
  12774. 'description' => array(
  12775. 'description' => 'TODO: please describe this field!',
  12776. 'type' => 'text',
  12777. 'not null' => FALSE,
  12778. ),
  12779. ),
  12780. 'primary key' => array(
  12781. 0 => 'studyfactor_id',
  12782. ),
  12783. 'indexes' => array(
  12784. 'studyfactor_idx1' => array(
  12785. 0 => 'studydesign_id',
  12786. ),
  12787. 'studyfactor_idx2' => array(
  12788. 0 => 'type_id',
  12789. ),
  12790. ),
  12791. 'foreign keys' => array(
  12792. 'cvterm' => array(
  12793. 'table' => 'cvterm',
  12794. 'columns' => array(
  12795. 'type_id' => 'cvterm_id',
  12796. ),
  12797. ),
  12798. 'studydesign' => array(
  12799. 'table' => 'studydesign',
  12800. 'columns' => array(
  12801. 'studydesign_id' => 'studydesign_id',
  12802. ),
  12803. ),
  12804. ),
  12805. );
  12806. return $description;
  12807. }
  12808. /**
  12809. * Implements hook_chado_schema_v1_2_studyfactorvalue()
  12810. * Purpose: To describe the structure of 'studyfactorvalue' to tripal
  12811. * @see tripal_core_chado_insert()
  12812. * @see tripal_core_chado_update()
  12813. * @see tripal_core_chado_select()
  12814. *
  12815. * @return
  12816. * An array describing the 'studyfactorvalue' table
  12817. *
  12818. * @ingroup tripal_chado_v1.2_schema_api
  12819. *
  12820. */
  12821. function tripal_core_chado_schema_v1_2_studyfactorvalue() {
  12822. $description = array(
  12823. 'description' => 'TODO: please describe this table!',
  12824. 'fields' => array(
  12825. 'studyfactorvalue_id' => array(
  12826. 'description' => 'TODO: please describe this field!',
  12827. 'type' => 'serial',
  12828. 'not null' => TRUE,
  12829. ),
  12830. 'studyfactor_id' => array(
  12831. 'description' => 'TODO: please describe this field!',
  12832. 'type' => 'int',
  12833. 'not null' => TRUE,
  12834. ),
  12835. 'assay_id' => array(
  12836. 'description' => 'TODO: please describe this field!',
  12837. 'type' => 'int',
  12838. 'not null' => TRUE,
  12839. ),
  12840. 'factorvalue' => array(
  12841. 'description' => 'TODO: please describe this field!',
  12842. 'type' => 'text',
  12843. 'not null' => FALSE,
  12844. ),
  12845. 'name' => array(
  12846. 'description' => 'TODO: please describe this field!',
  12847. 'type' => 'text',
  12848. 'not null' => FALSE,
  12849. ),
  12850. 'rank' => array(
  12851. 'description' => 'TODO: please describe this field!',
  12852. 'type' => 'int',
  12853. 'not null' => TRUE,
  12854. 'default' => 0,
  12855. ),
  12856. ),
  12857. 'primary key' => array(
  12858. 0 => 'studyfactorvalue_id',
  12859. ),
  12860. 'indexes' => array(
  12861. 'studyfactorvalue_idx1' => array(
  12862. 0 => 'studyfactor_id',
  12863. ),
  12864. 'studyfactorvalue_idx2' => array(
  12865. 0 => 'assay_id',
  12866. ),
  12867. ),
  12868. 'foreign keys' => array(
  12869. 'assay' => array(
  12870. 'table' => 'assay',
  12871. 'columns' => array(
  12872. 'assay_id' => 'assay_id',
  12873. ),
  12874. ),
  12875. 'studyfactor' => array(
  12876. 'table' => 'studyfactor',
  12877. 'columns' => array(
  12878. 'studyfactor_id' => 'studyfactor_id',
  12879. ),
  12880. ),
  12881. ),
  12882. );
  12883. return $description;
  12884. }
  12885. /**
  12886. * Implements hook_chado_schema_v1_2_studyprop()
  12887. * Purpose: To describe the structure of 'studyprop' to tripal
  12888. * @see tripal_core_chado_insert()
  12889. * @see tripal_core_chado_update()
  12890. * @see tripal_core_chado_select()
  12891. *
  12892. * @return
  12893. * An array describing the 'studyprop' table
  12894. *
  12895. * @ingroup tripal_chado_v1.2_schema_api
  12896. *
  12897. */
  12898. function tripal_core_chado_schema_v1_2_studyprop() {
  12899. $description = array(
  12900. 'description' => 'TODO: please describe this table!',
  12901. 'fields' => array(
  12902. 'studyprop_id' => array(
  12903. 'description' => 'TODO: please describe this field!',
  12904. 'type' => 'serial',
  12905. 'not null' => TRUE,
  12906. ),
  12907. 'study_id' => array(
  12908. 'description' => 'TODO: please describe this field!',
  12909. 'type' => 'int',
  12910. 'not null' => TRUE,
  12911. ),
  12912. 'type_id' => array(
  12913. 'description' => 'TODO: please describe this field!',
  12914. 'type' => 'int',
  12915. 'not null' => TRUE,
  12916. ),
  12917. 'value' => array(
  12918. 'description' => 'TODO: please describe this field!',
  12919. 'type' => 'text',
  12920. 'not null' => FALSE,
  12921. ),
  12922. 'rank' => array(
  12923. 'description' => 'TODO: please describe this field!',
  12924. 'type' => 'int',
  12925. 'not null' => TRUE,
  12926. 'default' => 0,
  12927. ),
  12928. ),
  12929. 'primary key' => array(
  12930. 0 => 'studyprop_id',
  12931. ),
  12932. 'unique keys' => array(
  12933. 'study_id' => array(
  12934. 0 => 'study_id',
  12935. 1 => 'type_id',
  12936. 2 => 'rank',
  12937. ),
  12938. ),
  12939. 'indexes' => array(
  12940. 'studyprop_idx1' => array(
  12941. 0 => 'study_id',
  12942. ),
  12943. 'studyprop_idx2' => array(
  12944. 0 => 'type_id',
  12945. ),
  12946. ),
  12947. 'foreign keys' => array(
  12948. 'cvterm' => array(
  12949. 'table' => 'cvterm',
  12950. 'columns' => array(
  12951. 'type_id' => 'cvterm_id',
  12952. ),
  12953. ),
  12954. 'study' => array(
  12955. 'table' => 'study',
  12956. 'columns' => array(
  12957. 'study_id' => 'study_id',
  12958. ),
  12959. ),
  12960. ),
  12961. );
  12962. return $description;
  12963. }
  12964. /**
  12965. * Implements hook_chado_schema_v1_2_studyprop_feature()
  12966. * Purpose: To describe the structure of 'studyprop_feature' to tripal
  12967. * @see tripal_core_chado_insert()
  12968. * @see tripal_core_chado_update()
  12969. * @see tripal_core_chado_select()
  12970. *
  12971. * @return
  12972. * An array describing the 'studyprop_feature' table
  12973. *
  12974. * @ingroup tripal_chado_v1.2_schema_api
  12975. *
  12976. */
  12977. function tripal_core_chado_schema_v1_2_studyprop_feature() {
  12978. $description = array(
  12979. 'description' => 'TODO: please describe this table!',
  12980. 'fields' => array(
  12981. 'studyprop_feature_id' => array(
  12982. 'description' => 'TODO: please describe this field!',
  12983. 'type' => 'serial',
  12984. 'not null' => TRUE,
  12985. ),
  12986. 'studyprop_id' => array(
  12987. 'description' => 'TODO: please describe this field!',
  12988. 'type' => 'int',
  12989. 'not null' => TRUE,
  12990. ),
  12991. 'feature_id' => array(
  12992. 'description' => 'TODO: please describe this field!',
  12993. 'type' => 'int',
  12994. 'not null' => TRUE,
  12995. ),
  12996. 'type_id' => array(
  12997. 'description' => 'TODO: please describe this field!',
  12998. 'type' => 'int',
  12999. 'not null' => FALSE,
  13000. ),
  13001. ),
  13002. 'primary key' => array(
  13003. 0 => 'studyprop_feature_id',
  13004. ),
  13005. 'unique keys' => array(
  13006. 'studyprop_id' => array(
  13007. 0 => 'studyprop_id',
  13008. 1 => 'feature_id',
  13009. ),
  13010. ),
  13011. 'indexes' => array(
  13012. 'studyprop_feature_idx1' => array(
  13013. 0 => 'studyprop_id',
  13014. ),
  13015. 'studyprop_feature_idx2' => array(
  13016. 0 => 'feature_id',
  13017. ),
  13018. ),
  13019. 'foreign keys' => array(
  13020. 'cvterm' => array(
  13021. 'table' => 'cvterm',
  13022. 'columns' => array(
  13023. 'type_id' => 'cvterm_id',
  13024. ),
  13025. ),
  13026. 'feature' => array(
  13027. 'table' => 'feature',
  13028. 'columns' => array(
  13029. 'feature_id' => 'feature_id',
  13030. ),
  13031. ),
  13032. 'studyprop' => array(
  13033. 'table' => 'studyprop',
  13034. 'columns' => array(
  13035. 'studyprop_id' => 'studyprop_id',
  13036. ),
  13037. ),
  13038. ),
  13039. );
  13040. return $description;
  13041. }
  13042. /**
  13043. * Implements hook_chado_schema_v1_2_synonym()
  13044. * Purpose: To describe the structure of 'synonym' to tripal
  13045. * @see tripal_core_chado_insert()
  13046. * @see tripal_core_chado_update()
  13047. * @see tripal_core_chado_select()
  13048. *
  13049. * @return
  13050. * An array describing the 'synonym' table
  13051. *
  13052. * @ingroup tripal_chado_v1.2_schema_api
  13053. *
  13054. */
  13055. function tripal_core_chado_schema_v1_2_synonym() {
  13056. $description = array(
  13057. 'description' => 'TODO: please describe this table!',
  13058. 'fields' => array(
  13059. 'synonym_id' => array(
  13060. 'description' => 'TODO: please describe this field!',
  13061. 'type' => 'serial',
  13062. 'not null' => TRUE,
  13063. ),
  13064. 'name' => array(
  13065. 'description' => 'TODO: please describe this field!',
  13066. 'type' => 'varchar',
  13067. 'length' => '255',
  13068. 'not null' => TRUE,
  13069. ),
  13070. 'type_id' => array(
  13071. 'description' => 'TODO: please describe this field!',
  13072. 'type' => 'int',
  13073. 'not null' => TRUE,
  13074. ),
  13075. 'synonym_sgml' => array(
  13076. 'description' => 'TODO: please describe this field!',
  13077. 'type' => 'varchar',
  13078. 'length' => '255',
  13079. 'not null' => TRUE,
  13080. ),
  13081. ),
  13082. 'primary key' => array(
  13083. 0 => 'synonym_id',
  13084. ),
  13085. 'unique keys' => array(
  13086. 'synonym_c1' => array(
  13087. 0 => 'name',
  13088. 1 => 'type_id',
  13089. ),
  13090. ),
  13091. 'indexes' => array(
  13092. 'synonym_idx1' => array(
  13093. 0 => 'type_id',
  13094. ),
  13095. ),
  13096. 'foreign keys' => array(
  13097. 'cvterm' => array(
  13098. 'table' => 'cvterm',
  13099. 'columns' => array(
  13100. 'type_id' => 'cvterm_id',
  13101. ),
  13102. ),
  13103. ),
  13104. );
  13105. return $description;
  13106. }
  13107. /**
  13108. * Implements hook_chado_schema_v1_2_tableinfo()
  13109. * Purpose: To describe the structure of 'tableinfo' to tripal
  13110. * @see tripal_core_chado_insert()
  13111. * @see tripal_core_chado_update()
  13112. * @see tripal_core_chado_select()
  13113. *
  13114. * @return
  13115. * An array describing the 'tableinfo' table
  13116. *
  13117. * @ingroup tripal_chado_v1.2_schema_api
  13118. *
  13119. */
  13120. function tripal_core_chado_schema_v1_2_tableinfo() {
  13121. $description = array(
  13122. 'description' => 'TODO: please describe this table!',
  13123. 'fields' => array(
  13124. 'tableinfo_id' => array(
  13125. 'description' => 'TODO: please describe this field!',
  13126. 'type' => 'serial',
  13127. 'not null' => TRUE,
  13128. ),
  13129. 'name' => array(
  13130. 'description' => 'TODO: please describe this field!',
  13131. 'type' => 'varchar',
  13132. 'length' => '30',
  13133. 'not null' => TRUE,
  13134. ),
  13135. 'primary_key_column' => array(
  13136. 'description' => 'TODO: please describe this field!',
  13137. 'type' => 'varchar',
  13138. 'length' => '30',
  13139. 'not null' => FALSE,
  13140. ),
  13141. 'is_view' => array(
  13142. 'description' => 'TODO: please describe this field!',
  13143. 'type' => 'int',
  13144. 'not null' => TRUE,
  13145. 'default' => 0,
  13146. ),
  13147. 'view_on_table_id' => array(
  13148. 'description' => 'TODO: please describe this field!',
  13149. 'type' => 'int',
  13150. 'not null' => FALSE,
  13151. ),
  13152. 'superclass_table_id' => array(
  13153. 'description' => 'TODO: please describe this field!',
  13154. 'type' => 'int',
  13155. 'not null' => FALSE,
  13156. ),
  13157. 'is_updateable' => array(
  13158. 'description' => 'TODO: please describe this field!',
  13159. 'type' => 'int',
  13160. 'not null' => TRUE,
  13161. 'default' => 1,
  13162. ),
  13163. 'modification_date' => array(
  13164. 'description' => 'TODO: please describe this field!',
  13165. 'type' => 'date',
  13166. 'not null' => TRUE,
  13167. 'default' => 'ow(',
  13168. ),
  13169. ),
  13170. 'primary key' => array(
  13171. 0 => 'tableinfo_id',
  13172. ),
  13173. 'unique keys' => array(
  13174. 'tableinfo_c1' => array(
  13175. 0 => 'name',
  13176. ),
  13177. ),
  13178. 'foreign keys' => array(
  13179. ),
  13180. );
  13181. return $description;
  13182. }
  13183. /**
  13184. * Implements hook_chado_schema_v1_2_treatment()
  13185. * Purpose: To describe the structure of 'treatment' to tripal
  13186. * @see tripal_core_chado_insert()
  13187. * @see tripal_core_chado_update()
  13188. * @see tripal_core_chado_select()
  13189. *
  13190. * @return
  13191. * An array describing the 'treatment' table
  13192. *
  13193. * @ingroup tripal_chado_v1.2_schema_api
  13194. *
  13195. */
  13196. function tripal_core_chado_schema_v1_2_treatment() {
  13197. $description = array(
  13198. 'description' => 'TODO: please describe this table!',
  13199. 'fields' => array(
  13200. 'treatment_id' => array(
  13201. 'description' => 'TODO: please describe this field!',
  13202. 'type' => 'serial',
  13203. 'not null' => TRUE,
  13204. ),
  13205. 'rank' => array(
  13206. 'description' => 'TODO: please describe this field!',
  13207. 'type' => 'int',
  13208. 'not null' => TRUE,
  13209. 'default' => 0,
  13210. ),
  13211. 'biomaterial_id' => array(
  13212. 'description' => 'TODO: please describe this field!',
  13213. 'type' => 'int',
  13214. 'not null' => TRUE,
  13215. ),
  13216. 'type_id' => array(
  13217. 'description' => 'TODO: please describe this field!',
  13218. 'type' => 'int',
  13219. 'not null' => TRUE,
  13220. ),
  13221. 'protocol_id' => array(
  13222. 'description' => 'TODO: please describe this field!',
  13223. 'type' => 'int',
  13224. 'not null' => FALSE,
  13225. ),
  13226. 'name' => array(
  13227. 'description' => 'TODO: please describe this field!',
  13228. 'type' => 'text',
  13229. 'not null' => FALSE,
  13230. ),
  13231. ),
  13232. 'primary key' => array(
  13233. 0 => 'treatment_id',
  13234. ),
  13235. 'indexes' => array(
  13236. 'treatment_idx1' => array(
  13237. 0 => 'biomaterial_id',
  13238. ),
  13239. 'treatment_idx2' => array(
  13240. 0 => 'type_id',
  13241. ),
  13242. 'treatment_idx3' => array(
  13243. 0 => 'protocol_id',
  13244. ),
  13245. ),
  13246. 'foreign keys' => array(
  13247. 'cvterm' => array(
  13248. 'table' => 'cvterm',
  13249. 'columns' => array(
  13250. 'type_id' => 'cvterm_id',
  13251. ),
  13252. ),
  13253. 'protocol' => array(
  13254. 'table' => 'protocol',
  13255. 'columns' => array(
  13256. 'protocol_id' => 'protocol_id',
  13257. ),
  13258. ),
  13259. 'biomaterial' => array(
  13260. 'table' => 'biomaterial',
  13261. 'columns' => array(
  13262. 'biomaterial_id' => 'biomaterial_id',
  13263. ),
  13264. ),
  13265. ),
  13266. );
  13267. return $description;
  13268. }