Name | Modified | Size | Downloads / Week |
---|---|---|---|
Parent folder | |||
infmx2html.4gl | 2020-05-11 | 85.0 kB | |
Readme.txt | 2020-05-11 | 21.2 kB | |
Totals: 2 Items | 106.2 kB | 0 |
#################################################################### # THIS FILE WAS CREATED USING -VI- WITH 132 COLUMNS #################################################################### # PLEASE READ THE WHOLE TEXT BEFORE COMPILING OR USING # # Program: infmx2html.4gl # Author : Tony Kaser # Date : May 26 2000 # Informix Version : 7.22 # Email : akaser@totalwebcreations.com # # # This program is distributed as is and the author assumes no liability for any damages # that may result from it's use. You are free to use, modify, distribute this program # as you like provided this text is included as is. # # If you have any suggestions for enhancements or make any enhancements please email me # at the above email address. Currently I am only making enhancements as I have need/time. # Since I am distributing this as shareware I do not offer any support. I will however # try to read my email and respond if I can. # # Shortly after I released the initial version of this program I receieved requests and # comments from users. I would like to apologize for failing to respond. # # Also, in reading this text again I find I made no mention of the fact that this was based # on the program 'makedic.4gl' by Mario Estrada. Apologizes to Mario. # # The old version of this program I released over 2 years ago was written against an # Informix version 5.0 database # I am currently using infmx2html.4gl against Informix version 7.22.UC2 # # Compiling: c4gl infmx2html.4gl -o infmx2html.4ge # you should not need to link in anything special to get it to compile. # If you wish to use this against other Informix versions you may need to # make modification. # # # Syntax : infmx2html.4ge <-d database_name> <-a> <-p root_path> # OPTIONS # -d database_name : identify the database you wish to build pages for # The heirarchy is the same but will build for only # the database 'database_name' # -a : This option will tell the program to build pages for # ALL databases managed by the server. This is the # DEFAULT and does not need to be specified. # -p root_path : root_path should be a fully qualified path, or a relative # path. DEFAULT is the current directory. This is the top # of the heirarchy (see below). All directories/html pages # will be built under this directory. # NOTE # Options -d and -a are mutually exclusive and will cause the program to abort # if they are but specified. # # # # Comments: Please email comments to the address above. # Please email complaints to /dev/null # # Description: This program creates a large set of files that describe your InformixServer # and all the databases that it manages. # The first page created is a file called 'DBNames.html'. This is created in a # directory which is the name of your InformixServer. This is located under the # current/selected directory. See heirarchy below for directory structure. # # PROCEDURES/TRIGGERS # These pages will create three more frames. # * The first frame is an html table containing a list of the procedures/triggers. # * The second frame there is nothing. This is intentional as it gives a nice # margin between the first frame and the data in the third frame. # * The third frame contains the actual body of the procedure or the trigger. # According to the Informix manuals there are two pieces of interest for a trigger. # * The first is the Header definition. # * The second is the triggered actions. # Procedures/Triggers pages are written out as text files. This is because the database # contains the body in several rows in a char field. This field may contain newlines. # Html would not recognize the newlines and would make it had to read. # Ideally I should build a function to convert all newlines to '<BR>' Tags. # Then I could set up some more linking off the page, like to the tbales. # # Since the site I am currently at does not use triggers, yet, I can not really # do too much with them. # # TABLES # The tables page creates three frames also. # * The first frame is a list of owners of tables in the database and the # number of tables they own. # Each of the owner names is a link. Pressing this link causes an index # to appear in the second frame directly below the first. # * The second frame just shows the alphabet as a set of links. This is # used to navigate the table index. Pressing a letter of the alphabet here # will cause the index of tables to be displayed in the third frame at the # begining of the list of tables that start with that letter. # * The third frame list all the tables owned by the selected owner. These tables # are listed alphabetically and in sections by alphabet. # Selecting a table will cause your browser to open another window that # will contain the table information. This allow you to view multiple tables at # the same time. # The html page that comes up to show the table information is broken up into three # Html tables # * The first table lists all the indexes for the table and what they are # comprised of and whether or not they are unique or duplicate indexes. # * The second table lists the parent tables and child tables if it can # determine them. These are determined from the syscontraints table and the # sysreferences table. If there is a better way please change it. I would # appreciate an email from anyone making changes so that I can update my version. # * The third table is optional and may not be created, this depends on whether or # not you store your Data Dictionary in the database. If the table 'tabdefs' is # found (see cursor td_curs in the PrepSqls() function) a table will be created # which will contain a description of your database. # * The third table is the actual table definition/scheme. # All datatypes on in the scheme are linked to an html page that when selected # will apear to give you some general information about that datatype. # Once again if you store your data dictionary in the database a column will be # added to the columns definitions table that will describe the column. This should # be stored in a table called 'coldefs' (see cursor cd_curs in the PrepSqls() function) # # This is an incomplete project. # Still To Do List: # 1: Build a set of pages showing # a. Synonyms and their definitions # b. Any dependancies # c. Blob Definitions # My current site does not employ most of these features. So I can # not really do anything with them since I cannot test them. # # 2: Needing more work is GetField(), which when given a qualifier for a # Datetime/Interval returns a field definition. This function is as per the # Reference manual dated 1991, and even my database has fields that are not # defined in there, such as minute(3), minute(4) and so on. Currently this # function will return minute for either of these. # # 3: Revisit the Parent/Child Table lookup and if there is a better way maybe someone # could enhance it. # # 4: Revisit the Reformat Function and add support for procedures and triggers as well. # This would allow links from within those pages to the tables being used. # # What should you do: # Create an html page however you like, containing names/links to each of the servers. # Since infmx2html.4ge can only work with the current server, if you have more than one # that you are running and building pages for you should have a toplevel page that # would be located in the 'root_directory' and allows you to easily get to each of the # Servers. # # So What Do You Get: A whole lotta html Pages. # # Basically when you run it you will get an entire # Web site dedicated to describing your Informix Server. # # # HEIRARCHY # <RootDirectory>/ # | # | <ServerPage.html> You should build this page # | | # | |->ServerName----------| # | | # | BlankPage.html | # | | # | InfmxTypes.html<------------+---------------------| # | | | | # | |->DataType | | # | |->Description | | # | |->ValidValues | | # | |->Aliases | | # | | | # |-><ServerName>/ | | # | | | # | DBNames.html<---------------| | # | | | # | |->ServerName ----------| | # | |->Database------------------| | # | |->Owner | | | # | |->DateCreated | | | # | |->Logging | | | # | |->ANSI Compliant? | | | # | |->NLS Enabled? | | | # | |->Read Only? | | | # | | | | # | | | | # | | | | # | Config.html<----------------| | | # | | | | # | |>Parameter | | # | |>Original Value | | # | |>Current Value | | # | |>Default Value | | # | | | # |->Databases/ | | # | | | # V | | # /<DatabaseName> | | # | | | # | Database.html <----------------| | # | | | # | |->Procedures------| | # | |->Triggers--------+------| | # | |->Tables----------+------+-----| | # | |->Views | | | | # | | | | | # | | | | | # | ProcIndex.html <------| | | | # | | | | | # | |->ProcName ------------| | | | # | |->ProcOwner | | | | # | |->ProcId | | | | # | |->ProcMode | | | | # | |->ProcArgCnt | | | | # | | | | | # | | | | | # | TrigIndex.html<-----------+--| | | # | | | | | # | |->TrigName-------------+-----| | | # | |->TrigOwner | | | | # | |->TrigId | | | | # | |->TrigTable------------+-----+------| | # | |->TrigEvent | | | | | # | |->TrigOld | | | | | # | |->TrigNew | | | | | # | |->Mode | | | | | # | | | | | | # | Views.html | | | | | # | | | | | | | # | |->ViewName-------------+-----+--+---+--| | # | |->Owner | | | | | | # | | | | | | | # | | | | | | | # | Tables.html<--------------+-----+--| | | | # | OwnerList.html | | | | | # | | | | | | | # | |->TableOwner-------| | | | | | # | |->TableCount | | | | | | # | | | | | | | # | | | | | | | # | <Owner>TableIndex.html<-| | | | | | # | | | | | | | # | |->TableName----+-----+---| | | | # | | | | | | | # | | | | | | | # | | | | | | | # |->Procedures/ | | | | | | # | | | | | | | # | <Owner><ProcName>.txt<--| | | | | | # | | | | | | | # | |->ProcName | | | | | # | |->ProcOwner | | | | | # | |->ProcId | | | | | # | |->ProcBody | | | | | # | | | | | | # |->Triggers/ | | | | | # | | | | | | # | <Owner><TrigName>.txt <-----| | | | | # | | | | | | # | |->TrigName | | | | # | |->TrigOwner | | | | # | |->TrigId | | | | # | |->TrigTable | | | | # | |->TrigBody | | | | # | | | | | # |->Views/ | | | | # | | | | | # | <Owner><ViewName>.html<---------+--+--| | # | | | | | # | |->ViewName | | | # | |->Owner | | | # | |->CreateStatement---------| | | | # | | | | | # | | | | | # | | | | | # | | | | | # |->Tables/ | | | | # | | | | # <Owner>-<TabName>.html<-----|<-|<-|<-|<-| | # | | | | # | | | | # |->ParentTables--------------------| | | # |->ChildTable-------------------------| | # | | # |->UniqueIndexes | # |->DuplicateIndexes | # | | # |-><Table Definitions If Found> | # | | # |->ColNo | # |->ColName | # |->ColType-------------------------------| # |->ColDetail # |->ColLength # |->ColScale # |->ColNullsAllowed # |-><column Definition If Found> # # # # It will create all necessary Sub-Directorys as needed. # # # July 8 2002. Added check text to ownerTable.html pages to display text associated to a row or table level CHECK. # Tony Kaser Added linking from parent/child table names to the actual table being referenced. # Corrected problems with datatype length and scale. # Corrected display of default values for numeric datatypes. # This version is currently running with version 7.22 Informix Online. # # July 11 2002.Corrected a problem with the triggers index page. - I had not properly terminated a <TD> field # Tony Kaser Changed the headings of the tables in the 'ownerTables.html' pagers to better indicate what # Data is contained in the htmlTable. # # July 15 2002.Added Functionality to allow program to build html pages for ALL the databases that you might # Tony Kaser have. User can, from the command line, select an individual database to build for. # System will now build for ALL databases except the sysmaster database, # User can now specify an HtmlRoot Directory to build the pages into. # Added check to see if tables 'tabdefs' and/or 'coldefs' exist. If they exist table pages will # Contain table definitions and/or column definitions when present. # See Cursors td_curs and cd_curs in PrepSqls for more information on these tables. # # July 18 2002.Corrected the above documentation. # Tony Kaser # # July 22 2002.Added support for Views. Views are being reformatted into html pages allowing links # Tony Kaser to the table(s) that they are created from. This is not perfect but it does work here. #