Closed (fixed)
Project:
Salesforce Suite
Version:
6.x-2.x-dev
Component:
User interface
Priority:
Normal
Category:
Feature request
Assigned:
Issue tags:
Reporter:
Created:
28 Apr 2009 at 18:45 UTC
Updated:
14 Jul 2009 at 03:24 UTC
Jump to comment: Most recent file
Comments
Comment #1
jmiccolis commentedFile uploading didn't take. take two.
Comment #2
alex_b commentedWe're using this in production for exploring SF repositories and building queries. This really makes our work faster.
Setting to needs review.
Comment #3
Bevan commentedOh goodie! I wish I'd had this a week ago! :)
Comment #4
Bevan commentedI put the file in /salesforce_api/salesforce_api.drush.inc.
I can see all 3 SOQL commands in drush help, but I get the following error when I try to run any soql command
Fatal error: Class 'SoapClient' not found in [snip]/SforceBaseClient.php on line 121. admin/settings/salesforce/demo connects fine.Comment #5
aaronbaumanA buddy of mine ran into this yesterday.
salesforce module works fine through your browser, right?
so, my guess is that your command line php instance is
1) different from your web php instance (for example if you're using X/M/WAMP) and
2) not configured with --enable-soap
try executing drush with the exact same php instance you use for apache.
Comment #6
Bevan commentedGood spotting. That was the issue – Thanks! Since Drush is a tool for development environments, I think we need to handle this error a bit better. E.g. "Have you enabled SOAP? If you can connect through the browser, make sure your command line PHP binary is the same as your web server's PHP binary. Use the command which php to help determine what binary is being used on the CLI."
Also, the help documents need fleshing out. The all need at least one example, in the same format as other Drush help docs. The soql command needs a few examples, some which actually work in most SF environments. It also needs links on how to find out more about how to use soql, and what soql is.
Otherwise, this is totally awesome and RTBC.
Comment #7
jmiccolis commentedGreat, glad everybody else if finding this useful. I'll post and updated file later this week which checks php compat and has some better docs.
Comment #8
jmiccolis commentedI've added better help, better display on soql describe when fields are requested, and now check for the soap extension.
Comment #9
jmiccolis commentedfile upload failed, trying again.
Comment #10
Bevan commentedComment #11
Bevan commentedCommitted in #208928 to DRUPAL-6--2. Nice work, and nice blog post! :)
Comment #13
victorkane commentedHave been enjoying this for some time.
Yesterday switched to new All-Versions-2.0 Drush, which is working fine; however, when I use the "drush soql" commands that were working fine previously, now I get invisible output.
The query is made ok, and the data returned from SF, but the data itself is not printed. For example:
$ drush soql show tables
... (142 lines) ...
142 rows in set.
Another example:
$ drush soql select Id from Contact where Email = \'someone@someone.net\'
1 rows in set (2.68 sec)
Programmatically, I am getting data, so I wonder if this is happening to anyone else using "drush soql" commands with the All-Versions-2.0 drush release.
Again, thanks a million for this wonderful drush extension!
Comment #14
jmiccolis commentedyes, the drush table printing api changed recently. This should be a quick fix
Comment #15
Bevan commentedThis is a separate issue, please create a new ticket/issue-node.