News for hackers. Stuff that matters.
Re:PRQL – A proposal for a better SQL by emteycz on Monday January 24, 2022 @03:52PM (#30063863)
I'd agree if there was any way whatsoever of fixing this issue, but there simply isn't. The editor can't even begin to guess what you might want until you write your FROM.
Re:PRQL – A proposal for a better SQL by taeric on Monday January 24, 2022 @04:14PM (#30064134)
Maybe in gigantic systems with more tables than makes sense. Realistically, all of the columns available in a database can be fit in memory with ease.

Then, the ide could basically fill my from out for me, based on what I'm asking for. Can even suggest what join I will need, if I list columns from multiple tables.

Re:PRQL – A proposal for a better SQL by tester756 on Monday January 24, 2022 @04:29PM (#30064311)
>Maybe in gigantic systems with more tables than makes sense. Realistically, all of the columns available in a database can be fit in memory with ease.

Every table has more than one column

So there's always more columns to remember than tables and generally tables are pretty easy like user invoices blabla

I worked with systems that had like 500 tables and some of them with 20-50 columns

you really want good intellisense in such a environment

Re:PRQL – A proposal for a better SQL by taeric on Monday January 24, 2022 @04:36PM (#30064392)
500 times 50 is still not a big number. And you could do decent statistical suggestions on the current columns in.

Good intelligent suggestions is, of course, helpful. And I agree that suggesting one of 500 is easier than the other. That said, neither is hard for a computer. And even asking friends what table I want will often be done with starting with the actual columns I want.

Re:PRQL – A proposal for a better SQL by tester756 on Monday January 24, 2022 @04:38PM (#30064411)
On the other hand I don't see why it couldnt work both ways

if you start query with

SELECT MiddleName then you could receive auto complete thats adds "FROM Users" and moves your cusor after MiddleName.

if you start query with

FROM Users SELECT _ and know intellisense drops list of columns

Re:PRQL – A proposal for a better SQL by taeric on Monday January 24, 2022 @04:48PM (#30064531)
Agreed. I'm really just arguing that it doesn't have to be from first.