Download presentation
Presentation is loading. Please wait.
Published byPriscilla Lindsey Dean Modified over 9 years ago
1
Stanford Linear Accelerator Center Epics.db to Oracle RDB Organizing site-wide Epics data Ron Chestnut – SNS November 2000
2
Three steps from.db to Oracle Generate a database report Import the report with Sqlload Parse the names to get individual fields Used at SLAC for compatibility with legacy control system wildcarding capabilities
3
Generating the report (1) bic_template file./bic_bxbcm.db { {STN=HB60,BIT3_CARD=0} {STN=LB60,BIT3_CARD=1} } file./bic_dcct.db { {STN=HB60}{STN=LB60} } etc.
4
Generating the report (2) bic_report script rm bic.all_pv dbLoadTemplate bic_template | dbreport OUT.INP.35 DESC.20 | sort > bic.all_pv
5
Import the data with SQLLOAD Script sqlloader acct/pwd control=pvload.ctl Control file options(skip=2) load data infile ‘bic.all_pv’ append into table pvlist when pv_type != “TYPE “ (pv_type position(1:15) char, pvnam position(16:45) char)
6
Parse the names into fields pvnam = PB60:DCCT:LIFETIME fld1 = PB60 fld2 = DCCT fld3 = LIFETIME nfld = 3
7
End up with nice table SQL>desc pvlist name type ========================= PV_TYPEchar(15) PVNAMchar(30) PV_INOUTchar(35) PV_DESCchar(20) FLD1char(15) …. FLD6char(15) NFLDnumber(1) pv_last_fieldchar(15) SQL> select count(*) from pvlist; COUNT(*) ---------------- 16932
8
Current Uses at SLAC Support wildcarded history source files Generate filtered and sorted reports with simple SQL Provide a uniform way to find PV names Reduce maintenance load
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.