Coder Social home page Coder Social logo

forcedotcom / soql-tooling Goto Github PK

View Code? Open in Web Editor NEW
22.0 22.0 8.0 1.95 MB

SOQL Language Tooling features including the Language Server and Query Builder UI.

License: BSD 3-Clause "New" or "Revised" License

JavaScript 2.61% TypeScript 89.46% HTML 4.11% CSS 3.45% Shell 0.38%

soql-tooling's People

Contributors

baseballyama avatar code0100fun avatar dehru avatar dobladez avatar github-actions[bot] avatar jgellin-sf avatar jonnyhork avatar lisandrofernandezsf avatar praksb avatar ryanbrainard avatar svc-scm avatar tmock12 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

soql-tooling's Issues

Save dialog for exporting results

Is your feature request related to a problem? Please describe.

The export results feature is opinionated about where to save the results - I'd like to be able to choose where they go. Another side effect of this is that you might overwrite your previous export by accident with a different query or just updated results of the same one.

Describe the solution you'd like

A save dialog might be a nice to have. Save dialogs can have default location (like what already happens), but I can choose a different location and set the file name.

Describe alternatives you've considered

At the moment you can just rename the results or manually move them somewhere else if you want.

[W-8675840] Not providing enough error details to the user

When a user runs an invalid query we show them the generic Your query contains invalid or incomplete syntax. Fix the syntax errors and try again but the library does provide enough information about the error. We should be surfacing that information to the user.

Sample query:

Select Id, Status, Location, Body from ApexLog

Library error message:

Select Id, Status, Location, Body from ApexLog
                             ^
ERROR at Row:1:Column:30
No such column 'Body' on entity 'ApexLog'. If you are attempting to use a custom field, be sure to append the '__c' after the custom field name. Please reference your WSDL or the describe call for the appropriate names.

Screen Shot 2020-11-12 at 3 30 27 PM

W-8253044 - UX: SOQL Builder is unusable outside of an sfdx-project.

Is your feature request related to a problem? Please describe.
Because the SOQL extension is activated when I open a .soql file, I will see the custom editor when I open a .soql file from any directory or workspace.

However if I am not in an sfdx-project as the root directory then the sobjects can not load and I can not run a soql query in the text document.

Describe the solution you'd like
The SOQL builder should only be activated if I have an sfdx-project as my root directory.

Describe alternatives you've considered
Some notification to the user they should re-open the sfdx-proj at the root directory.

Additional context
Screen Shot 2020-10-22 at 11 10 33 AM

Incorrect error message when running a Tooling API query

If a user runs a query for an entity that is only exposed in Tooling API the error message is Your query contains invalid or incomplete syntax. Fix the syntax errors and try again. It should be something like entity not supported.

tooling_api_query

OS and version: Mac OS 10.15.7
VS Code Version: 1.51.0

UX: Show the query to which the results came from in the table view

Is your feature request related to a problem? Please describe.
If I have ran multiple queries and I have many tabs open of the data view then I can't keep track of which was associated with each tab

Describe the solution you'd like
have some sort of drop down in the table view of the query text that the results came from.

Describe alternatives you've considered
close each tab before running a new query

Additional context
Screen Shot 2020-10-22 at 12 53 20 PM

W-8253104 - Soql Results View -> Csv and Json buttons -> Not apparent what they will do

Is your feature request related to a problem? Please describe.
When the Results View is displayed, the JSON and CSV Buttons are displayed. But it's not really apparent that those will export the results. Probably just need some text.

Describe the solution you'd like
It might be better to have text that says
Download as: [csv] [json]

Additional context
Screen Shot 2020-10-22 at 11 17 23 AM

(Accessibility) Unable to use the keyboard to tab through selected fields and remove them

Code Builder or Desktop:
Code Builder

OS and version:
Windows

VS Code Version:

Browser Version (if applicable):
Edge

Summary

For accessibility, the selected fields should be in the tab order and you should be able to use the keyboard to remove them.

