1040 points · by Dowwie · 1y ago · 407 comments
I'm not sure whether or not it's better to have your editor database-aware or to have your codebase have appropriate context committed. On one hand, less generated code/artifacts make for a cleaner codebase. On the other hand, not everyone uses VC Code or will know how to use this integration. Database browser GUIs have never really had a single winner. That said, VS Code does have enough dominance to potentially make themselves "the standard way to view a database in development"
That code might in turn have plugins or feature flags that mean you don't know the concrete sql schema until runtime.
Same for seed data and migrations.
So it depends on the use-case how useful this format is for tooling and discovery vs an actual connection to the database.
Often times, the indexes will reflect this. Often times, not.
Jeff Bezos famously said[1] that anyone who does otherwise should be fired, and I agree.
How do you keep that all in sync across your apps?
I'm curious, do you output triggers, store procedures, and such? Many tools seem to stop after you've defined tables, columns, and indices, but I'd love some better tooling to make use of the rest of the DB's features.
And curses. Now I'm going down another rabbit hole rehashing ways to interface with my database in a side project that is doomed to never get past the "there has to be a better way to…" phase ;)
You're adding a round trip to the database and the LLM and inserting a tool call in the conversation before it even starts generating any code.
And the reference Postgres MCP implementation doesn't include Postgres types or materialized views, and is one of the most widely used packages: Zed.dev's MCP server for example, is seemingly just a port of it and has the same problem.
If designed well - by suspending generation in memory and inserting a <function_result>, without restarting generation and fetching cache from disk - the round trip/tool call is better (costs the equivalent of 50 tokens for waiting + function_result tokens).
Quite amazing they put the effort into this for Postgres instead of SQL Server. The demand must be a lot higher.
See here for the SQL server extension: https://marketplace.visualstudio.com/items?itemName=ms-mssql...
Just to clarify on the Azure Data Studio (ADS) point: the MSSQL extension includes many of the core features from ADS, but our strategy is slightly different and focused on a modern, developer-first experience.
Here’s the link to our open roadmap—would love to hear your thoughts: https://aka.ms/vscode-mssql-roadmap
Both teams seem to very much want developers to enjoy their tools, so please do send them feedback on what you need out of the tools.
Follow Carlos Robles if you want SQL server extension news: https://www.linkedin.com/in/croblesm/
Follow Joshua Johnson for PostgreSQL server extension news: https://www.linkedin.com/in/johnsonjoshuae/
Not to mention that SQL "SDK-style" projects only work properly in VS Code, so Visual Studio users are left out in the cold having to deal with an incomplete, half-baked solution.
The biggest problem with the usability of Microsoft products today is short-sighted thinking. New features, platforms, frameworks etc are launched and then forgotten about just a few years later with no effort to tie into the groundwork of what came before.
You might think this is only a problem for old customers who are already accustomed to the old technologies, but that's not true: it burdens new customers too. There's a few reasons for this that I can think of.
1) It's hard for new customers to know what technologies they should be reaching for in what situations when there's so many different choices.
2) It's hard to find the right documentation for the technology you've picked because you have to browse through a ton of out-of-date documentation that wrongly refers to the deprecated technologies and it's not clear what the current recommendations are.
3) The new stuff is often built without consideration for the ways of thinking that the underlying platform was built with. Thus, you end up with weird idiosyncrasies as you move from one technology to another, which make it hard to learn and hard to use.
4) When you replace the old technologies you lose the benefit of community knowledge on platforms like Stack Overflow, you lose the ability to look at existing open-source projects for guidance, etc. You are basically going into uncharted territory where there are no clearly established patterns in the wild.
So, even new users coming on to your platform suffer from these deficits. That's not to say I don't appreciate all the work on these new powerful technologies like VS Code and .NET Platform and so on, but I think a more long-sighted vision for these products would go a long way. And it's not just a matter of looking forward, since you never know what's going to happen in the future with a product as organizational priorities change. It's also a matter of looking backwards at what came before, at what groundwork was laid by previous efforts, and how it can be best taken advantage of and re-used for future efforts. That is the biggest missing piece at Microsoft today in my opinion.
Feel free to connect with me on LinkedIn, and we can go from there: https://www.linkedin.com/in/croblesm/
ADS is being sunset, and I was surprised when trying to install the Postgres extension on VS Code to find that it had its last meaningful contribution 6 years ago [0]. It couldn't work on newer VS Code versions.
I use ADS with both Postgres and MSSQL, prior to this announcement, I kept using ADS because there was nothing to migrate to.
[0] https://github.com/microsoft/vscode-postgresql/commits/maste...
We’re still working on bringing over some Azure Data Studio features to the VS Code extension, especially around import/export (like flat file and DACPAC). I’d love to hear what else you think is missing.
If you’re interested, here’s our open roadmap: https://aka.ms/vscode-mssql-roadmap
I'm assuming they might want to move SSMS to VSCode in time, so trying it out by covering new ground, PostgreSQL, makes sense to me.
[1]: https://learn.microsoft.com/en-us/ssms/sql-server-management...
As I’ve mentioned in a few other threads, the PostgreSQL team recently forked our MSSQL extension to kick off a fresh implementation for Postgres. It’s built on the same foundation we’re actively improving and evolving for both extensions.
From a consumer perspective, we're almost all benefiting.
From a business perspective, they get unpaid help and community brownie points.
Given that there are many Microsoft closed source extensions for VS Code, that cannot legally be used with the open source Version of VS Code, I would say they are not going all in. Knee deep maybe.
Embrace, extend, extinguish.
I've helped create apps that support millions to hundreds of millions of revenue on Azure SQL Databases that cost at most a few hundred dollars per month. And you can get started with a S0 database for $15/mo which is absolutely suitable for production use for simple apps.
Unfortunately, I think Microsoft realized how good of a value the DTU-based model was, and has started pushing everyone to the vCore model, which dramatically increases the barrier to entry for Azure SQL Database, making PostgreSQL a much more attractive option. If Microsoft ever kills off the DTU purchasing model of Azure SQL Database, I likely won't be recommending or choosing Azure SQL Database at all going forward. It'll 100% be PostgreSQL.
When the client brought some 3rd party expert and he advised rewriting to MySQL, I quickly did the math and it was like $60/m, without a free year.
We continued with DTU MSSQL with Prisma ORM and never regreted.
But they charge you an arm and a leg for the pleasure, but it can be worthwhile for enterprise.
MSSQL is extremely, extremely capable as a database engine.
But it also costs an arm and a leg. People who haven't used it don't know just how capable it is.
The reason people don't use them more often is that they're not free or even inexpensive.
plus they can take notes from Open source DB like postgress and improve their system better
that's every SQL server out there included Postgres. Is NoSQL considered as none-legacy?
How do I install this on Neovim then? Is there a LSP? Or is this Microsoft proprietary? I wonder how much better without Copilot integration this is then the competition.
I'm using DBeaver CE currently. Does all I need (also for SQLite).
Once you start reading press releases with this business-dictionary, it gets a lot easier to just close the tab and move on.
I don't want to poop on open source, but pgadmin and dbeaver and not even close to playing in the same league.
I work in Oracle and Datagrip saved my sanity.
In my experience, DataGrip has been easier to get up and running out of the box and bringing the big IDE guns than DBeaver but DBeaver also does done this really well. For example I have never been able to setup DG with Access but DBeaver works pretty good out of the box with that garbage. Also it's free.
Both are solid
I think it's worth downloading the 30 day trial and giving it a quick whirl. The people who dislike it seem to get hesitant quite quickly, so I doubt you'd need more than a day to decide if it's for you or not. There are all kinds of cool and fancy plugins you can set up, but I wouldn't bother with that if you decide the UX just isn't for you.
It supports quite literally every database I've thrown at it, which is pretty nice.
The way it support projects is also rather useful to me as a developer. Most SQL tools seem to be focused on being an interface first and maybe having a few SQL files open second, but Datagrip's basis as an IDE makes it very easy to maintain collections of scripts (version migrations etc).
That said, I'm not sure if the 99 bucks (a year if you want updates, though you get a perpetual license for the current version) is worth it. I use it because it's part of Jetbrains' all products pack, which I paid to use other IDEs, essentially giving me Datagrip for free. If you're not already a Jetbrains customer you could definitely give it a go, but the value per dollar it provides is very different.
My company had some leftover Datagrip licences, and it felt like moving from notepad to an IDE. I haven't looked back since.
As you suggest however, tooling for that workload is pretty rare. I want something that focuses on enhancing the database development experience: that understands that there are development workflows for database code which are well controlled and rigorous. So many database tools are focused on being system administrative aids first, or giving you features for directly interacting and <ack> altering the running state of the database and its server from the tool.
The best tool I found for what I do was targeted at Oracle: Allround Automation's PL/SQL Developer (https://www.allroundautomations.com/products/pl-sql-develope...). It's a development oriented tool that, at least last I used it, was focused on serious development work rather than administrative work. Now, I haven't used it in almost 20 years when last I did Oracle development... but I haven't found anything for PostgreSQL that has that thoughtfully implemented database developer centric feature set.
Today I muddle through with DataGrip. DataGrip has just enough of what I need that it's marginally better to work with than just a simple text editor... and also narrowly avoids some misfeatures as not to negate it's utility.
I loved workgroup style app development. R:Base, Access, dBase, FoxPro. Then I switched to UI work for a stretch.
Circling back to back-end work, naive me embraced Hibernate (2004?), assuming it'd be familiar and good.
I was wrong.
Now that I have a lot of free time, I'm finally recreating the workgroup style experience, for the general dev population. Sort of.
Using Hibernate, our workflow became: rough in some ORM hack, capture the generated SQL, use SQL Query Analyzer and Toad to make it work (and performant), coerce Hibernate to regenerate the SQL we want. Totally backwards, right?
Eventually we gave up and just used HQL.
At that point, why even bother with ORM?
So I created a "SQL first" workflow. Treat your SQL (DML) as source code, use those explicit queries to generate the prepared statements (and typesafe DAOs, DTOs, etc). In other words, auto-generate all the things you'd do yourself, if only you had more time.
I used my tool for years. Am currently making it usable for other devs. eg Spent last week making my grammar for MySQL "good enough" for initial release. Already have PostgreSQL and SQLite, plus my original turrible "poor mans SQL" grammar (comparable SQL-92). Which I'll cull once I have "good enough" T-SQL and PL/SQL grammars.
Any way. Thanks for reading.
I only meant to confirm your experience with development DBAs. The only such person I was able to retain was near retirement and was tired of the hustle.
I much prefer JB's git integration, but I wouldn't discount it just because the UI is so completely different.
Here's the talk where I used it: https://www.youtube.com/watch?v=k6Vm2hakkV4
I also did a theater session at our MSFT booth, but the recording isn't up yet. You can follow the steps in this repo to check out all the features that I demo'd, however: https://github.com/Azure-Samples/postgresql-extension-playgr...
Let the team know about any issues here: https://github.com/microsoft/vscode-pgsql/issues
I'm an emacs user and even I keep a copy of VSCode installed just because I occasionally have to interact with SQL Server and it's really the best way to do that on non-windows systems now that they're winding down ADS.
There are tons of enterprise development workflows, and plugins, that probably will never be ported into VSCode, from their .NET and COM implementations.
Now in terms of mindshare, and gateway drug into Microsoft ecosystem, definitely VSCode.
It is also the best Web IDE, for the return of timesharing development, sorry cloud.
That alone means everyone that is on Github and Azure, gets to use it as the modern version from X Windows and RDP/Citrix sessions.
Not bad, for Eclipse v2 (Enrich Gamma is one of the main architects), pity the whole Electron shell though.
FWIW I use it via Linux .deb and integrate with a private GitLab.
Azure, Github, CoPilot, .NET (why do you think it is cross-platform), Java (yes, MS is back in Java land, they were the ones with initial ARM support), Go (they have their own FIPS compliant distro), Python (although with layoffs maybe not anymore), Rust, npm, Powershell, Powerapps, 365 AddIns, Teams plugins, clang/cmake (part of Visual Studio installer), Azure Linux, Sphere OS,....
Once you're gonna play with azure, GitHub, vsc, you're bit by bit invested in the ecosystem and opening the wallet for that other feature or integration.
Also the best webdev IDE.
It was never marketed like that, for the simple reason that popular VSCode languages like Python/HTML/Javascript were never well supported by regular Visual Studio, so there is no way to move to "proper" Visual Studio if you do Python/web development.
It is becoming common for some to use Rider primarily, but VS is still used as part of the build system.
When was that?
Any tab called be pulled into its own window and moved to a different screen.
Even the terminal panel can be popped out into a tab or panel or window. (The UI is not obvious but once you see it you can’t unsee it)
It’s pretty cool to have the code and terminal side by side in the editor window. (Of course this was always possible with emacs)
Maybe it's because my tolerance for imperfection is much lower for databases than web apps, but it is so bad that I can't trust it for anything database-related beyond text transformations and generating boilerplate queries. It will incorrectly tell me things like postgres doesn't support TABLE OF <TYPE>, or make syntax errors for ON CONFLICT, and immediately agree with any "what about" or "are you sure" I throw at it.
Curious if anybody else has run into this. Obviously LLMs are not always great in specialized domains like this but the poor performance with something as popular as postgres is pretty uncharacteristic IMMO.
Does anyone here feel that the graphical editors actually save them time or make their lives easier?
But with DataGrip I could just pull the row I was interested and paste in the string from the UI.
Surely there's another workaround that wouldn't involve a UI but this made it pretty easy.
You put too many bezier curves on a page on my eyes go cross. They don't even bother to make the lines different colors. Just a bunch of white curves against a fixed grid layout. Wut?
It's taking well structured data and then destructuring it into an inaccurate sloppy picture. I don't get it.
Like, you can make websites graphically with DreamWeaver (or something), but I think most people say that you're better off using HTML and CSS and whatnot if you know how to use that.
Is this GUI stuff something people who are good at SQL actually use or is this mostly for new people?
My first step was to look at the data using the UI. Then when I tested my queries, I also just ran them in the UI.
It’s just faster.
I never used the UI for “simple” queries since there wasn’t anything to test.
In my opinion, i see that graphical editors are more product for major section of devs and admins.
New query could still get results.
Overall, it should have been a separate app because you can't really see all the results in a small panel.
The team is very receptive to feedback, in my experience.
I got my hopes up for nothing
Data grip for big serious stuff.
It makes me wish for something like phpmyadmin or adminer
This is also what's said here by one of the devs: https://github.com/microsoft/vscode-pgsql/issues/15
Looks like manually loading the VSIX to bypass the compatibility check should work but who knows how stable that'll be.
I imagine later LLM have access to my table metadata and then perhaps down the road, LLM can suggest me better queries based on execution plans that it saw.
Also like with dbeaver that you can take the results and export them in many different formats. like directly to excel for some of my co-workers who live and die in excel.
I don't understand why the first four points under this heading are basically the same.
If love for there to me a "rename variable" feature.
am I the only one to have that problem?
I really wonder why they would call it "server name" instead of database host though
It seems like all their copilots are seperate subs, which seems like a missed opportunity honestly.
[0] affectionately Crashional Rose
People have to stop pretending there were no IDEs before IntelliJ .
slowly development tools are catching up with the 90s
When you generate visualization, you should only show key table and key fields within the table and hide all the helper, secondary fields and tables.
In an LLM world this should be easy for LLMs to pick out key tables and fields and only display those
LLM here would be like another person or another team, that decides what's important for me, what I should see and what I should not. Might work, but I'd rather see the full picture and decide myself.
It’s going to be tough to beat SQLTools for Sublime Text (https://code.mteixeira.dev/SublimeText-SQLTools/). It’s simple, fast, does the basics right, and crucially, works for many of the usual suspects.
Most IDEs try to do everything and fail, yet only target one db vendor. They’re _all_ bloated and buggy, with endless trees and menus, bells and whistles. Results grids are slow, copy/paste is janky, formatting is never quite right—or outright misleading.
SQLTools stays out of the way and just works.
...also, I don’t want AI-powered nonsense. I’ll reach for that when I need it. Get off my lawn.
- neovim for file editing,
- zsh (+zoxide) for navigation / file management,
- plain git to manage my repos,
- plain text note taking and accounting, etc.
`psql` is pretty bad at it and in `\e` you will just end up in an editor, which will probably don't know about your schema.
I've tried many tools, but seems like I like DataGrip (or databases in PyCharm Professional) the most, so I use EAP from time to time, when I'm going to write a lot of SQL.
— autocompletion for everything — table/function names, types; very helpful on projects with hundreds to thousands of tables
— navigation ("jump to referenced table", "find foreign keys to this column", etc)
— data export in two dozen formats (configurable)
— exactly the same UI for working with 30 database engines (or however many it supports, I'm too lazy to count). Especially helpful with databases that have atrocious CLI clients, like Oracle.
— a nice tree-structured view of your database; or you can generate a (possibly vector) diagram for the rare case when that helps
— high quality autoformatter that works for every SQL dialect it supports, and in the same way
— minor things like the ability to extract a subquery with a couple of key presses, or rename a table alias
Probably something else I'm forgetting.
Saving a couple of keystrokes when writing SQL has little to do with it.
> The software is licensed, not sold. Microsoft reserves all other rights. Unless applicable law gives you more rights despite this limitation, you will not (and have no right to):[…] d) use the software for commercial, non-profit, or revenue-generating activities
Oops. Better not install this on your work laptop!
[0] https://marketplace.visualstudio.com/items/ms-ossdata.vscode...
Not only that but it damages the reputation of this community.
You (<-- I don't mean you personally, but all of us) should be welcoming to new users and assume good faith, as the site guidelines ask (https://news.ycombinator.com/newsguidelines.html). There's no reason why you can't make your substantive points while doing so. (Edit: you needn't look far for a good example: https://news.ycombinator.com/item?id=44074135.)
It might also be good to remember that everyone makes mistakes, that project launches don't always go perfectly, and that HN is for discussing the interesting aspects of a submission.
Its a public preview, for which Microsoft probably does not wish to accept non-disclaimable liabilities for defects when used in those circumstances.
It is for previewing. By people who are interested in what is in the pipeline for a more general release.
So you are saying that MIT/ISC/GPL/Apache2 and all the other OSS licenses do open you up to liabilites?
Edit: That's uncharitable of me. I strongly doubt that's the plan. But it genuinely was the first thing that came to mind.
Why would they spend money into this extension if 99% of developers can't use it?
no source, not a promising privacy policy
That's cool. How do I get this into JetBrains IDEs?
The main difference is that JetBrains supports a bunch of databases, not just one.
(I thought it was particularly nice when you could install most to the VS Code DB extensions standalone as "Azure Data Studio"; you can build separate VS Code profiles for your coding and DBA hats of course, but it's not quite the same feel as launching a separate, dedicated application. Though "Azure Data Studio" was often overlooked because it worked just fine on non-Azure hosted databases.)
JetBrains has always done their completion / language integration differently than VSCode + LSP, but it seems to work well. My only complaint is that GoLand organizes imports differently than gopls / goimports, but my knowledge there is a few years out of date. I've worked on teams with a lot of GoLand users and nothing has really bothered me on this front recently, so they probably fixed it years ago.
Yes, Intellj will recognize that the string in my code is an SQL statement and use auto complete and validation when it is connected to a database.
I've looked at the announcement and it seems that the functionality of Jetbrains is similar.
One benefit of using VSCode/Sublime Text/vim/emacs language integrations is that I roughly know what command to run to get the same results in the terminal as I get in the editor. With JetBrains does-it--all IDEs, I have no clue.
[0] https://www.jetbrains.com/help/qodana/getting-started.html
It does not care if the imports are organized differently. I like to do:
import (
# standard libraries
"fmt"
"io"
# our stuff
"github.com/pachyderm/pachyderm/src/internal/whatever"
# packages
"example.com/foo/bar"
"github.com/whatever/whatever/foo"
)
People/tools will remove the newlines or mix in local packages with upstream packages, and I decided not to care. I'm pretty sure nobody else cares.Good starting point: https://www.jetbrains.com/pages/intellij-idea-databases/
If this is “PGAdmin, but 50% worse, but it just lives as another tab in your editor instead of another application” that is genuinely a huge win for me
Probably that’s because my day-to-day isn’t actually database administration, it’s application development where I need to be able to work with a database from time to time — so the preservation of context, however marginal, is really nice.
It also recognizes your regular programming code strings as SQL and can also autocomplete/highlight typos, but I don't use that, because we're using JOOQ that generates code stubs from live DB.
Last time I tried to use it in my environment, it triggered too many 'external network requests' for the liking of our IT guy. We relegated it to the "Do Not Use" pile as a result.
Has this been resolved? Nobody in my team wants to use an IDE that sends data back to its masters ..
Check it out and get on the waitlist getgalaxy.io/explore/product-tour
happy to chat live with anyone if interested, support@getgalaxy.io
Not a good way to generate potential user interest or generally good feelings towards it.
Just saying.