>> #request.tapi.db.concatenate("blah","blah2","yadda")#

> Interesting! Our cms has a variable:
> request.thrive.dbms.concatenate() which
> does almost the same thing! My version just inserts the
> symbol, so it takes no parameters. ;-)

You and I seem to have a lot in common when it comes to coding. :)

I thought having it just return the concat string and decided to do it this
way because I figured it'd be less typing / fewer lines of code...

select col1 #request.tapi.db.concatenate()# col2
        #request.tapi.db.concatenate()# '/samsonite/'
        #request.tapi.db.concatenate()# col4 as blah

vs.

select #request.tapi.db.concatenate("col1","col2","'/samsonite/'","col4")#
as blah

though most concatenation for Tapestry is done in views and stored proc's,
so I'm not even certain the function will get used -- just planning for
contingencies. :)

I should probably actually rewrite it so that it can be used with or without
arguments, that way I can probably leave out the preservesinglequotes and be
good, like:

select #request.tapi.db.concatenate("col1","col2"," ")# '/samsonite/'
        #request.tapi.db.concatenate()# col4

more typing, but maybe more reliable... (the whitespace argument above
forces the function to add the concat string to the right of col2 since it's
only going to delimit the list in the middle and an empty string "" would be
removed from the list).

I suppose I could have used listchangedelims() and just passed a whole
string, but then if you want to have a quoted value in the middle and it
contains any of the delimiter characters (col1 + '+' + col2) there's a
problem.


s. isaac dealey                954-776-0046

new epoch                      http://www.turnkey.to

lead architect, tapestry cms   http://products.turnkey.to

tapestry api is opensource     http://www.turnkey.to/tapi

certified advanced coldfusion 5 developer
http://www.macromedia.com/v1/handlers/index.cfm?ID=21816

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm

                                Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
                                

Reply via email to