Steps To Reproduce:

  1. Select multiple fields in the SOQL builder
  2. Press the tab key

Expected result

The selected fields should be in the tab flow, and you should be able to use the keyboard (e.g., press enter) to remove the field.

Actual result

Focus skips over the selected fields to the Order By dropdown.

Additional information

Feel free to attach a screenshot.

SFDX CLI Version:

W-8580578: SObject retrieval not recognizing recently created default scratch org as default

Code Builder or Desktop: Desktop

OS and version: Mac 10.14.6

VS Code Version: 1.49.0

Browser Version (if applicable):

Summary

I created a default scratch org in VSCode. I installed the SOQL extension. I opened a soql file in the SOQL editor. The Salesforce CLI output showed NamedOrgNotFound: No AuthInfo found for name <scratch-org-name> and failed to load the sobject names in the FROM field. In the meantime, sfdx force:schema:sobject:list -c all retrieved the sobjects with no problems. When I re-selected the scratch org in the org picker, the editor was able to retrieve the sobjects.

Steps To Reproduce:

  1. Create a default scratch org using the Command Palette.
  2. Install the SOQL extension.
  3. Open a .soql file in the SOQL editor. The FROM picklist does not get populated and the Salesforce CLI output reads NamedOrgNotFound: No AuthInfo found for name <scratch-org-name>

Expected result

The SOQL editor is able to connect to the recently created default scratch org and retrieves sobject information.

Actual result

The SOQL editor does not retrieve sobject information from the recently created default scratch org and issues the NamedOrgNotFound: No AuthInfo found for name <scratch-org-name> message to the Salesforce CLI output channel.

Additional information

Full Salesforce CLI output channel output (3 instances of NamedOrgNotFound correspond to 3 attempts at opening SOQL editor).

Starting SFDX: Create a Default Scratch Org...

10:33:16.376 sfdx force:org:create -f config/project-scratch-def.json --setalias dreamtxdemo --durationdays 30 --setdefaultusername --json --loglevel fatal
10:33:57.776 sfdx force:org:create -f config/project-scratch-def.json --setalias dreamtxdemo --durationdays 30 --setdefaultusername --json --loglevel fatal
 ended with exit code 0

NamedOrgNotFound: No AuthInfo found for name dreamtxdemo
NamedOrgNotFound: No AuthInfo found for name dreamtxdemo
NamedOrgNotFound: No AuthInfo found for name dreamtxdemo
Starting SFDX: Set a Default Org

12:37:38.369 sfdx force:config:set defaultusername=dreamtxdemo
=== Set Config
Name             Value        Success
───────────────  ───────────  ───────
defaultusername  dreamtxdemo  true
12:37:39.940 sfdx force:config:set defaultusername=dreamtxdemo
 ended with exit code 0

SFDX CLI Version: 7.78.1

W-8580593: Starting a VSCode session with an expired authentication breaks SOQL editor

Starting a VSCode session with an expired SFDX authentication breaks SOQL editor. It will not throw any error but it does not populate any data on the view. Switching to a valid authentication does not work either. The only solution is to switch to a valid authentication session and then restart VSCode.

VSCodesession_expiredauth

OS and version: Mac OS 10.15.7

VS Code Version: 1.51.0

W-8252878 - Update Order By selections with UI changes.

Code Builder or Desktop: CB

OS and version: Mac Mojave

Steps To Reproduce:

  1. In Order By, select a field like Id that is probably a primary key
  2. Under Nulls, select a value
  3. Click Add.
    Nothing happens.

Expected result

Error or information message that you can't select this field because it's a primary key or can't be null

Was able to select another field and indicate a Null.

Improve overall developer experience with SOQL Builder

