This repository has been archived by the owner on Jan 8, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2.5k
DDL support for Zend\Db #4311
Closed
ralphschindler
wants to merge
6
commits into
zendframework:master
from
ralphschindler:feature/db-ddl
Closed
DDL support for Zend\Db #4311
ralphschindler
wants to merge
6
commits into
zendframework:master
from
ralphschindler:feature/db-ddl
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Removed various empty classes
@@ -0,0 +1,175 @@ | |||
<?php | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
add
/**
* Zend Framework (http://framework.zend.com/)
*
* @link http://github.com/zendframework/zf2 for the canonical source repository
* @copyright Copyright (c) 2005-2013 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/
here ...
This needs a php-cs-fixer ! :) Also for instance this:
Should look better like this:
I didn't go through all your code though. But there are also many unnecessary \n's and there's also a //var_dump() somewhere. Looks like a nice feature though, looking forward to using it. |
It's a work in progress, more things are coming, including unit tests, doc blocks, etc. |
} | ||
|
||
$newSpec = str_replace('...', implode(', ', $newSpecParts), $this->specification); | ||
//var_dump($newSpec, $newSpecTypes); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't forget to remove that :).
More tests and docblocks
ghost
assigned weierophinney
May 1, 2013
weierophinney
added a commit
that referenced
this pull request
May 1, 2013
- Made sure file-level docblocks were consistent throughout - Alphabetized constant and property declarations - Ensured methods were in public -> protected -> private order - s/$self/this/ in all @return annotations - Ensured annotations were available and correct for all public methods - A few minor formatting changes for readability
weierophinney
added a commit
that referenced
this pull request
May 1, 2013
Merged to develop for 2.2.0. |
What about simple non-unique column/s index? |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is initial support for DDL commands in Zend\Db\Sql via an object-oriented abstraction interface. There are many things that would be supported long term.
At current, this component is capable of creating, altering and dropping tables, with columns, constraints and indexes. It has MySQL specialization support. Below is a sample script and its output:
Which results in