Re: HSQLDB: Wie Struktur dokumentieren?
Wolfgang Schaible <[email protected]>
| Newsgroups | gmane.comp.openoffice.dba.user |
|---|---|
| Organization | atHome |
| Message-ID | <[email protected]> |
hallo Marc, Am Samstag 17 September 2005 15.49 schrieb Marc Santhoff: > Am Samstag, den 17.09.2005, 14:17 +0200 schrieb Wolfgang Schaible: > did you select the wrong list address or the wrong language? ;) on the first glance the wrong list address, but then -because there is your answer- the wrong language :-)) Subject in 'the' language: How to document a DB structure? (Tables, Columns, Fields, Types, Length, isAuto, isRequired, Relations, ...) my first try: > > 'HSQLDB: unusable: shows also deleted DBs and Cols ! >> > > sub showDBstruct > > Dim oTables as Object, oMetaDta as Object, oCols as > > Object Dim mTablesNames, mColNames, s1, s2, s3, i, j > > oTables =oDtaSrc.Tables() > > 'xRay.Xray oDtaSrc 'oTables > > mTablesNames=oTables.getElementNames() > > for i=LBound(mTablesNames) to UBound(mTablesNames) > > s1=s1+">"+mTablesNames(i)+"<"+chr(13) > > ' oMetaDta=oDtaSrc.getMetaData() 'unimplemented? > > oCols=oDtaSrc.Tables(i).columns > > mColNames=oCols.getElementNames() > > for j=LBound(mColNames) to UBound(mColNames) > > s3=s3+mColNames(j)+chr(13) > > next j > > next i > > msgbox (s1, 66, "TableNames") > > msgbox (s3, 66, "ColumnNames") > > end Sub 'showDBstruct > This works fine using DBase or MySQL databases for me (tried > creating and deleting a table in mysql, it is *not* listed after > deletion), so I would blame the HSQLDB implementation somewhere > in the OO.o driver, the jdbc driver or the database itself. it's not easy to work with OOo-HSQLDB: -Docu: same is said in JDK for Java, nearly nothing using Basic -Documented methods do simply not work (see above) -No examples > I'd use another approach: making the design using a tool better > fitting the task could be helpfull. Dia would be a oss candidate > for this one ... ok, but now I should made the 'as is' docu, sometimes this differs from design... :-) and manually created 'as is' docu differs from reality too <> > Maybe you have to run a pruging finction or the like as in DBase > to get rid of deleted stuff completely? no idea, don't know a purging function Greetings Wolfgang