"Ben Bookey" <[EMAIL PROTECTED]> writes:

Hi,

well, it won't make you happy, but that is how it works on
e.g. PostgreSQL.

Torque uses the onDelete="cascade" attribute only for the SQL
generation and relies on the database to do the actual cascade.

>Dear List,

>I am trying to create a cascade delete foreign key reference for mySQL
>database sql script, using Torque 3.0.2, but it doesnt generate the correct
>sql.

>I have taken a look at the mySQL template vm velocity files, but can not
>find any mention of "cascade delete".

I looked at the Torque 3.1 tree and cascades are only supported for
oracle, postgresql and sapdb (as far as I can see).

The MySQL support is pretty much on the 3.23 level when the database
engine had no cascading delete support. The problem with MySQL is,
that the supported language has been greatly extended in 4.x.

So yes. I think you're out of luck for MySQL > 3.23 ATM. Sorry. 

Patches welcome (but they must keep backwards compatiblity; so you
probably would need to introduce a new database type, e.g. mysql4,
based on mysql.

        Regards
                Henning

><foreign-key foreignTable="main" onDelete="cascade">
>  <reference
>               local="ID_main"
>               foreign="ID_main"/>
></foreign-key>


>Could anyone tell me if this is supported by Torque and the mysql db driver.

>regards

>Ben Bookey


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

-- 
Dipl.-Inf. (Univ.) Henning P. Schmiedehausen          INTERMETA GmbH
[EMAIL PROTECTED]        +49 9131 50 654 0   http://www.intermeta.de/

RedHat Certified Engineer -- Jakarta Turbine Development  -- hero for hire
   Linux, Java, perl, Solaris -- Consulting, Training, Development

"Fighting for one's political stand is an honorable action, but re-
 fusing to acknowledge that there might be weaknesses in one's
 position - in order to identify them so that they can be remedied -
 is a large enough problem with the Open Source movement that it
 deserves to be on this list of the top five problems."
                       -- Michelle Levesque, "Fundamental Issues with
                                    Open Source Software Development"

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

Reply via email to