From f6c9088e16c4c083174dd1130ae58d213923cdef Mon Sep 17 00:00:00 2001 From: ivan Date: Tue, 15 Jul 2003 11:45:14 +0000 Subject: import of sql-ledger 2.0.8 --- sql-ledger/doc/COPYING | 355 ++++++++++++++++++ sql-ledger/doc/README | 287 ++++++++++++++ sql-ledger/doc/UPGRADE-1.6-1.8 | 61 +++ sql-ledger/doc/UPGRADE-1.8-1.8.3 | 23 ++ sql-ledger/doc/UPGRADE-1.8.3-1.8.4 | 10 + sql-ledger/doc/UPGRADE-1.8.4-1.8.5 | 18 + sql-ledger/doc/UPGRADE-1.8.5-1.8.7 | 6 + sql-ledger/doc/UPGRADE-1.8.7-2.0.0 | 20 + sql-ledger/doc/UPGRADE-2.0-2.0.8 | 8 + sql-ledger/doc/copyright | 23 ++ sql-ledger/doc/faq.html | 747 +++++++++++++++++++++++++++++++++++++ 11 files changed, 1558 insertions(+) create mode 100644 sql-ledger/doc/COPYING create mode 100644 sql-ledger/doc/README create mode 100644 sql-ledger/doc/UPGRADE-1.6-1.8 create mode 100644 sql-ledger/doc/UPGRADE-1.8-1.8.3 create mode 100644 sql-ledger/doc/UPGRADE-1.8.3-1.8.4 create mode 100644 sql-ledger/doc/UPGRADE-1.8.4-1.8.5 create mode 100644 sql-ledger/doc/UPGRADE-1.8.5-1.8.7 create mode 100644 sql-ledger/doc/UPGRADE-1.8.7-2.0.0 create mode 100644 sql-ledger/doc/UPGRADE-2.0-2.0.8 create mode 100644 sql-ledger/doc/copyright create mode 100644 sql-ledger/doc/faq.html (limited to 'sql-ledger/doc') diff --git a/sql-ledger/doc/COPYING b/sql-ledger/doc/COPYING new file mode 100644 index 000000000..083bb4150 --- /dev/null +++ b/sql-ledger/doc/COPYING @@ -0,0 +1,355 @@ + + + +GNU General Public License + + + + + +
+                    GNU GENERAL PUBLIC LICENSE
+                       Version 2, June 1991
+
+ Copyright (C) 1989, 1991 Free Software Foundation, Inc.
+ 675 Mass Ave, Cambridge, MA 02139, USA
+
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+
+                            Preamble
+
+  The licenses for most software are designed to take away your
+freedom to share and change it.  By contrast, the GNU General Public
+License is intended to guarantee your freedom to share and change free
+software--to make sure the software is free for all its users.  This
+General Public License applies to most of the Free Software
+Foundation's software and to any other program whose authors commit to
+using it.  (Some other Free Software Foundation software is covered by
+the GNU Library General Public License instead.)  You can apply it to
+your programs, too.
+
+  When we speak of free software, we are referring to freedom, not
+price.  Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+this service if you wish), that you receive source code or can get it
+if you want it, that you can change the software or use pieces of it
+in new free programs; and that you know you can do these things.
+
+  To protect your rights, we need to make restrictions that forbid
+anyone to deny you these rights or to ask you to surrender the rights.
+These restrictions translate to certain responsibilities for you if you
+distribute copies of the software, or if you modify it.
+
+  For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must give the recipients all the rights that
+you have.  You must make sure that they, too, receive or can get the
+source code.  And you must show them these terms so they know their
+rights.
+
+  We protect your rights with two steps: (1) copyright the software, and
+(2) offer you this license which gives you legal permission to copy,
+distribute and/or modify the software.
+
+  Also, for each author's protection and ours, we want to make certain
+that everyone understands that there is no warranty for this free
+software.  If the software is modified by someone else and passed on, we
+want its recipients to know that what they have is not the original, so
+that any problems introduced by others will not reflect on the original
+authors' reputations.
+
+  Finally, any free program is threatened constantly by software
+patents.  We wish to avoid the danger that redistributors of a free
+program will individually obtain patent licenses, in effect making the
+program proprietary.  To prevent this, we have made it clear that any
+patent must be licensed for everyone's free use or not licensed at all.
+
+  The precise terms and conditions for copying, distribution and
+modification follow.
+
+                    GNU GENERAL PUBLIC LICENSE
+   TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
+
+  0. This License applies to any program or other work which contains
+a notice placed by the copyright holder saying it may be distributed
+under the terms of this General Public License.  The "Program", below,
+refers to any such program or work, and a "work based on the Program"
+means either the Program or any derivative work under copyright law:
+that is to say, a work containing the Program or a portion of it,
+either verbatim or with modifications and/or translated into another
+language.  (Hereinafter, translation is included without limitation in
+the term "modification".)  Each licensee is addressed as "you".
+
+Activities other than copying, distribution and modification are not
+covered by this License; they are outside its scope.  The act of
+running the Program is not restricted, and the output from the Program
+is covered only if its contents constitute a work based on the
+Program (independent of having been made by running the Program).
+Whether that is true depends on what the Program does.
+
+  1. You may copy and distribute verbatim copies of the Program's
+source code as you receive it, in any medium, provided that you
+conspicuously and appropriately publish on each copy an appropriate
+copyright notice and disclaimer of warranty; keep intact all the
+notices that refer to this License and to the absence of any warranty;
+and give any other recipients of the Program a copy of this License
+along with the Program.
+
+You may charge a fee for the physical act of transferring a copy, and
+you may at your option offer warranty protection in exchange for a fee.
+
+  2. You may modify your copy or copies of the Program or any portion
+of it, thus forming a work based on the Program, and copy and
+distribute such modifications or work under the terms of Section 1
+above, provided that you also meet all of these conditions:
+
+    a) You must cause the modified files to carry prominent notices
+    stating that you changed the files and the date of any change.
+
+    b) You must cause any work that you distribute or publish, that in
+    whole or in part contains or is derived from the Program or any
+    part thereof, to be licensed as a whole at no charge to all third
+    parties under the terms of this License.
+
+    c) If the modified program normally reads commands interactively
+    when run, you must cause it, when started running for such
+    interactive use in the most ordinary way, to print or display an
+    announcement including an appropriate copyright notice and a
+    notice that there is no warranty (or else, saying that you provide
+    a warranty) and that users may redistribute the program under
+    these conditions, and telling the user how to view a copy of this
+    License.  (Exception: if the Program itself is interactive but
+    does not normally print such an announcement, your work based on
+    the Program is not required to print an announcement.)
+
+These requirements apply to the modified work as a whole.  If
+identifiable sections of that work are not derived from the Program,
+and can be reasonably considered independent and separate works in
+themselves, then this License, and its terms, do not apply to those
+sections when you distribute them as separate works.  But when you
+distribute the same sections as part of a whole which is a work based
+on the Program, the distribution of the whole must be on the terms of
+this License, whose permissions for other licensees extend to the
+entire whole, and thus to each and every part regardless of who wrote it.
+
+Thus, it is not the intent of this section to claim rights or contest
+your rights to work written entirely by you; rather, the intent is to
+exercise the right to control the distribution of derivative or
+collective works based on the Program.
+
+In addition, mere aggregation of another work not based on the Program
+with the Program (or with a work based on the Program) on a volume of
+a storage or distribution medium does not bring the other work under
+the scope of this License.
+
+  3. You may copy and distribute the Program (or a work based on it,
+under Section 2) in object code or executable form under the terms of
+Sections 1 and 2 above provided that you also do one of the following:
+
+    a) Accompany it with the complete corresponding machine-readable
+    source code, which must be distributed under the terms of Sections
+    1 and 2 above on a medium customarily used for software interchange; or,
+
+    b) Accompany it with a written offer, valid for at least three
+    years, to give any third party, for a charge no more than your
+    cost of physically performing source distribution, a complete
+    machine-readable copy of the corresponding source code, to be
+    distributed under the terms of Sections 1 and 2 above on a medium
+    customarily used for software interchange; or,
+
+    c) Accompany it with the information you received as to the offer
+    to distribute corresponding source code.  (This alternative is
+    allowed only for noncommercial distribution and only if you
+    received the program in object code or executable form with such
+    an offer, in accord with Subsection b above.)
+
+The source code for a work means the preferred form of the work for
+making modifications to it.  For an executable work, complete source
+code means all the source code for all modules it contains, plus any
+associated interface definition files, plus the scripts used to
+control compilation and installation of the executable.  However, as a
+special exception, the source code distributed need not include
+anything that is normally distributed (in either source or binary
+form) with the major components (compiler, kernel, and so on) of the
+operating system on which the executable runs, unless that component
+itself accompanies the executable.
+
+If distribution of executable or object code is made by offering
+access to copy from a designated place, then offering equivalent
+access to copy the source code from the same place counts as
+distribution of the source code, even though third parties are not
+compelled to copy the source along with the object code.
+
+  4. You may not copy, modify, sublicense, or distribute the Program
+except as expressly provided under this License.  Any attempt
+otherwise to copy, modify, sublicense or distribute the Program is
+void, and will automatically terminate your rights under this License.
+However, parties who have received copies, or rights, from you under
+this License will not have their licenses terminated so long as such
+parties remain in full compliance.
+
+  5. You are not required to accept this License, since you have not
+signed it.  However, nothing else grants you permission to modify or
+distribute the Program or its derivative works.  These actions are
+prohibited by law if you do not accept this License.  Therefore, by
+modifying or distributing the Program (or any work based on the
+Program), you indicate your acceptance of this License to do so, and
+all its terms and conditions for copying, distributing or modifying
+the Program or works based on it.
+
+  6. Each time you redistribute the Program (or any work based on the
+Program), the recipient automatically receives a license from the
+original licensor to copy, distribute or modify the Program subject to
+these terms and conditions.  You may not impose any further
+restrictions on the recipients' exercise of the rights granted herein.
+You are not responsible for enforcing compliance by third parties to
+this License.
+
+  7. If, as a consequence of a court judgment or allegation of patent
+infringement or for any other reason (not limited to patent issues),
+conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License.  If you cannot
+distribute so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you
+may not distribute the Program at all.  For example, if a patent
+license would not permit royalty-free redistribution of the Program by
+all those who receive copies directly or indirectly through you, then
+the only way you could satisfy both it and this License would be to
+refrain entirely from distribution of the Program.
+
+If any portion of this section is held invalid or unenforceable under
+any particular circumstance, the balance of the section is intended to
+apply and the section as a whole is intended to apply in other
+circumstances.
+
+It is not the purpose of this section to induce you to infringe any
+patents or other property right claims or to contest validity of any
+such claims; this section has the sole purpose of protecting the
+integrity of the free software distribution system, which is
+implemented by public license practices.  Many people have made
+generous contributions to the wide range of software distributed
+through that system in reliance on consistent application of that
+system; it is up to the author/donor to decide if he or she is willing
+to distribute software through any other system and a licensee cannot
+impose that choice.
+
+This section is intended to make thoroughly clear what is believed to
+be a consequence of the rest of this License.
+
+  8. If the distribution and/or use of the Program is restricted in
+certain countries either by patents or by copyrighted interfaces, the
+original copyright holder who places the Program under this License
+may add an explicit geographical distribution limitation excluding
+those countries, so that distribution is permitted only in or among
+countries not thus excluded.  In such case, this License incorporates
+the limitation as if written in the body of this License.
+
+  9. The Free Software Foundation may publish revised and/or new versions
+of the General Public License from time to time.  Such new versions will
+be similar in spirit to the present version, but may differ in detail to
+address new problems or concerns.
+
+Each version is given a distinguishing version number.  If the Program
+specifies a version number of this License which applies to it and "any
+later version", you have the option of following the terms and conditions
+either of that version or of any later version published by the Free
+Software Foundation.  If the Program does not specify a version number of
+this License, you may choose any version ever published by the Free Software
+Foundation.
+
+  10. If you wish to incorporate parts of the Program into other free
+programs whose distribution conditions are different, write to the author
+to ask for permission.  For software which is copyrighted by the Free
+Software Foundation, write to the Free Software Foundation; we sometimes
+make exceptions for this.  Our decision will be guided by the two goals
+of preserving the free status of all derivatives of our free software and
+of promoting the sharing and reuse of software generally.
+
+                            NO WARRANTY
+
+  11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
+FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW.  EXCEPT WHEN
+OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
+PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
+OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.  THE ENTIRE RISK AS
+TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU.  SHOULD THE
+PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
+REPAIR OR CORRECTION.
+
+  12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
+REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
+INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
+OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
+TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
+YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
+PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGES.
+
+                     END OF TERMS AND CONDITIONS
+        Appendix: How to Apply These Terms to Your New Programs
+
+  If you develop a new program, and you want it to be of the greatest
+possible use to the public, the best way to achieve this is to make it
+free software which everyone can redistribute and change under these terms.
+
+  To do so, attach the following notices to the program.  It is safest
+to attach them to the start of each source file to most effectively
+convey the exclusion of warranty; and each file should have at least
+the "copyright" line and a pointer to where the full notice is found.
+
+    <one line to give the program's name and a brief idea of what it does.>
+    Copyright (C) 19yy  <name of author>
+
+    This program is free software; you can redistribute it and/or modify
+    it under the terms of the GNU General Public License as published by
+    the Free Software Foundation; either version 2 of the License, or
+    (at your option) any later version.
+
+    This program is distributed in the hope that it will be useful,
+    but WITHOUT ANY WARRANTY; without even the implied warranty of
+    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+    GNU General Public License for more details.
+
+    You should have received a copy of the GNU General Public License
+    along with this program; if not, write to the Free Software
+    Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+
+Also add information on how to contact you by electronic and paper mail.
+
+If the program is interactive, make it output a short notice like this
+when it starts in an interactive mode:
+
+    Gnomovision version 69, Copyright (C) 19yy name of author
+    Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
+    This is free software, and you are welcome to redistribute it
+    under certain conditions; type `show c' for details.
+
+The hypothetical commands `show w' and `show c' should show the appropriate
+parts of the General Public License.  Of course, the commands you use may
+be called something other than `show w' and `show c'; they could even be
+mouse-clicks or menu items--whatever suits your program.
+
+You should also get your employer (if you work as a programmer) or your
+school, if any, to sign a "copyright disclaimer" for the program, if
+necessary.  Here is a sample; alter the names:
+
+  Yoyodyne, Inc., hereby disclaims all copyright interest in the program
+  `Gnomovision' (which makes passes at compilers) written by James Hacker.
+
+  <signature of Ty Coon>, 1 April 1989
+  Ty Coon, President of Vice
+
+This General Public License does not permit incorporating your program into
+proprietary programs.  If your program is a subroutine library, you may
+consider it more useful to permit linking proprietary applications with the
+library.  If this is what you want to do, use the GNU Library General
+Public License instead of this License.
+
+
+
+
+
diff --git a/sql-ledger/doc/README b/sql-ledger/doc/README
new file mode 100644
index 000000000..7585f5357
--- /dev/null
+++ b/sql-ledger/doc/README
@@ -0,0 +1,287 @@
+                SQL-Ledger Accounting
+                     Version 2.0
+
+
+DESCRIPTION:
+------------
+SQL-Ledger is a double-entry accounting program written
+in perl. It has been tested with PostgreSQL, Oracle,
+Apache, Netscape, Mozilla, Galeon, Explorer, Links, Lynx,
+Konqueror, Voyager, W3M and Opera clients on Linux, FreeBSD,
+Solaris, Windows and Mac computers.
+
+Data is stored in a SQL server, either locally or remote,
+the display is through a text or GUI web browser. The system
+is linked by a chart of accounts.  All transactions for AR,
+AP and GL are stored in a transaction table. Hyper-links
+from the chart of accounts let you view transactions posted
+through AR, AP and GL.
+
+Configuration files let you specify to which SQL server
+to connect to, personal preferences such as company name,
+language, number and date format, etc.
+
+The admin script can be used to create, edit or delete users
+and to create and delete datasets and to setup the Chart
+of Accounts and templates needed for the system.
+It can be used for PostgreSQL and Oracle. If you want to
+use another SQL server the tables and chart of accounts
+must be created by hand.
+
+You can have a group of users using the same dataset and
+templates for generating Invoices, Income Statements and
+Balance Sheets or a different set altogether.
+
+Templates are supplied in html and tex format to generate
+most of the forms. Forms can be printed to screen, sent
+to a printer or to a mailer agent. To use the tex forms
+latex must be installed. Most systems have a latex binary
+installed by default. Latex is also available for Windows
+and the Mac so we stay compatible across all major platforms.
+
+
+COPYRIGHT:
+----------
+You may distribute under the terms of the GNU License.
+
+
+LATEST VERSION:
+---------------
+available from http://www.sql-ledger.org
+
+
+PLATFORMS:
+----------
+Non specific, see requirements.
+
+
+REQUIREMENTS:
+-------------
+1 - Perl, 5+
+2 - http server (Apache, NCSA, httpi, ...)
+3 - SQL Server with transaction support (PostgreSQL 7.0+, Oracle)
+4 - DBD (DBD-Pg, DBD-Oracle)
+5 - DBI
+6 - LaTeX (optional)
+
+
+FOREIGN LANGUAGE SUPPORT:
+-------------------------
+All the required files are in locale/country_code
+The main files are 'all' and 'missing'. You can enter
+translated strings in either file. When you are done
+run locales.pl from the command line to rebuild the
+required files.
+
+Some of the translation files are not 100% complete.
+If strings are missing, English is used instead.
+
+
+INSTALLATION:
+-------------
+unpack the tar.gz file in /usr/local
+
+  tar xzvf sql-ledger-x.x.x.tar.gz
+
+you should now have everything in /usr/local/sql-ledger
+
+copy sql-ledger.conf.default to sql-ledger.conf
+
+edit sql-ledger.conf
+
+create a file sql-ledger-httpd.conf in the same location
+where your httpd.conf is and copy the next section into the file
+
+  Alias /sql-ledger/ /usr/local/sql-ledger/
+  
+    AddHandler cgi-script .pl
+    Options ExecCGI Includes FollowSymlinks
+  
+
+  
+    Order Deny,Allow
+    Deny from All
+  
+
+edit httpd.conf and add
+
+  # SQL-Ledger
+  Include /sql-ledger-httpd.conf
+
+Note: Replace  with the server's root directory!
+
+restart your web server.
+
+
+Note: /usr/local/sql-ledger is only a suggested
+path, you can install in any directory.
+
+
+INSTALLATION WITH setup.pl:
+---------------------------
+Make a directory
+
+  mkdir /usr/local/sql-ledger
+
+Copy setup.pl to /usr/local/sql-ledger
+
+run setup.pl as root and follow the prompts.
+
+Go to the next step, "PREPARE YOUR SQL SERVER".
+
+
+SET PERMISSION:
+---------------
+change directory to /usr/local/sql-ledger
+
+# chown nobody:nobody users templates
+
+replace nobody:nobody with the web server
+user of your system. Some systems use
+apache:apache, www, www-data, ...
+
+
+PREPARE YOUR SQL SERVER:
+------------------------
+
+  PostgreSQL:
+  -----------
+  add one database user with create database privileges
+  to manage the datasets and tables for SQL-Ledger
+  
+  # su postgres
+  $ createuser -d sql-ledger
+  
+  if you use passwords to access postgres set the user up with a password 
+  $ createuser -d -P sql-ledger
+
+  Answer no to the following question.
+  Shall the new user be allowed to create more new users? (y/n) n
+
+  You can add more database users to keep datasets
+  separated. Each dataset belongs to one company.
+  
+  
+  ORACLE:
+  -------
+  add one user and one tablespace
+  all datasets share the same tablespace
+  
+
+SETUP A DATABASE AND THE TABLES:
+--------------------------------
+Load your web browser and connect to
+http://localhost/sql-ledger/admin.pl
+
+Tables are created with the "Database
+Administration" function.
+
+Select the "Database Administration" link,
+enter a host, port and user you created in the
+previous step.
+
+The "Create Dataset" link queries the server
+for existing datasets and displays them in a
+column. Then you enter a name for the new
+dataset and select one of the Chart of Accounts
+and click on Continue.
+Your new dataset and the tables will be created
+and the selected Chart of Accounts loaded. The
+owner of the tables is the user you entered in
+the previous screen.
+
+NOTE: Be patient, some of the charts are really
+big and take some time to create.
+
+The "Delete Dataset" link queries the server
+for datasets which are in use by SQL-Ledger
+and are not used by any members. This may
+take a while to figure out. "Be patient".
+If there are any datasets not in use, you get
+a screen with the datasets listed where you
+can select the one you want to delete.
+
+NOTE: you cannot manage any other datasets
+from this interface, only the datasets used
+by SQL-Ledger.
+
+
+SETUP A USER:
+-------------
+Load your web browser and connect to
+http://localhost/sql-ledger/admin.pl
+
+Click on "Add User". In the Database
+section select the driver and enter
+the user you used to create the dataset.
+
+
+LOAD THE ACCOUNTING PROGRAM:
+----------------------------
+Load your web browser and connect to
+http://localhost/sql-ledger/login.pl
+
+
+UPGRADING TO A NEWER VERSION:
+-----------------------------
+1. unpack the new version over top
+2. check the doc directory for specific notes
+3. load admin.pl
+   click on "Database Administration"
+   enter the dba in the "Connect to" field
+   click on "Update Dataset"
+   select the datasets and click "Continue"
+
+
+UPGRADING WITH setup.pl:
+------------------------
+run setup.pl from the command line and follow
+the prompts.
+
+
+INSTALLATION CHECKLIST:
+-----------------------
+1. untar SL somewhere
+2. change permissions for the users and templates directory
+3. edit httpd.conf
+4. edit sql-ledger.conf
+5. a) add the database user sql-ledger in PostgreSQL
+   b) add a tablespace and the database user sql-ledger in Oracle
+6. load admin.pl
+7. create datasets for the companies
+8. add users
+
+   In the Database section enter
+   
+   a) PostgreSQL
+   
+      Host:     for local connections leave empty
+      Dataset:  the dataset created in step 7
+      Port:     for local connections leave empty
+      User:     sql-ledger
+      Password: password for sql-ledger
+      
+   b) Oracle
+   
+      SID:      system ID
+      Port:     the port Oracle is listening on
+      Dataset:  the dataset created in step 7
+      Password: password for connection
+   
+
+IF SOMETHING DOESN'T WORK:
+--------------------------
+There is a FAQ online which addresses various questions.
+see http://www.sql-ledger.org/misc/faq.html
+
+There are also several mailing lists at
+http://www.sql-ledger.org/misc/mailinglist.html
+where you can go for help.
+
+If you require support you can order online at
+http://www.sql-ledger.com/misc/support.html
+
+
+=====================================================================
+December 4, 2002
+
diff --git a/sql-ledger/doc/UPGRADE-1.6-1.8 b/sql-ledger/doc/UPGRADE-1.6-1.8
new file mode 100644
index 000000000..b5631b283
--- /dev/null
+++ b/sql-ledger/doc/UPGRADE-1.6-1.8
@@ -0,0 +1,61 @@
+Upgrading from version 1.6 to 1.8
+
+1. make a backup copy of your databases and SQL-Ledger, just in case!
+   $ cd /usr/local/www/sql-ledger
+   $ pg_dump database > db.out
+   $ tar cvf ~/sql-ledger.tar .
+   
+2. install SQL-Ledger over top of your old installation
+   $ cd /usr/local/www
+   $ tar zxvf sql-ledger-1.8.0.tar.gz
+   
+3. change the tables to the new layout
+   $ cd sql-ledger/sql
+   $ psql database < upgrade-1.6-1.8.sql
+
+4. copy the new master templates to your template directory
+   $ cd ../templates
+
+   $ cp Default-email_purchase_order.html your_template_dir/email_purchase_order.html
+   $ cp Default-purchase_order.html your_template_dir/purchase_order.html
+   $ cp Default-email_sales_order.html your_template_dir/email_sales_order.html
+   $ cp Default-sales_order.html your_template_dir/sales_order.html
+ 
+5. Two new accounts were hopefully added to your chart of accounts
+   One account for Foreign Exchange Gains and one for
+   Foreign Exchange Losses
+   edit and change to suit your COA. You can safely change
+   the account number too.
+      
+6. Edit your preferences
+
+   In field 'Stylesheet' enter -> sql-ledger.css
+   Stylesheet is in the css directory
+
+   Add your foreign currencies in the Currencies field
+   The first currency in the list is your default
+   i.e CDN:USD:EUR:YEN
+   If you used a nativecurr than it should be listed in the
+   new currencies field.
+
+7. <%nativecurr%> has changed to <%currency%>
+   edit all your templates and change nativecurr to currency
+
+8. I also added four more variables which can be used in your templates.
+   <%contact%>, <%shiptocontact%>, <%shiptophone%>, <%shiptofax%>
+   
+9. Nameing convention for templates has changed from an
+   underscore to a minus sign. If you designed your own
+   master templates rename the templates from
+   industry_invoice.html to industry-invoice.html,
+   industry_packing_list.html to industry-packing_list.html, etc.
+   The minus sign is used to separate the name and list them in
+   the setup screen.
+   
+   This change only applies to the master templates in the
+   templates root directory NOT the individual templates which
+   are used by users.
+
+It looks more than it really is. Steps 1 to 4 are important,
+the rest is for fine tuning and info.
+
diff --git a/sql-ledger/doc/UPGRADE-1.8-1.8.3 b/sql-ledger/doc/UPGRADE-1.8-1.8.3
new file mode 100644
index 000000000..babed3793
--- /dev/null
+++ b/sql-ledger/doc/UPGRADE-1.8-1.8.3
@@ -0,0 +1,23 @@
+Upgrading from version 1.8.(0-2) to 1.8.3
+
+1. install SQL-Ledger over top of your old installation
+   $ cd /usr/local
+   $ tar zxvf sql-ledger-1.8.3.tar.gz
+
+2. copy sql-ledger.conf.default to sql-ledger.conf
+   $ cp sql-ledger.conf.default sql-ledger.conf
+
+   if you modified sql-ledger.conf merge the changes from the
+   .default file rather than copying over top.
+
+3. copy the new master templates to your template directory
+   $ cd ../templates
+
+   $ cp Default-invoice.tex your_template_dir/invoice.tex
+   $ cp Default-packing_list.tex your_template_dir/packing_list.tex
+   $ cp Default-purchase_order.tex your_template_dir/purchase_order.tex
+   $ cp Default-sales_order.tex your_template_dir/sales_order.tex
+ 
+4. edit sql-ledger.conf
+   instructions are in the file
+
diff --git a/sql-ledger/doc/UPGRADE-1.8.3-1.8.4 b/sql-ledger/doc/UPGRADE-1.8.3-1.8.4
new file mode 100644
index 000000000..c3ecdf5af
--- /dev/null
+++ b/sql-ledger/doc/UPGRADE-1.8.3-1.8.4
@@ -0,0 +1,10 @@
+Upgrading from version 1.8.3 to 1.8.4
+
+1. install SQL-Ledger over top of your old installation
+   $ cd /usr/local
+   $ tar zxvf sql-ledger-1.8.4.tar.gz
+
+2. update the tables with the admin script
+
+   You will not be able to log in until you upgraded the tables.
+   
diff --git a/sql-ledger/doc/UPGRADE-1.8.4-1.8.5 b/sql-ledger/doc/UPGRADE-1.8.4-1.8.5
new file mode 100644
index 000000000..e8c32e1bf
--- /dev/null
+++ b/sql-ledger/doc/UPGRADE-1.8.4-1.8.5
@@ -0,0 +1,18 @@
+Upgrading from version 1.8.4 to 1.8.5
+
+1. install SQL-Ledger over top of your old installation
+   $ cd /usr/local
+   $ tar zxvf sql-ledger-1.8.5.tar.gz
+
+2. update the tables with the admin script
+
+   You will not be able to log in until you upgraded the tables.
+
+
+There are two new variables (<%customernumber%> and <%vendornumber%>)
+which can be used in the forms. These may be used instead of the
+internally generated customer_id and vendor_id.
+
+Typically these numbers are used to retrieve a customer, vendor
+by some ID. In most counter operations the phone number is used.
+
diff --git a/sql-ledger/doc/UPGRADE-1.8.5-1.8.7 b/sql-ledger/doc/UPGRADE-1.8.5-1.8.7
new file mode 100644
index 000000000..992238c3a
--- /dev/null
+++ b/sql-ledger/doc/UPGRADE-1.8.5-1.8.7
@@ -0,0 +1,6 @@
+Upgrading from version 1.8.5 to 1.8.7
+
+1. install SQL-Ledger over top of your old installation
+   $ cd /usr/local
+   $ tar zxvf sql-ledger-1.8.7.tar.gz
+
diff --git a/sql-ledger/doc/UPGRADE-1.8.7-2.0.0 b/sql-ledger/doc/UPGRADE-1.8.7-2.0.0
new file mode 100644
index 000000000..e16ba7556
--- /dev/null
+++ b/sql-ledger/doc/UPGRADE-1.8.7-2.0.0
@@ -0,0 +1,20 @@
+Upgrading to Version 2.0.0
+
+1. install SQL-Ledger over top of your old installation
+   $ cd /usr/local
+   $ tar zxvf sql-ledger-2.0.0.tar.gz
+
+2. load admin.pl and update the tables
+
+   You will not be able to log in until the tables are up to date.
+
+3. copy the new templates to your personal template directory
+
+   $ cd templates
+   $ cp Default-check.tex dir/check.tex
+   $ cp Default-receipt.tex dir/receipt.tex
+   $ cp Default-statement.html dir/statement.html
+   $ cp Default-statement.tex dir/statement.tex
+
+   replace 'dir' with your directory name
+
diff --git a/sql-ledger/doc/UPGRADE-2.0-2.0.8 b/sql-ledger/doc/UPGRADE-2.0-2.0.8
new file mode 100644
index 000000000..6ddff62ac
--- /dev/null
+++ b/sql-ledger/doc/UPGRADE-2.0-2.0.8
@@ -0,0 +1,8 @@
+Upgrading from version 2.0.[0-7] to 2.0.8
+
+1. install SQL-Ledger over top of your old installation
+   $ cd /usr/local
+   $ tar zxvf sql-ledger-2.0.8.tar.gz
+
+2. update your datasets with the admin script
+
diff --git a/sql-ledger/doc/copyright b/sql-ledger/doc/copyright
new file mode 100644
index 000000000..d493a3d21
--- /dev/null
+++ b/sql-ledger/doc/copyright
@@ -0,0 +1,23 @@
+######################################################################
+# SQL-Ledger Accounting
+# Copyright (c) 2003, Dieter Simader
+#
+#  Author: Dieter Simader
+#   Email: dsimader@sql-ledger.org
+#     Web: http://www.sql-ledger.org
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+#
+#######################################################################
+
diff --git a/sql-ledger/doc/faq.html b/sql-ledger/doc/faq.html
new file mode 100644
index 000000000..0f6f237ca
--- /dev/null
+++ b/sql-ledger/doc/faq.html
@@ -0,0 +1,747 @@
+
    +

  • Sub-menus and Apache 2.0

    +Some versions of Apache 2.0 (2.0.44+) don't expand sub-menus and generate +a 500 error at various points. This stems from workaround developed for +earlier versions of Apache 2.0. It looks like this workaround must now be +disabled. If you get an error or the sub-menus don't expand edit +SL/Form.pm and comment lines 80-82. +
    +  # for Apache 2 we escape strings twice
    +#  if (($ENV{SERVER_SOFTWARE} =~ /Apache\/2/) && !$beenthere) {
    +#    $str = $self->escape($str, 1);
    +#  }
    +
    + + +

  • About installation

    +The easiest is to use the setup.pl script as root. +You don't need to know very much about your system, just login as root, +run 'perl setup.pl' and follow the prompts. +

    setup.pl does not check for missing software packages and it is your +responsibility to make sure you have the required pieces +installed either from source or from a package supplied with your distro. + +

    Requirements are clearly indicated in the README file and on the +download page. + + +

  • IDENT Authentication failed for user "postgres"

    + +This error has everything to do with the way the distros set up +access rights for postgres. They are way too restrictive and leave you +wondering what to do next. + +

    Do yourself a favour and change authentication in pg_hba.conf to + +

    +local           all              trust
    + +

    until you have figured what all this stuff in pg_hba.conf does. + +

    NOBODY, I repeat, NOBODY, from the Internet will be able to +connect to postgres. You can't even connect from the inside LAN, the only +one who is allowed to connect are clients originating from localhost. + +

    Read a bit about the different authentication settings and change +them as you see fit. +It is all described in detail in pg_hba.conf + +

    If you can't find the file, there is a wonderful utility called find. +Use it. +

    +# find /usr/local -type f -name 'pg_hba.conf'
    +
    + + +

  • DBD-Pg for Mandrake 9.0

    +Mandrake did not package a compiled DBD-Pg package again, so install DBD-Pg +from the source package. +Install perl-DBD-Pg-1.01-4mdk.i586.rpm from the 'contrib' area. +(Mandrake / 9.0 / contrib / RPMS) + +

  • LaTeX error

    +If for some reason LaTeX produces an error message check for strange +characters in your account description and parts description +and use \usepackage[latin1]{inputenc} in the preamble. + + +

  • LaTeX templates

    +If you don't want to edit tex code by hand, +you could use Lyx, Abiword, or any WYSIWYG editor capable of exporting +latex code. +To do that you must change the tokens for parameters <% and %> to something +like << and >>. % is the comment character in tex. There is also a +pagebreak block which must be commented out. +When you are done with the changes +replace << and >> with <% and %> and uncomment the pagebreak block. + +

    LaTeX is difficult but it also offers a much superior interface to produce +professionally looking forms in postscript and PDF format. +Unfortunately with power comes some pain too. + + +

  • W3M

    +pass terminal=mozilla when you start w3m +
    $ w3m -F http://localhost/sql-ledger/login.pl?terminal=mozilla
    + +To use without frames +
    $ w3m http://localhost/sql-ledger/login.pl?terminal=lynx
    + +

  • PDF option disappeared

    +Edit sql-ledger.conf and set $latex = 1; +
    sql-ledger.conf is perl code, check if it compiles, if it does not +the internal defaults are used which set $latex to 0, hence no PDF option. + +

  • SQL-Ledger on Mac Os X 10.1.5

    +Jaume Teixi put together + +installation instructions to run SL on a Mac. +
    The instructions are for 1.8.5 however they still apply to any of the +newer versions. + +

  • Installation on Windows (WIN32)

    +
      +
    • install Apache, perl, +Postgres +or Oracle, DBI and the appropriate DBD +module +
      if you can't compile DBD-Pg here is a precompiled +DBD-Pg module +
    • download the latest version of SQL-Ledger +
    • extract the files to c:\apache\sql-ledger +
    • download +sql-ledger-windows.tar.gz +and extract the files to c:\apache\sql-ledger +
      the shebang line is changed to c:\perl\bin\perl and the symlinks + are regular files +
      answer with 'Yes' to overwrite existing files. +
    • edit c:\apache\conf\httpd.conf and add +
      +Alias /sql-ledger/ "C:/apache/sql-ledger/"
      +<Directory "c:/apache/sql-ledger">
      +  AllowOverride All
      +  AddHandler cgi-script .pl
      +  Options +ExecCGI
      +  Order Allow,Deny
      +  Allow from All
      +</Directory>
      +
      +<Directory "c:/apache/sql-ledger/users">
      +  Order Deny,Allow
      +  Deny from All
      +</Directory>
      +
      + +
    • start Apache +
    • start Postgres|Oracle +
    • connect to http://localhost/sql-ledger/admin.pl and setup users +and datasets +
    • connect to http://localhost/sql-ledger/login.pl and login + +
    + +

  • Installation on Windows /w cygwin

    +
      +
    • install cygwin +Apache, perl, postgres, gcc and lynx +
    • install DBI +
    • tar zxvf DBI-1.30.tar.gz +
    • cd DBI-1.30 +
    • perl Makefile.PL +
    • make install +
    • install DBD-Pg +
    • tar -zxvf DBD-Pg-1.13.tar.gz +
    • export POSTGRES_INCLUDE=/usr/include/postgresql +
    • export POSTGRES_LIB=/usr/lib/postgresql +
    • cd DBD-Pg-1.13 +
    • perl Makefile.PL +
    • make install +
    • edit /etc/apache/httpd.conf and add +
      +AddHandler cgi-script .pl
      +Alias /sql-ledger/ /var/www/sql-ledger/
      +<Directory /var/www/sql-ledger>
      +  Options +ExecCGI
      +</Directory>
      +
      +<Directory /var/www/sql-ledger/users>
      +  Order Deny,Allow
      +  Deny from All
      +</Directory>
      +
      +
    • install SQL-Ledger +
    • cd /var/www +
    • mkdir sql-ledger +
    • download setup.pl and save the file +in /var/www/sql-ledger +
    • cd /var/www/sql-ledger +
    • perl setup.pl +
    + +

  • What do I enter for the language

    +If you use English, nothing, if you want to use a foreign language for +the login screen and admin stuff enter the language code. All the +language specific files are in the locale directory. The long form for +the language is in the LANGUAGE file. + +

  • Mandrake 9.0 permission denied error

    +Mandrake says to add this to your commonhttpd.conf +
    +<Directory /usr/local/sql-ledger>
    +   AllowOverride All
    +   Options -MultiViews -Indexes -FollowSymLinks
    +   Order allow,deny
    +   Allow from all
    +</Directory>
    +
    +The way apache starts is it:
    +Blocks all access to the physical file system /
    +Opens access to the physical file system /var/www/html
    +Opens access to the physical file system /var/www/perl
    +Opens access to the physical file system /var/www/cgi-bin
    +Opens access to the physical file system /var/www/protected-cgi-bin 
    +Opens access to the physical file system /home/*/public_html
    +Opens access to the physical file system /home/*/public_html/cgi-bin
    +Opens access to the physical file system /var/www/icons
    +Opens access to the physical file system /usr/share/doc
    +
    +Since you're trying to access files outside of those allowed paths, you
    +have to specifically allow it.  It's done this way because of some past
    +exploits with the pathnames.  Rather than trust that there will never be
    +another bug within apache that will let you get somewhere you don't
    +want, you set it up securely out of the box so that apache won't let
    +itself go somewhere that you don't want it to.
    +
    + + +

  • Incorrect Dataset version

    +The dataset you are trying to use is not compatible with the version. +When you upgrade datasets use the same database user in the "User" +field as the one listed in the Database section for the user. + + +

  • Mandrake 8.2

    +Mandrake did not include the package "perl-DBD-Pg-1.01-1mdk.i586.rpm" +You can install the package from Mandrake 8.1 + + +

  • printing to a printer

    +Setup a printer in the "Printer" field in the users preferences. +i.e lpr -Plaser +and set $latex = 1 in sql-ledger.conf +LaTeX must be installed for this to work. + +

    To send the document to the printer check the "Postscript" or "PDF" format, +enter the number of copies and click on the "Print" button. + +

    The printer field is available only when you edit the user's +preferences with admin.pl. + +

    Note: html format is for screen preview. Use your browser's +print function. + + +

  • beginning balances

    +Add a GL Journal entry and enter the beginning balance for your accounts. +Use your balance sheet. If you also want to add open invoices, add the invoices +and make the appropriate adjustments. Your balance sheet includes these +amounts! + + +

  • cost for parts and service

    +the cost will be updated when you purchase goods and services. You can +enter the cost manually. This is so you can have a cost on file without +making a purchase. + + +

  • establish a beginning inventory

    +add the parts with a purchase invoice. Use the real cost for the items +not zero. If you use zero cost then the cost of goods will be zero when you +sell the item. + + +

  • Assemblies

    +Assemblies are manufactured goods assembled from parts, services and +assemblies. Because you do not buy assemblies you 'stock assemblies' by +adding assembled units to your inventory. The quantity for individual parts +is reduced and the quantity for the assembly increased. To disassemble an +assembly you simply return the parts to inventory by entering a negative +quantity for the number of assemblies to stock. + + +

  • customizing SQL-Ledger

    +The application interface +consists of a global and private interface. + + +

  • DBD-Pg not installed

    + +Most modern distributions now package DBD-Pg. If it is +not packaged follow this recipe to get it working. + +
      +
    • check if you have the header files for PostgreSQL +
      $ find / -name 'libpq-fe.h' +
      if nothing shows up install the development package for PostgreSQL +
    • download and untar DBD-Pg +
    • set the environment variables POSTGRES_LIB and POSTGRES_INCLUDE +
    • cd to DBD-Pg directory +
      as ordinary user +
      $ perl Makefile.PL +
      $ make +
      $ make test +
      if all went well su to root +
      # make install +
    • remove DBD-Pg +
    + + +

  • SuSE 8.1 installation

    +
      +
    1. Install the following using YaST2: + +

      - perl-DBD-Pg +
      - postgresql +
      - postgresql-contrib +
      - postgresql-devl +
      - postgresql-docs +
      - postgresql-libs +
      - postgresql-perl +
      - postgresql-server +
      - postgresql-test + +

    2. Setup directories and paths for PostgreSQL: + +

      > sux - (change to root) + +

      - If not done by the installation, setup disk directory for your db: +
      # mkdir /var/lib/pgsql/data +
      # chown postgres /var/lib/pgsql/data + +

    3. Initialize the database, and start it, as below: +

      Note that there are man pages for initdb and pg_ctl. + +

      # touch /var/log/pgsql +
      # chown postgres:postgres /var/log/pgsql +
      # sux postgres + +

      - Initialize postgres: +
      > /usr/bin/initdb -D /var/lib/pgsql/data +
      (creating ... Success...) + +

      - Start the postgres daemon: +
      > /usr/bin/pg_ctl -D /var/lib/pgsql/data -l /var/log/pgsql start (start db) +
      (postmaster successfully started) + +

    4. Quick-test the server (still as user postgres): + +

      - > psql -d template1 +
      (Welcome ... \q to exit psql) +
      \q + +

      - Try setting up another db user: + +

      > createuser <db-user> (<db-user> should match an existing Linux user) +
      Shall the new user be allowed to create databases? (y/n) y +
      Shall the new user be allowed to create more new users? (y/n) n + +

      Unless a problem with DBD::Pg (perl interface), postgres is ready to go. + +

    5. If a previous sql-ledger database needs to be installed, +
      do the following as postgres user. Steps for dumping the old db, + and building the new follow: + +

      > sux postgres +
      > psql template1 +
      =# CREATE DATABASE my_database; (create your database) +
      =# \q +
      > cd /var/lib/pgsql/backups (assuming your backups are here) +
      The next command should have been performed earlier from the + previous installed version of postgres and your database: +
      > pg_dump -d my_database.sql.bak (from previous ver postgres) +
      > cp my_database.sql.bak my_database.sql +
      - Use vi to change all occurrances of 'current_date' to current_date + in file my_database.sql . +
      The vi command for this is :g/'current_date'/s//current_date/g +
      > psql my_database < my_database.sql > my_database.log +
      - Check my_database.log for errors. + +

    6. Download setup.pl and run it as root while on line to the internet: + +

      # mkdir /usr/local/sql-ledger +
      # cd /usr/local/sql-ledger +
      # ./setup.pl +
      - Enter i +
      - Enter httpd owner and group if different than displayed default. +
      (Download occurs and status is displayed...) + +

    7. Setup the new sql-ledger with database. + +

      - Surf to http://my_computer/sql-ledger/admin.pl +
      - Click enter (no password needed). +
      ->Database Administration +
      - Leave fields Host and Port enpty for local installations. +
      - Enter your database name in the "Connect to" field. +
      - Enter the database user you setup (postgres, sql-ledger, etc.) +
      - Enter a password, only if a password is assigned to the database. +
      - To update an existing sql-ledger database: ->Update Database +
      Should see: The following Datasets need to be updated. +
      ->Continue +
      Do more admin. You will need to setup at least one login. +
      To exit: ->Database Admin + +

    8. See if it works: + +

      - Surf to http://my_computer/sql-ledger/login.pl +
      - Enter the login name you just created. Main menu screen should appear. +

    + + + +

  • Redhat Installation

    + +
      +
    • Install apache1.3.12-25.i386.rpm +
    • Install perl5.6.0-9.i386.rpm +
    • Install postgresql-7.0.2-17.i386.rpm +
    • Install postgresql-server-7.0.2-17.i386.rpm +
    • Install postgresql-devel-7.0.2-17.i386.rpm (POSTGRES_INCLUDE) +
    • tar xvzf DBI-1.14.tar.gz +
    • cd DBI-1.14 +
    • perl Makefile.PL +
    • make +
    • make install +
    • cd .. +
    • tar xvzf DBD-Pg-0.95 +
    • cd DBD-Pg-0.95 +
    • export POSTGRES_LIB=/usr/lib/pgsql +
    • export POSTGRES_INCLUDE=/usr/include/pgsql +
    • perl Makefile.PL +
    • make +
    • make install +
    • install SQL-Ledger +
    + +

    Some of the applications have newer versions however the installation +instructions remain the same. Just substitute the old version with a newer +version. + + +

  • Debian Installation

    + +
      +
    • unpack into /usr/local/www/sql-ledger +
    • install postgresql (Dselect) +
    • install apache (Dselect) +
    • install libdbi-perl (Dselect) +
    • install libdbd-pg-perl (Dselect) +
    • install libpgperl (Dselect) +
    • modify /etc/postgresql/postgresql.conf +
      TCPIP_SOCKET = 1 +
    • create a user for managing SQL-Ledger databases +
      from root +
      su postgres +
      $ createuser -d sql-ledger +
      if you use passwords to access postgres set the user up with a password +
      $ createuser -d -P sql-ledger +
    • change /etc/apache/httpd.conf and add +
      +AddHandler cgi-script .pl
      +Alias /sql-ledger/ /usr/local/www/sql-ledger/
      +<Directory /usr/local/www/sql-ledger>
      +  Options +ExecCGI
      +</Directory>
      +
      +<Directory /usr/local/www/sql-ledger/users>
      +  Order Deny,Allow
      +  Deny from All
      +</Directory>
      +
      +
    • restart apache +
    • change fileownership of users and templates to www-data +
      chown www-data: users templates +
    • From browser enter http://localhost/sql-ledger/admin.pl +
    • Login as the postgres user (account manager) you have created (above) +
      Create a DB +
      Create users + +
    • then enter http://localhost/sql-ledger/login.pl +
      Login as one of the users you have just created + +
    + +

    +The long version was provided by Gordon Haverland. +

    +

      +
    • You need to unpack the SQL-Ledger package (compressed tar archive) + someplace. Unpacking it in
      +      /usr/local/www/sql-ledger.
      + Remember where you have unpacked it. +
    • SQL-Ledger requires that the PostgreSQL database be installed. +This is a very full-featured database, and has many associated +packages. SQL-Ledger requires version 7.0 or better. The name +of the basic package on Debian is postgresql. To find if you +already have postgresql installed, and if so what version, the +following command should work:
      +      dpkg -l | grep -i 'ii  postgresql '
      + A typical response would be:
      +      ii  postgresql     7.1.3-5        Object....[stuff deleted]
      + Indicating, that version 7.1.3 is installed (the -5 is a + Debian patch level). You can use dselect or apt-get to install + postgresql if you need to. You can visit the Debian maintainer's + page for much more information on related packages at
      +      http://people.debian.org/~elphick/postgresql/
      + Older versions of Debian's PostgreSQL installation use a file + called postmaster.init, while newer versions use a file called + postmaster.conf, either residing in /etc/postgresql. +
    • SQL-Ledger requires a HTTP server (or daemon) which is capable of + handling CGI scripts. Apache is the one which is recommended, + version 1.3 or better. Debian calls the base package apache. + Debian has two alternative versions of Apache, one with mod-perl + (apache-perl) support compiled in, and the other with SSL + (secure sockets layer - apache-ssl) support. SQL-Ledger doesn't + require mod-perl or SSL support, but works with either if + you need it installed for other functions you have. Older versions + of Debian Apache installations, spread the configuration of the + server across 3 files (srm.conf, access.conf and httpd.conf). + Newer versions have consolidated all of this to httpd.conf. +
    • SQL-Ledger uses the Data Base Interface perl module for communication + with PostgreSQL. The CPAN (Comprehensive Perl Archive Network) + name for this module is DBI. Debian calls this module + libdbi-perl. You should probably deselect (or apt-get) the + Debian version of this module to minimize upgrading headaches in + the future. +
    • DBI requires the use of an implementation specific Data Base + Driver. In our case, we need the PostgreSQL specific one. + CPAN calls this module DBD::PG, Debian calls it libdbd-pg-perl. + You should use dselect (or apt-get) to install it. +
    • One more layer of Perl - PostgreSQL support is needed. Debian + calls this last package libpgperl. Use dselect or apt-get to + install it. (You should be able to install all 5 packages at + one time.) +
    • We need to allow your PostgreSQL database to accept queries + in a network manner. To do this, we need to change the value + of the TCPIP_SOCKET to 1. In newer + PostgreSQL installs, this variable will be someplace in + /etc/postgresql/postgreslq.conf (older installs will be + postmaster.init, same directory. Note: you shouldn't have + both files there.) Start up your favorite text editor, find + the line with that variable on it, change the "no" to a "yes", + and make sure the line isn't commented out (a "#" in front + of it on the same line). +
    • PostgreSQL has a set of users and passwords independent of + normal user logins. We need to set up a PostgreSQL user + to "own" the SQL-Ledger data (choose a name that makes sense + to you, it shouldn't be "root" or "postgres"). The (PostgreSQL) + program for doing this is called "createuser". To make this + SQL-Ledger owner user, we first need to "become" the PostgreSQL + superuser (on Debian, this is "postgres"), and then we will + run the createuser program. So, once we are logged in as root: +
      +      # su postgres
      +      $ createuser -d sql-ledger
      +    ...
      +      $ exit
      +      # 
      +
      + As shown above, we then typed "exit" after createuser was done, + to stop being the "postgres" user. The "-d" switch (you called + also use "--createdb") specifies that this user can create + databases. +
    • We need to adjust the configuration of the HTTP server Apache + next. Older Apache installations (srm.conf, access.conf and + httpd.conf) need changes in srm.conf and httpd.conf. Newer + installations just need to edit /etc/apache/httpd.conf. First, + we need to instruct the server that files that end in ".pl" + are to be treated as "cgi-script"s (srm.conf if separate).
      +      AddHandler cgi-script .pl
      + Second, we need to map our SQL-Ledger installation to be easy + for users to find it (in srm.conf if separate).
      +      Alias /sql-ledger/ /usr/local/www/sql-ledger/
      + The "/" at the end of sql-ledger in both strings is important! + Next, we need to allow the server to execute files from those + directories, include things and follow links. This information + is in httpd.conf (old or new installations).
      +      <Directory /usr/local/www/sql-ledger>
      +        Options ExecCGI Includes FollowSymLinks
      +      </Directory>
      + If we decided to put SQL-Ledger somewhere other than + /usr/local/www/sql-ledger, we would use different paths above. +
    • All the files in the "users" and "templates" subdirectories + of /usr/local/www/sql-ledger need to be owned by "www-data".
      +      # cd /usr/local/www/sql-ledger
      +      # chown www-data:www-data users templates users/members
      + You may get an "error" about users/members not existing. It + is safe to ignore this error. +
    • Restart the apache server.
      +      /etc/init.d/apache restart
      +
    • From a browser, visit the URL
      +      http://localhost/sql-ledger/admin.pl
      +
    • Login as the PostgreSQL user responsible for the SQL-Ledger + database you set up. Create a database and create + at least one user. (It's not a good idea to access your + SQL-Ledger data as the "owner" of the data on a regular basis.) +
    • Visit
      +      http://localhost/sql-ledger/login.pl
      + and login as the user you created
+ + + + +

  • login.pl has compilation error

    + +This could be because of a missing configuration file in the users directory + +

    check the permission for the users directory. The directory must be +set writeable for the webserver. If your webserver runs under nobody.nogroup +set it to +

    +drwxrwx--x   2 johndoe  nogroup    1024 May 26 16:49 users
    +
    +or
    +
    +drwx--x--x   2 nobody   nogroup    1024 May 26 16:49 users
    +
    + + +

  • script not executing, shows in browser instead

    + +Add + +
    +  AddHandler cgi-script .pl
    +
    + +in your httpd.conf file. + + +

  • unknown terminal!

    +the frontend script couldn't figure out which browser you are using +

    include the terminal variable on the URL +

    +  http://localhost/sql-ledger/login.pl?terminal=lynx
    +

    Valid terminal variables are lynx and mozilla + + +

  • permission denied at filesystem level

    + +Check if your web server has write permission to write to the following +files and directories: +
    +  users/
    +  templates/
    +  users/members
    +
    +  # chown nobody:nogroup users templates users/members
    +
    + + +

  • permission denied to access tables

    +The user you entered in the "Database section" must be a valid +database user who has the rights to access the tables. + +

    If the tables are owned by 'john' and you enter 'mary' as the dba +you might run into this problem if mary doesn't have the rights to +access tables owned by john. + + +

  • html and graphics files don't show up on screen

    + +Enable Includes and FollowSymlinks Options in your httpd.conf file +
      <Directory /usr/local/sql-ledger>
    +    Options ExecCGI Includes FollowSymlinks
    +  </Directory>
    +
    + + +

  • Can I use mySQL

    + +No. mySQL lacks certain features required by SQL-Ledger. + + +

  • switch display to a foreign language

    + +Load your preferences and select the language. +
    Language selection is in accordance to + +ISO 3166-1 standards. + + +

  • Text shows in English when I use a foreign language

    + +This is because the corresponding hash entry is missing. +Add the missing text in the locale/cc/all or locale/cc/missing +file and run 'perl locales.pl' to rebuild the individual files. + +
    cc refers to the country code. + + +

  • switch to a foreign language for the login and admin screen

    + +Edit sql-ledger.conf and enter the code for the variable +$language. If your language specific files are in 'locales/cc', enter 'cc' + + + + +

    +


    + +

    SQL-Ledger security

    +
    + + + + + + -- cgit v1.2.1