Is your feature request related to a problem? Please describe.
Not specific to particular but it is about in general experience. here are the quick notes from my point of view:

  1. Editing SOQL query is not friendly in text editor - it keeps selecting the SOQL builder view - probably known already
  2. Option to edit the query inside soql query instead of text editory
  3. Shortcut to open the soql query editor from apex classes/triggers on selecting the query
  4. Auto suggestions for fields and its related fields
  5. Ability to navigate to record in salesforce app
  6. Ability to edit and delete the record from soql builder results
  7. Run the query against another org easily or have an option for it

Describe the solution you'd like
Nothing specific, but would like to have the best solution that improve developer experience

Describe alternatives you've considered
Nothing

Additional context
None

From picklist overflows to SOQL Query preview box

After loading the list of SObject from the org, the From picklist gets refreshed and that causes the picklist to overflow to the SOQL Query preview box.

misaligned-from-picklist

OS and version: Mac OS 10.15.7
VS Code Version: 1.51.0

W-8129644 - Multiple query result tabs for the same query

If a user runs the same query multiple times we create multiple SOQL Query Results tabs. I would expect only one result tab per query or per .soql file.

Repro steps:
Build a valid query
Click the Run Query button multiple times
Get the same number of result tabs

multiple_results_same_query

W-8207738 - Run Query button does not indicate it is busy running your query

Code Builder or Desktop:
Desktop
OS and version:
OSX 10.14.6
VS Code Version:
1.52.0-insider
Browser Version (if applicable):
NA

Summary

When i click the Run Query button, it does not indicate that it is "busy" running the query. If the query takes a long time, my tendency is to click it again, unsure if it captured my previous click. This can result in multiple queries being run at once, with multiple result tabs displaying after the queries finally return.

This UX is especially brutal when your salesforce org has a lot of data and the query takes a while to run. For instance, log into gus.

sfdx force:auth:web:login -r https://gus.my.salesforce.com -a gus
sfdx force:config:set defaultusername=<your gus email>@gus.com

Steps To Reproduce:

  1. Log into gus
  2. Create a simple query like SELECT Id FROM ADM_Work__c
  3. Click Run Query
  4. Notice the awkwardly long pause and the mental anguish as to whether anything is happening.

Expected result

The Run Query button should disable and provide visible feedback to the user that is indeed carrying out their wishes.

Actual result

The Run Query button just stays in it's current state, without any UX feedback that it has indeed received its orders to run the query.

Additional information

run-query

SFDX CLI Version:
sfdx-cli/7.78.1-5a65d9dd2f linux-x64 node-v12.18.3

Toggle menu icon does not show when SFDX: Created New Soql Query until file is saved

OS and version:
All
VS Code Version:
1.52.1
SFDX CLI Version:
sfdx-cli/7.80.0

Summary

When using the command palette with SFDX: Create New Soql Query, the file it produces is untitled. And the toggle icon to toggle between source and builder is not available in the title menu until the file is saved with a .soql extension.

Steps To Reproduce:

  1. Run SFDX: Create New Soql Query from the command palette
  2. Notice that when the soql builder ui becomes available, the toggle icon is not shown
  3. Save the file with anyname.soql
  4. Notice that the toggle icon becomes available

Expected result

I would expect that anytime the soql builder ui is active, the title menu should include the toggle icon.

Actual result

Toggle icon is not present until file is save as *.soql

Additional information

W-8253076 - Soql Builder - Zero results returned after limit field set to 0 then cleared

Code Builder
Version: 1.51.0-insider
Commit: 076245b1ce18bc0c262bb287b3fcad1575d756ae
Date: 2020-10-14T19:02:31.672Z
Browser: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/86.0.4240.80 Safari/537.36

Summary

There seems to be some issue when the limit field is set to 0, and then it gets removed from the soql statement ( see other bug ). Running the query returns Zero results as if the LIMIT 0 is still set in the statement.

Additional interaction with the LIMIT field resolves the issue as a work around. But it's not apparent why there are no results.

