First off, thanks for the patch/work Byron.  I've been wanting to get around
to verifing the decoupled torque with sybase, but we're in deep with turbine
2.x at the moment.  Anyway, after your patch was posted, I munged around
with it.

We went around with the delimiters when the current version of torque was
updated to support sybase.  Sybase's isql tool can also define the delimiter
to use to terminate a command ( its a command-line switch ), then there's
always sqsh, or java alternatives.  I think it is simpler to have the same
delimiter within torque, which is really just using the same delimiter that
the sql task in ant was using.  So I'm -1 on switching the sybase templates
or the adapter class to use 'go' as the deilimter.

Your patch to the TableTool in TorqueDataDump worked for me with sybase, but
mysql hung.  I took the easiest way out which was to re-implement that inner
class using Village.  This effectivly reads the entire result set into a
QueryDataSet which allowed the Iterator interface to be implemented
correctly.  Not much different but has some trade offs.  The first being the
entire dataset is read into memory: large tables will suck.  The other is
since Torque is currently implemented with Village, the data dump task will
work with any jdbc driver that village ( and subsequently torque ) works
with.

So I've used your patch, re-did TableTool with village, and repackaged it up
into the following zip:
http://home.wi.rr.com/jbrekke/patches/torque-patch.zip

It contains the patch file which will need to be applied and the files that
will be added to the repo when commited.

 Length   Method    Size  Ratio   Date   Time   CRC-32    Name
--------  ------  ------- -----   ----   ----   ------    ----
    4751  Defl:N     1426  70%  12-13-01 21:44  bf6a2c09  patch
     125  Defl:N       78  38%  12-13-01 21:41  d5397442
src/templates/sql/db-init/sybase/createdb.vm
     285  Defl:N      171  40%  12-13-01 21:42  55f8aadf
src/templates/sql/load/sybase/row.vm
      78  Defl:N       58  26%  12-13-01 21:42  e6de15d9
src/templates/sql/load/sybase/val.vm
    3781  Defl:N     1080  71%  12-13-01 21:44  16130603
profile/sybase.profile
--------          -------  ---                            -------
    9020             2813  69%                            5 files

Could you, or anyone else, try this out?  I've tested it with sybase and
mysql and all seems OK here.  Thanks.

jb


-----Original Message-----
From: Byron Foster
To: Turbine Developers List
Sent: 12/13/01 2:09 PM
Subject: RE: [PATCH] Sybase testbed

On Thu, 2001-12-13 at 06:47, Brekke, Jeff wrote:
> The delimiter should be defined by the ant task that executes the
generated
> sql.  'go' is used by sybase tools and ; should work from the torque
ant
> tasks.  I'll try your testbed here today hopefully...
> 

This is true.  I guess the advantage is generating SQL that can be used
in both environments.  From within Torque,  and loaded directly by
sybase tools, aka isql. Especially given the fact that Torque already
has hooks to handle such differences. Let me know how it goes or if you
have any problems.

Thanks,
Byron
 


--
To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to