classes/phing/tasks/ext/dbdeploy/DbDeployTask.php
\DbDeployTask
Generate SQL script for db using dbdeploy schema version table and delta scripts
- Extends from
- \Task
- author
- Luke Crouch at SourceForge (http://sourceforge.net)
- copyright
- 2001,2002 THYRELL. All rights reserved
- package
- phing.tasks.ext.dbdeploy
- version
- $Revision: 1215 $
Properties

string
$TABLE_NAME= 'changelog'
The tablename to use from the database for storing all changes This cannot be changed
changelogDetails- Type
- string

array
$appliedChangeNumbers= 'array'
Array with all change numbers that are applied already
arrayDetails- Type
- array

int
$checkall= 'false'
Checkall attribute False means dbdeploy will only apply patches that have a higher number than the last patchnumber that was applied True means dbdeploy will apply all changes that aren't applied already (in ascending order)
falseDetails- Type
- int

object
$dbmsSyntax= 'null'
Contains the object for the DBMS that is used
nullDetails- Type
- object

int
$lastChangeToApply= '999'
The number of the last change to apply
999Details- Type
- int

string
$outputFile= 'dbdeploy_deploy.sql'
Output file for performing all database patches of this deployment Contains all the SQL statements that need to be executed
dbdeploy_deploy.sqlDetails- Type
- string

string
$undoOutputFile= 'dbdeploy_undo.sql'
Outputfile for undoing the database patches of this deployment Contains all the SQL statements that need to be executed
dbdeploy_undo.sqlDetails- Type
- string
Methods

createOutputFile(
string $file, bool $undo
=
false
)
:
void| Name | Type | Description |
|---|---|---|
| $file | string | |
| $undo | bool |

fileNeedsToBeRead(
int $fileChangeNumber, string $lastChangeAppliedInDb
)
:
bool| Name | Type | Description |
|---|---|---|
| $fileChangeNumber | int | |
| $lastChangeAppliedInDb | string |
| Type | Description |
|---|---|
| bool |

generateSql(
bool $undo
=
false
)
:
string| Name | Type | Description |
|---|---|---|
| $undo | bool |
| Type | Description |
|---|---|
| string |

getAppliedChangeNumbers(
)
:
array| Type | Description |
|---|---|
| array |

getDeltasFilesArray(
)
:
array| Type | Description |
|---|---|
| array |

getLastChangeAppliedInDb(
)
:
int|mixed| Type | Description |
|---|---|
| intmixed |

setCheckAll(
bool $checkall
)
:
void| Name | Type | Description |
|---|---|---|
| $checkall | bool |

setDeltaSet(
string $deltaSet
)
:
void| Name | Type | Description |
|---|---|---|
| $deltaSet | string |

setDir(
string $dir
)
:
void| Name | Type | Description |
|---|---|---|
| $dir | string |

setLastChangeToApply(
int $lastChangeToApply
)
:
void| Name | Type | Description |
|---|---|---|
| $lastChangeToApply | int |

setOutputFile(
string $outputFile
)
:
void| Name | Type | Description |
|---|---|---|
| $outputFile | string |

setPassword(
string $password
)
:
void| Name | Type | Description |
|---|---|---|
| $password | string |

setUndoOutputFile(
string $undoOutputFile
)
:
void| Name | Type | Description |
|---|---|---|
| $undoOutputFile | string |

setUrl(
string $url
)
:
void| Name | Type | Description |
|---|---|---|
| $url | string |

setUserId(
string $userid
)
:
void| Name | Type | Description |
|---|---|---|
| $userid | string |