Steps To Reproduce:

  1. Set Limit to 1
  2. Run Query
  3. Set Limit to 0 ( watch soql statement remove the limit clause )
  4. Run Query
  5. BOOM: Zero Results
  6. This is step 2. All steps should start with '1.'

Expected result

Since the LIMIT clause has been removed, I would expect all results.

Actual result

Zero records returned

Additional information

limit0bug

SFDX CLI Version: sfdx-cli/7.74.1-32db2396ed linux-x64 node-v12.18.3

Suggestion on Fields and WHERE clause boxes

Hello,
Recently I just installed this extension to my workspace: SOQL Builder for Visual Studio Code. This is really amazing and, also waited for this update. I have some feedback which has been mentioned below.
image

  1. It would be better Fields box have draggable window, So we can have a wide views in the Fields selection box and also it will be more easier to us select particular field which might have large number of fields for some objects.
  2. As per the above image, you can see in image(highlighted as 2 in red circle) there is no WHERE clause in the SOQL Query. It would be better to create another box for WHERE clause like ORDERBY and LIMIT or make SOQL Query box as editable so the developer can add their WHERE clause to the query.

Inconsistent titles

The titles between the data preview tab, the soql file title (in the tab) and the soql builder UI are not consistent.

inconsistent-titles

OS and version: Mac OS 10.15.7
VS Code Version: 1.51.0

With Autosave Off, Preview does not reflect the state of the SOQL Builder UI

OS and version:
Windows 10

VS Code Version:
1.52.1

SFDX CLI Version:
7.82.1

Summary

When autosave is not turned on, the soql preview does not update to represent the actual state of the query. It appears that the onDocumentChange event does not get fired until the file is saved. And then it updates. This can cause confusion since the state of the inputs and the preview do not match. When the query is run, it is run with the soql query that is currently unsaved in the text document.
Short summary of what is going on or to provide context.

Steps To Reproduce:

  1. Open a soql query in soql builder
  2. Make sure autosave is off in your vscode preferences
  3. Adjust the query using the soql-builder form inputs
  4. Watch the preview panel of the soql builder is not updated
  5. Run the query and watch the results represent the state of the UI ( and the state of the unsaved soql query )
  6. Save the file and watch the preview update to reflect the true state of the soql statement.

Expected result

I guess that the soql statement in the preview should align with the state of the UI controls. And the state of the unsaved soql file. It might be nice for the user to know that this preview is not saved. Which could give them confidence to make changes and manipulate their query until they WANT to save the results.

I usually work with autosave on. So I expect the state of the UI, the preview, and the saved file to always be the same. But novice users may prefer to manually control saving the file.

Actual result

UI controls in the soql builder and the preview are not in sync.

Additional information

auto-save-turned-off.mov

Ability to view record from SOQL results

Is your feature request related to a problem? Please describe.
It would be nice to have an option with a link to view the record in salesforce.

Describe the solution you'd like
I would like to have another column which shows the actions to view the record in salesforce or show all the data of that record irrespective of what fields mentioned in soql

Describe alternatives you've considered
I need to select all the fields manually and then rerun the query, instead the option which automatically shows record details with all the fields would be a great plus

Additional context
None

W-8253055 - UX: No indication to the user that there is no default org set

Is your feature request related to a problem? Please describe.
When I open the SOQL builder with no default or set and click "run query", there is no indication that anything is happening and the extension appears broken. The only way to know that an attempt was made to run query is to open the output console and see a log to the channel.

Describe the solution you'd like
I would like some sort of reminder or notification that I need to have set a default org before I can run a query.

Describe alternatives you've considered
I would have to know to open the output channel and look for messages or logs.

Additional context
In this case, the text document contained a valid query but I couldn't run it.
Screen Shot 2020-10-22 at 11 13 55 AM

Unable to move between SOQL Builder and Text Editor tabs

Code Builder or Desktop:

Desktop

OS and version:

Catalina 10.15.7

VS Code Version:

Version: 1.51.1

Summary

Unable to click between tabs of soql file opened with both SOQL Editor and Text Editor

