Closed (won't fix)
Project:
Drush
Version:
8.x-6.x-dev
Component:
Core Commands
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
22 Dec 2010 at 03:15 UTC
Updated:
11 Sep 2013 at 04:58 UTC
Jump to comment: Most recent file
Comments
Comment #1
chx commentedMoved a few lines down , after the PDO check.
Comment #2
chx commentedIf I add this then even drush si and sqlc works. It smells like a utility function to me but not familiar enough with the drush customs on where to put this.
Comment #3
chx commentedW/o the first hunk, i filed a sep issue for that.
Comment #4
greg.1.anderson commentedCode looks good to me. Regarding the utility function, it could be placed in includes/drush.inc, but since it is only a few lines, I don't think that is necessary.
Comment #5
chx commentedWell it's wrong, i misunderstood: driver is the Drupal driver, databaseType is the PDO driver. Easy fix.
Comment #6
moshe weitzman commentedPlease remove that static cache. Those have eaten drupal alive and they aren't welcome here. Caller can do own cacheing if he needs to call this over and over again.
Otherwise, looks good.
Comment #7
chx commentedreally? this is the kind that would not receive the drupal_static treatment even in Drupal as it can not change during a request (or in fact, evah)
Comment #8
moshe weitzman commentedI looked at postgres driver and it takes $connection_options in its contstructor. This passes the string 'databaseType' as $connection_options and caches the result. That does not look right.
Comment #9
moshe weitzman commentedcommitted without uneeded static cache.
Comment #10
greg.1.anderson commentedThis patch causes sql-sync to catch fire and crash. Drush isn't bootstrapped, so it can't include the desired files. I didn't have time to try to fix it; I just backed out the last change, and sql-sync worked again. Did not commit; HEAD is still broken.
Comment #11
jonhattanI've just seen this
Comment #12
moshe weitzman commentedSorry. Please roll this back. Am offline until sun night
Comment #13
jonhattanreverted.
Comment #14
bherlig commentedThe revert removed some existing lines, so currently the SQL commands don't work for me (D6 installation using mysql).
Note that in 1.92 of sql.drush.inc (Diff) removes the following lines:
With that, the DB-driver isn't properly retrieved, but is returned as null. This becomes apparent when executing sql-connect:
Note that the command is missing.
Patch to fix the revert is attached for your consideration.
Comment #15
jonhattanapplied. thanks bherlig.
Comment #16
chx commentedArgh! this wasnt fixed?
Comment #17
chx commentedSQL commands now work too.
Comment #18
moshe weitzman commentedSomeone who needs this should step up for a code review and verify that it works. Otherwise, it won't get much attention from maintainers.
Comment #19
greg.1.anderson commentedThis issue was marked
closed (won't fix)because Drush has moved to Github.If desired, you may copy this bug to our Github project and then post a link here to the new issue. Please also change the status of this issue to
closed (duplicate).Please ask support questions on Drupal Answers.