Re: [fpc-pascal] Re: FCL-DB/SQLDB docs started

2007-12-04 Thread Adrian Maier
On Dec 3, 2007 2:07 PM, Leonardo M. Ramé <[EMAIL PROTECTED]> wrote:
> I like the idea, can you start by creating the section's skeleton?

Here is a possible structure of the page.I'm not familiar yet to
working with this
lufdoc , that's why i'm putting the skeleton here on the mailing list
for the moment.


Sqldb guide

1. Introduction
- what is FCL-db
- what is Sqldb ; the supported databases
- the current document concentrates on the sql databases

2. Concepts
- the diagram shown here
http://wiki.lazarus.freepascal.org/SQLdb_Programming_Reference
- explanations about each of the classes

3. Connecting to a database
- how to instatiate a TsqlConnection for each of the supported databases
- checking that the connection succeeded
- closing the connection
- frequently used methods of the TSqlConnection class
- maybe : link to another doc "Setting up the database for the sqldb
guide examples" , so that
  the specific instructions for creating the db doesn't clutter this guide

4. Transactions
- how to instantiate a TsqlTransaction and "link" it to the connection object
- frequently used methods of the TSqlTransaction class :
StartTransaction, Commit, CommitRetaining, Rollback.

5. Executing SQL commands

5.1 The TSqlQuery class
- how to instante and "link" the query to the transaction and connection.
- frequently used methods

5.2 Executing simple sql queries (which don't return tuples)
- cfilltable.pp

5.3 Executing a sql query and traversing the records
- example for accessing the fields by name  - dshowtable.pp
- example for accessing the fields by position
- using filters - gfiltertable.pp

5.4 Editing the records
- fedittable.pp

5.5 Queries with parameters
- efilltableparams.pp

5.6 Executing sql commands with connection.ExecuteDirect
- example for using ExecuteDirect  - bcreatetable.pp
- advantages/disavantages compared to using a TSqlQUery

5.7 Other stuff
- getting the list of tables - alisttables.pp
- other functionality that i'm not aware of

6. Developing FCL-DB and SqlDb
6.1 Structure of the FCL-DB directory in the FPC sources
6.2 Implementing a new kind of TSqlConnection


7. Resources
- links to the reference pages of the classes used
- links to tutorials, wiki pages, etc.



-- 
Adrian Maier
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] can we have fpc's doc in chm format?

2007-12-04 Thread Roberto Padovani
why not giving it a try ? :-) I'm downloading

2007/12/4, Bee <[EMAIL PROTECTED]>:
> > Agree. However, I was finally able to finish this job last night. It
> > took me about 6 hours to re-arrange the index files, manually. For
> > everyone who is interested, fpc docs in chm format can be downloaded at:
> > http://www.esnips.com/doc/04496e39-6105-423d-b571-b0766990b060/fpc-2.2.0-docs
> > (5.8 MB compressed)
>
> Can we provide this file on fpc's doc ftp?
>
> -Bee-
>
> has Bee.ography at:
> http://beeography.wordpress.com
> ___
> fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
> http://lists.freepascal.org/mailman/listinfo/fpc-pascal
>


-- 
--
 Ing. Roberto Padovani

 via Mandrioli, 1
 40061 Minerbio (BO)
 Italy

 mail: [EMAIL PROTECTED]
 cell: 340-3428685
-
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] can we have fpc's doc in chm format?

2007-12-04 Thread Andrew Haines
Michael Van Canneyt wrote:
> 
> On Sun, 2 Dec 2007, Bisma Jayadi wrote:
> 
>> Can we have fpc's doc in chm format? It's easier to navigate and search
>> compare to other formats. :)
> 
> The reference material: If you complete the chm backend of fpdoc, yes.
> The manuals: definitely out.
> 

I have almost completed the patch to add chm as an output option for fpdoc.

And before anyone gets their hopes up, to make chm's searchable you have
to at creation time generate a special file that is contained in the
chm. To me it's relatively difficult and I never implemented it.

Short version: chm's made with the current chm writing code cannot be
searched with the helpviewer.

That having been said, If a viewer is written for chm files (there is
reader code with fpc too) perhaps a database file created with some
search engine (like ioda) can be included and integrated so searching is
possible.

Michael, are the manuals written in rtf? why couldn't they be in a chm file?

Regards,

