Author |
|
MrGibbage Super User
Joined: October 23 2006 Location: United States
Online Status: Offline Posts: 513
|
Posted: September 24 2012 at 15:43 | IP Logged
|
|
|
It seems that the PowerHome power users here like to use database commands,
rather than the built in functions. I can easily see how that would give a lot
more flexibility. So, where did you all learn about the database contents, field
names, primary keys, foreign keys, etc? I don't see any data dictionaries or
other documentation anywhere. Do I have to be in Dave's circle of trust to have
access to it? :)
__________________ Skip
|
Back to Top |
|
|
MrGibbage Super User
Joined: October 23 2006 Location: United States
Online Status: Offline Posts: 513
|
Posted: October 18 2012 at 13:37 | IP Logged
|
|
|
Dave? Anyone? Please :)
__________________ Skip
|
Back to Top |
|
|
dhoward Admin Group
Joined: June 29 2001 Location: United States
Online Status: Offline Posts: 4447
|
Posted: October 18 2012 at 14:41 | IP Logged
|
|
|
Skip,
The original user manual (available on the downloads page) had an appendix with some database details but it is now woefully outdated. The single biggest thing you'd really to need to know first is SQL. There are a number of sites on the web that will explain SQL. For the most part its generic among databases but each database has its own functions/implementations resulting in minor differences. Obviously, the database SQL dialect you'd want to know is for Sybase Adaptive Server Anywhere.
With a general SQL foundation, it may help to connect to the PH database using a SQL explorer type tool such as Microsoft Access, SQL Query, Toad, etc. so that you can view the structures. The general access userid is ph and the password is ph.
You can glean all the information you need directly within PowerHome using the PH Multi-editor in SQL mode (shift-F5). You can start with SQL statement which will give you a top level of the catalog:
select * from syscatalog
From there, you can see the various system tables which may lead you to run:
select * from systable
and
select * from syscolumn
The owner of all of the PH specific data tables is "powerhome" so you can query/filter on that to see only the PH tables.
Once you have a list of the PH tables, a real easy way to just see the data as well as the column names would be to just run:
select * from phtablename
where phtablename may be macrodetail, timedevents, etc.
You'll definitely want to take care directly modifying data as you can seriously screw with the internal relationships and create orphan data since the runtime version of ASA doesnt allow for triggers or parent/child relationships so PH must manage all of that internally.
This should be a good start to get you going and I can fill in any specifics you may have.
Dave.
|
Back to Top |
|
|
MrGibbage Super User
Joined: October 23 2006 Location: United States
Online Status: Offline Posts: 513
|
Posted: October 18 2012 at 14:47 | IP Logged
|
|
|
Thanks, Dave. I have no problem with SQL. I use it just about every day at
work. What I was really looking for was a description of the tables and
columns. Pretty much the only thing I will be doing is queries--no
writing/deleting, so I don't think I can screw up any relationships or
anything like that.
Anyway, you gave me enough here to get started. Unless you have a good data
dictionary, describing the tables and their relationships, then I can
probably figure it out myself.
__________________ Skip
|
Back to Top |
|
|
MrGibbage Super User
Joined: October 23 2006 Location: United States
Online Status: Offline Posts: 513
|
Posted: November 03 2012 at 09:59 | IP Logged
|
|
|
Anyone know of any FREE sybase database viewers? I'd like to have an offline, external
database viewer that I can use to browse the powerhome db with a gui. A sybase
database viewer is what I need to view the PowerHome database, right? I have been
searching for several days now, and surprisingly I haven't found any that would work.
I use Oracle SQL developer and Toad at work. It would be awesome if there was a way to
make a connection to the pwrhome.db file right through an app like that. Otherwise, a
tool like this sqlite
browser would be just fine.
__________________ Skip
|
Back to Top |
|
|
dhoward Admin Group
Joined: June 29 2001 Location: United States
Online Status: Offline Posts: 4447
|
Posted: November 03 2012 at 11:16 | IP Logged
|
|
|
Skip,
You don't need a viewer specific to Sybase. Any viewer that is able to connect to an ODBC datasource should work. You just need to open the ODBC administrator and add an entry for PowerHome. Once you've done that, you should be able to use anything that supports ODBC.
Dave.
|
Back to Top |
|
|