Steps To Reproduce:

  1. Right click a .soql file in Explorer
  2. Click "Open With..."
  3. Select "SOQL Builder"
  4. Edit the file (ie: "click a new field")
  5. Right click the same .soql file in Explorer
  6. Click "Open With..."
  7. Select "Text Editor"
  8. Click the tab with the "SOQL Builder" view
  9. Click back to the tab with the "Text Editor" view

Expected result

I should be able to click on the open "Text Editor" tab of the .soql file

Actual result

The "Text Editor' tab of the soql file is disabled (non-clickable). I can only close it but can't switch to the view.

Additional information

This may be a VScode issue? 🤷 . I'm trying to find some other extensions that offer "open with" capabilities to test.

unclickable-tab

W-8252962 - SOQL Builder - "Unsupported Syntax" may be confusing

Code Builder or Desktop: Both

OS and version: Linux

VS Code Version:1.50

Browser Version (if applicable):

Summary

When a query contains syntax that is not yet supported in the UI, an "Unsupported Syntax" error message is shown. This can be confusing to a user because it might imply that there is bad syntax, not simply syntax that is beyond the capabilities of the editor.

Steps To Reproduce:

  1. Create a file query.soql with contents SELECT Id FROM Account WHERE Name = 'HelloWorld'.
  2. Open SOQL builder editor. Note "Unsupported Syntax" message.

Expected result

A message is displayed that concisely conveys that the editor can't handle the syntax but there is no problem with syntax itself.

Actual result

User is presented with potentially confusing "Unsupported Syntax".

Additional information

SFDX CLI Version: 7.74.1

Pressing "Enter" on a selected field does not add the field to the query

Code Builder or Desktop:
Code Builder

OS and version:
Windows

VS Code Version:

Browser Version (if applicable):
Edge

Summary

When selecting fields in the SOQL Builder editor, a user should be able to use the arrow keys and pressing the enter key should add the field.

Short summary of what is going on or to provide context.

Steps To Reproduce:

  1. Tab to the Fields list
  2. Use the arrow keys to select a field
  3. Press enter

Expected result

The field gets added to the list when pressing enter

Actual result

The field is not added.

Additional information

Feel free to attach a screenshot.

SFDX CLI Version:

Field remove from SOQL query briefly re-appears

Code Builder or Desktop: Code Builder

OS and version: MacOS Catalina

VS Code Version: Version: 1.51.0-insider
Commit: 076245b1ce18bc0c262bb287b3fcad1575d756ae
Date: 2020-10-14T19:02:31.672Z

Browser Version (if applicable): Google Chrome 86.0.4240.75

Summary

Playing with adding/removing query fields

Steps To Reproduce:

  1. Select a few fields for the query
  2. Remove a field

Expected result

Have the field removed for good.

Actual result

The field disappears, then re-appears for a moment, and finally disappears.

Additional information

DeleteFieldReappears (1)

W-8253021 - SOQL Builder - Cache and logging needed for sobject metadata

Is your feature request related to a problem? Please describe.
For whatever reason, sometimes it takes minutes to load SObjects or their metadata. When the metadata is loading, I see "...loading..." but no indication that anything is happening. This is frustrating.

