Skip to content

Commit

Permalink
Merge pull request #88 from WebFiori/dev
Browse files Browse the repository at this point in the history
fix: Fix to Table Name Inclusion on Create Table Query
  • Loading branch information
usernane authored Apr 30, 2024
2 parents f32a87a + 2dea8f2 commit 06164ce
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions webfiori/database/mssql/MSSQLColumn.php
Original file line number Diff line number Diff line change
Expand Up @@ -632,6 +632,7 @@ private function defaultPartString() {
}
}
private function firstColPartString() {
$this->setWithTablePrefix(false);
$retVal = MSSQLQuery::squareBr($this->getName()).' ';
$colDataTypeSq = MSSQLQuery::squareBr($this->getDatatype());
$colDataType = $this->getDatatype();
Expand Down
2 changes: 2 additions & 0 deletions webfiori/database/mssql/MSSQLTable.php
Original file line number Diff line number Diff line change
Expand Up @@ -299,11 +299,13 @@ private function createFKString() {
$sourceCols = [];

foreach ($fkObj->getSourceCols() as $colObj) {
$colObj->setWithTablePrefix(false);
$sourceCols[] = ''.$colObj->getName().'';
}
$targetCols = [];

foreach ($fkObj->getOwnerCols() as $colObj) {
$colObj->setWithTablePrefix(false);
$targetCols[] = ''.$colObj->getName().'';
}
$fkConstraint .= " constraint ".$fkObj->getKeyName().' '
Expand Down

0 comments on commit 06164ce

Please sign in to comment.