Why not create a method for your multi-line EXECUTES and simply call that method?

----------------------------------------
Randy Jaynes
Management Software


On Apr 28, 2006, at 10:40 AM, Steve Alex wrote:


On Feb 20, 2006, at 6:44 PM, Aparajita Fishman wrote:

Is the %s formatting operator limited to string(255) when used in conjunction with "execute in 4d"?

Neither the % operator nor "execute in 4d" are inherently limited to 255 characters.


Back in Feb when I was having this problem with PDFlib plugin, I reverted to writing a wrapper for the one plugin call that contained more than 255(really 80) characters.

Now I'm trying to get Active4D to talk to the Postgres plugin (PgSQL Plugin) and have run into the same problem. I'll write something like:

$sql := 'select trans.tran_key,splits.split_key,trans.amount as camount, splits.amount from trans,splits where trans.id = splits.tran_id and split_key = \'$invnum\''
        $cmd := 'PgSQL Select (%d;"%s")' % ($connection;$sql)
        $rowset:= execute in 4d($cmd;*)

and the Plugin will barf on the command reporting an SQL error around column 79, pointing to "fr", or the first couple of characters of "from". This leads me to believe that the 4D execute statement:
EXECUTE (statement)

Parameter    Type        Description
statement      String      Code to be executed

must be limited to an 80 character string. The plugin call works fine from 4D. I'll have to try using the execute statement from 4D with a sql query string longer than 80 characters, but don't think that ".. inherently limited to 255 characters" is correct - something is limiting it to 80 characters.

Steve









_______________________________________________
Active4D-dev mailing list
[email protected]
http://mailman.aparajitaworld.com/mailman/listinfo/active4d-dev
Archives: http://mailman.aparajitaworld.com/archive/active4d-dev/

_______________________________________________
Active4D-dev mailing list
[email protected]
http://mailman.aparajitaworld.com/mailman/listinfo/active4d-dev
Archives: http://mailman.aparajitaworld.com/archive/active4d-dev/

Reply via email to