Describe the solution you'd like
Waiting so long for the fields to become enabled once is very frustrating. Waiting twice is unacceptable. The SOQL Builder should take advantage of a cache so that this wait does not occur more than once. Additionally, some output (say, on the "Salesfore CLI" channel, would be useful to indicate that we are trying to do something.

Describe alternatives you've considered

Additional context
I experienced these long waits while using Linux. It's hard to see how that has anything to do with it, but who knows?

Switch between Data API and Tooling API

Is your feature request related to a problem? Please describe.
SOQL queries are supported by both the Data APIs and Tooling API. The SOQL Builder should allow a user to switch between both APIs.

This is supported by the query commands in VSCode, the CLI and the @salesforce/core library.

(SOQL Query Builder) General Feature requests

Is your feature request related to a problem? Please describe.
General product feature requests

Describe the solution you'd like

  1. I want to to be able to see more fields at once (e.x. expand fields section)
  2. Fields should be ordered alphabetically, but Id and Name should be the first two fields, always - impossible to find what I need
  3. I want to see the field label and field type (e.x. Account Name, Name, Text)
  4. I want to traverse relationships (e.x. let me build Account.Owner.Name)
  5. I want to use Tooling API objects/fields and run Tooling queries
  6. When lots of fields are selected, the output table should scroll horizontally

Describe alternatives you've considered
Alternatives are to use other tooling, such as https://getjetstream.app/ - but sometimes it is nice not to have to leave my development environment.

Additional context
none

Limit field allows some non-numeric characters

Code Builder or Desktop: Desktop

OS and version: Mac 10.14.6

VS Code Version: 1.49.0

Browser Version (if applicable):

Summary

Limit field allows +-e..
image

Steps To Reproduce:

  1. Open SOQL editor
  2. Type +-e. in the limit field.

Expected result

Typing these characters is suppressed (like all other non-numeric characters).

Actual result

These characters appear in the limit field.

Additional information

SFDX CLI Version: 7.78.1

Traverse relationships

We aim for 1 topic per issue - This is a break out of a feedback from #124:

I want to traverse relationships (e.x. let me build Account.Owner.Name)

Nulls dropdown had no effect on order of query results or odd results

Code Builder or Desktop: CB

OS and version: Mac Mojave

Steps To Reproduce:

  1. Select some fields from Account
  2. Order by Name - ASC, Industry DESC, Nulls, LAST

Expected result

Nulls would be at bottom of query results - I need to understand the resolution order for options

Actual result

Nulls seemed to have no effect on Query results order when order has values (Name ASC ruled order)
When I deleted Order specific fields for ASC, DESC and just generally had order selected as DESC or --, null field was second result out of 3.
After running it with -- for Order and switching back to DESC, Query Results crashed with unhappy paper face icon.

Option to add all the fields of the object to a query

Is your feature request related to a problem? Please describe.
There should be an option in the SOQL Builder UI to use all the fields of an object in a query. Having to scroll and click on each field is not a good experience when an object has more than 5-10 fields.

Disable order-by button when invalid

Code Builder or Desktop:
Desktop
OS and version:
Windows 10 Pro version 2004 build 20251.1
VS Code Version:
1.51.1

Summary

"Order By" form button should be disabled until valid options are selected. Form should probably also clear after clicking "Add".

Screen capture

soql_builder_blitz_order_by_2020-11-12 12-23

W-8253095 - Soql-Builder Query preview does not match the text document.

Code Builder or Desktop: Both

OS and version: MacOS Mojave 10.14.6

VS Code Version: 1.50/0

Browser Version (if applicable): Chrome

Summary

When I open a .soql query with unsupported syntax, I am still presented with a preview of the query but there is a mismatch between what the preview shows and what the query in the text document is. I can still click "run query" if the query is valid and see results in the table view.

At the very least this is confusing as a user. It is hard to tell if the results I'm presented with represent the query in the preview or the text document.

Steps To Reproduce:

  1. From an sfdx-project create a .soql file.
  2. right click the file and select "open with...", chose the Text Editor
  3. paste in a query that contains unsupported syntax, such as the one below.
  4. reopen the soql file with the SOQL builder.
SELECT Name, AccountNumber, Type, NumberOfEmployees, BillingCity, BillingCountry, BillingStreet, Website 
FROM Account 
WHERE NumberOfEmployees >= 50 AND BillingCity = 'Tulsa'
ORDER BY AccountNumber ASC

Expected result

The preview should display what is in the text document, or I should be able to tell the source query of the results I am presented with.

Actual result

neither of the above

Additional information

Preview Mismatch

SFDX CLI Version:

Little white square shows up in Builder UI with no fields or object selected

Version: 1.51.0
Commit: fcac248b077b55bae4ba5bab613fd6e9156c2f0c
Date: 2020-11-05T18:14:40.758Z
Electron: 9.3.3
Chrome: 83.0.4103.122
Node.js: 12.14.1
V8: 8.3.110.13-electron.0
OS: Darwin x64 18.7.0

Summary

There is a little white square that appears with when there is no object and fields selected. This only seems to appear initially, like if you open an empty file or type a query "SELECT name FROM". However once an object is selected and the fields are populated. I am unable to get the square to show up again.

Steps To Reproduce:

  1. Create a new .soql file inside of an sfdx-project.
  2. Right click on the soql and open with the SOQL Builder
  3. There should be a little square in the Fields select element.

White Square in UI

Saved Query Results Not Revealed In Explorer

Version: 1.50.1 (user setup)
Commit: d2e414d9e4239a252d1ab117bd7067f125afd80a
Date: 2020-10-13T15:06:15.712Z
Electron: 9.2.1
Chrome: 83.0.4103.122
Node.js: 12.14.1
V8: 8.3.110.13-electron.0
OS: Windows_NT x64 10.0.17763

Code Builder or Desktop: Desktop

OS and version: Windows 10 (VirtualBox VM)

Summary

When a user clicks "csv" or "json" to save the query results then the newly created file is supposed to be revealed and focused in the file explorer. This is behavior we get when using MacOS. However in Windows, the file explorer is opened but the correct file is not revealed and focused.

Steps To Reproduce:

on Windows

  1. Click Run Query
  2. Click csv or json

Expected result

On MacOS

Reveal In Explorer MacOS

Actual result

On Windows

The explorer is opened but the focus is in the wrong spot

Reavel In Explorer

UI lists objects that can't be queried

Orgs enable entities around standard & custom objects that can't be queried (e.g. <custom object api name>__ChangeEvent) but these objects still get listed in the UI and allow the user to build a query.
These objects should not get listed in the SOQL Builder UI.

Screen Shot 2020-11-12 at 2 40 06 PM

OS and version: Mac OS 10.15.7
VS Code Version: 1.51.0

W-7987352: Soql Builder UX - Selecting an Object from the List - Needs Filter / Autocomplete Component

Is your feature request related to a problem? Please describe.
The list of objects available in the "From" dropdown is cumbersome. It would be better to be able to filter that list with a text input box that provided autocomplete and suggestions. Currently, the default select input, while functional, is overwhelmingly long.

Describe the solution you'd like
What i would like to have is a component that will show all the available selections, but also allow me to type and that would filter down the selections to match my typing. It should also offer the top match so that when i hit enter, i don't have to leave my keyboard or use the mouse.

Additional context
Google search as an example of the UX I'd like to see.

Screen Shot 2020-10-22 at 11 01 24 AM

Soql Builder - Limit 0 causes limit clause to be deleted

Code Builder or Desktop:
Code Builder

OS and version:
Mac OSX 10.14.6

VS Code Version:
Version: 1.51.0-insider
Commit: 076245b1ce18bc0c262bb287b3fcad1575d756ae
Date: 2020-10-14T19:02:31.672Z
Browser: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/86.0.4240.80 Safari/537.36

Browser Version (if applicable):
Version 86.0.4240.80 (Official Build) (x86_64)

Summary

When putting a 0 in the limit field of the UI, the limit statement is then deleted from the soql. My assumption is that LIMIT 0 is a valid statement so that a query can be tested without returning results.

Interesting though, for Low Code Users I wonder if a limit of 0 makes much sense. If they set the limit to 0, they likely want to get rid of the limit to the statement. And setting it to 0 vs deleting the limit text might actually be a valid interaction with the UI.

Steps To Reproduce:

  1. Set Limit to 0
  2. Notice limit statement is removed from soql.

Expected result

I guess i expected the limit to remain in the soql statement as LIMIT 0. But there is some question as to what Low Code Users might expect.

Actual result

limit-0

SFDX CLI Version: sfdx-cli/7.74.1-32db2396ed darwin-x64 node-v12.18.3

Fields listbox readability

Is your feature request related to a problem? Please describe.

It's a bit difficult to scroll through fields when there's a lot of them - especially if your eyes aren't so kind 👓

Describe the solution you'd like

It'd be nice to either let the user resize, have the list box expand with the window size, or even just make it a little taller than it is now. Another small but really helpful improvement would be to alphabetize the fields.

SOQL syntax highlighting is not working

Open a .soql file (using the Text Editor) and you'll see the query is not properly color coded. If you use VSCode's developer tools (Command palette > Developer: Inspect Editor Tokens and Scopes) you can verify that the query is not getting tokenized.

Screen Shot 2020-11-12 at 4 25 55 PM

Screen Shot 2020-11-12 at 4 25 48 PM

Screen Shot 2020-11-12 at 4 25 39 PM

Option to edit the query inside SOQL Builder instead of the text editor

We aim for 1 topic per issue - This is a break out of feedback from #124 and #128.

from @loktevich: on #124
Provide a way to edit SOQL query in the builder window

For now, if I need to edit a SOQL query I need to switch to the text editor. There is a readonly textarea field with the resulting query. Make it editable. It will also help to build complex queries with relationships and get JSON data for them before corresponding general features are implemented.

from on @brahmajitammana on #128
Option to edit the query inside soql query instead of text editory

W-8207695 - Refresh sobjects with new default org set

Code Builder or Desktop: Both

OS and version:

VS Code Version:

Browser Version (if applicable): any

Summary

If I have an instance of the soql builder open and no default org is set, then I set a default or, the UI does not refresh to represent the sobjects in my new default org.

Steps To Reproduce:

  1. open a .soql file with no defualt org set
  2. Then set a new default org

Expected result

sobjects should be populated to reflect the new org

Actual result

Nothing happens, I have to close and re-open the soql file to retrieve the sobjects

Additional information

SFDX CLI Version:

W-8580564: Querying for related records introduces unnecessary data

When running a query that gets data from a field on a related object it introduces data that was not queried for.

Sample query:

Select childobjectname__c, fieldname__c, isCascadeDelete__c, z_ChildSObjectDescription__c, z_ChildSObjectDescription__r.Name, z_ChildSObjectDescription__r.isDeprecatedAndHidden__c  FROM z_ChildRelationship__c

Screen Shot 2020-11-12 at 3 12 29 PM

This causes the JSON result to include a new object in the result.
related_query_json

It causes the CSV output to have a column with [object Object] value which hides all the data that was queried for.
related_query_csv

Unclear source of query runner "invalid syntax" notification

Code Builder or Desktop: Both

OS and version: Linux

VS Code Version: 1.50

Browser Version (if applicable):

Summary

When 'Run Query' is run on an invalid query, a notification is popped that tells the user that there is invalid syntax. It is not clear that the message is coming from the Query Runner. A user might think it is coming from the SOQL Builder. If the user cannot tell how to fix the syntax using the SOQL Builder (the editor has very limited syntax error recognition), the generic message in the notification may not be enough for the user to address the problem. Since the error has presumably come back from the org, I wonder if there is some more helpful information in the org's response.

Steps To Reproduce:

  1. Create file query.soql with contents SELECT FROM.
  2. Open file in SOQL Builder.
  3. Press Run Query. Note the '... invalid syntax ...' notification.

Expected result

The notification message contains some indication that it was running the query that caused it to pop (this is not clear since there is some communication delay between pressing the button and receiving a reply from the org). It also contains root cause information that may help the user address the problem.

Actual result

The notification of unclear origin says: "Your query contains invalid or incomplete syntax. Fix the syntax errors and try again."

Additional information

SFDX CLI Version: 7.74.1

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.