Andrew Haines
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] can we have fpc's doc in chm format?

2007-12-04 Thread Marco van de Voort
> Michael Van Canneyt wrote:
> 
> Michael, are the manuals written in rtf? 

They are in LaTeX with specialized environments.

___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal] [2.3.1] Can't take the address of constant expressions

2007-12-04 Thread Damien Gerard


Hi !

I am trying the 2.3.1 and I can not recompile my projects.
I ve got the message :Can't take the address of constant expressions.

I have only the following :

TMyClass = class(TObject)
   p_ref : TAnotherClass;
   procedure setRef(AValue: TANotherClass);
public
   property ref: TAnotherClass read p_ref write setRef;
end;

Where am I wrong for the 2.3.1 ?



--
Damien Gerard
[EMAIL PROTECTED]

People who used magic without knowing what they were doing usually  
came to a sticky end. All over the entire room, sometimes.

-- (Terry Pratchett, Moving Pictures)



___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] [2.3.1] Can't take the address of constant expressions

2007-12-04 Thread Jonas Maebe


On 04 Dec 2007, at 12:06, Damien Gerard wrote:


I am trying the 2.3.1 and I can not recompile my projects.
I ve got the message :Can't take the address of constant expressions.

I have only the following :


No, you have more:

bigmac:~/fpc/test jonas$ cat tt4.pp
{$mode delphi}

TMyClass = class(TObject)
   p_ref : TAnotherClass;
   procedure setRef(AValue: TANotherClass);
public
   property ref: TAnotherClass read p_ref write setRef;
end;
bigmac:~/fpc/test jonas$ ppcppc27 tt4
Free Pascal Compiler version 2.3.1 [2007/12/01] for powerpc
Copyright (c) 1993-2007 by Florian Klaempfl
Target OS: Darwin for PowerPC
Compiling tt4.pp
tt4.pp(3,9) Fatal: Syntax error, "BEGIN" expected but "identifier  
TMYCLASS" found

Fatal: Compilation aborted

(even adding "type" and a dummy declaration for TAnotherClass is not  
enough to get the error message you are reporting)



TMyClass = class(TObject)
   p_ref : TAnotherClass;
   procedure setRef(AValue: TANotherClass);
public
   property ref: TAnotherClass read p_ref write setRef;
end;

Where am I wrong for the 2.3.1 ?


Please post the full source needed to reproduce the error message you  
are getting.



Jonas
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


Re: [fpc-pascal] can we have fpc's doc in chm format?

2007-12-04 Thread Andrew Haines
Michael Van Canneyt wrote:
> 
> On Sun, 2 Dec 2007, Bisma Jayadi wrote:
> 
>> Can we have fpc's doc in chm format? It's easier to navigate and search
>> compare to other formats. :)
> 
> The reference material: If you complete the chm backend of fpdoc, yes.

Attached is a patch to add chm output to fpdoc. I edited Makefile.fpc to
require the "package" chm. Also a patch for chmwriter.pas with some
minor changes that were needed.

Regards,

Andrew


fpdoc-chm.tar.bz2
Description: BZip2 compressed data
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal

[fpc-pascal] fpc 2.2.0, trying to install as none root on Linux

2007-12-04 Thread Bernd Mueller

Hello,

I have downloaded fpc-2.2.0.i386-linux.tar, decompressed the archive and 
run the install script ./install.sh as none root.


The script prompts the following message:
   "Install prefix (/usr or /usr/local) [/home/bernd/fpc-2.2.0]:"

I read the manual and expected to answer some simple questions. I think, 
it is my lack of Linux experience, but is not clear to me, what I should 
enter now.


I would like to install the compiler/rtl/docs into /home/bernd/fpc220 
and leave the rest of the system completely untouched. Is this possible? 
If yes, what do I have to enter? Thanks.


Regards, Bernd.
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal


[fpc-pascal] copy(), length(), and setlength() is not mentioned in fpc docs?

2007-12-04 Thread Bee

Hi all,

Is it just me or above methods are indeed not mentioned within fpc's doc 
2.2.0? Any texts that are supposed to be a link to above methods is not 
formed as a link.


Just to make sure, before I'll report this to mantis as a "bug". :)

-Bee-

has Bee.ography at:
http://beeography.wordpress.com
___
fpc-pascal maillist  -  fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal