|
I've noticed that many people and/or companies think that SQL is somehow easier than programming.
I've even worked for a company where you were automatically a "SQL consultant" if you didn't know how to code.
Recently, I picked up a project for a company with 10K(!) procedures mostly written by a guy who didn't know how optional parameters work.
The result is that I've found plenty of simple front-ends with "SQL back-ends".
Basically a simple web app that just executes stored procedures on GET and POST requests.
The stored procedures are usually written by "IT professionals", "consultants" and managers.
The problem with working like this, SSMS is not an easy tool that formats your code (format is always terrible!), where you can search and debug or where you easily implement DevOps practices.
Completely unmaintainble.
|
|
|
|
|
Ah, yes, the "everything must be in a procedure" crew.
Also watch out for the "only DBAs can write SQL" crew.
|
|
|
|
|
PIEBALDconsult wrote: Also watch out for the "only DBAs can write SQL" crew.
Well in my experience it tends to lean way in the other direction. Without someone with some database experience they will not even attempt anything in the database except simple CRUD. Which of course ends up producing some really inefficient code.
|
|
|
|
|
jschell wrote: CRUD
PTUI. Don't even use that term around me. No one with proper database skills thinks in such limited terms.
My best experiences were where I would write the SQL and a DBA would point out improvements which could be made.
|
|
|
|
|
Sander Rossel wrote: companies think that SQL is somehow easier than programming
Well 'technically' that is true.
For the most part, especially the way companies use it the vast majority of time ANSI SQL is not that difficult.
However PL/SQL, TSQL, etc are not in fact ANSI SQL.
Nor for that matter is database design, optimization, etc.
Sander Rossel wrote: The problem with working like this,
Not sure where you are going with this.
Bad code is just back code. Bad designs are just bad designs.
The language is not the problem for either of those.
And ignorance of those problems certainly is not the fault of the language.
Sander Rossel wrote: Basically a simple web app that just executes stored procedures on GET and POST requests....The stored procedures are usually written by "IT professionals", "consultants" and managers.
But for most businesses, most of the code should in fact be simple. It should not require much more than that. It is pointless that everyone be a database DBA because there is generally no need for the expertise all of the time. So there will be some stored procs because that is all that is actually needed.
|
|
|
|
|
jschell wrote: For the most part, especially the way companies use it the vast majority of time ANSI SQL is not that difficult. True, but when it comes to complex business logic, SQL is really not the best tool for the job.
jschell wrote: Not sure where you are going with this. SQL just isn't the tool to build complex systems with loops, if-then-elses, XML and JSON parsing and generation, and even sending out emails.
I've seen stuff like writing to table variables within a transaction so that the data can be written outside of the transaction even when the transaction is rolled back... Or using temp tables because the table should be used across procedures, but still within a transaction while not losing the data on a rollback... Stuff of nightmares really.
And if that's what you're going to do with SQL it becomes very difficult very fast.
And there's just no way to debug all this unless you're going to set breakpoints (which isn't straightforward and will block your entire server, I've never actually seen anyone doing this besides myself).
Just because you can doesn't mean you should.
So yeah, I'm talking about actual programming in SQL (with all the limitations that come with it).
jschell wrote: But for most businesses, most of the code should in fact be simple. If you're running a multi billion multinational the code is never simple.
These are some of the customers I've seen this method of working.
jschell wrote: It is pointless that everyone be a database DBA because there is generally no need for the expertise all of the time. True, but these companies have their complex business logic written in SQL by people who don't even have the professional courtesy to format their code.
These people have never written code because they're not coders.
They're more accustomed to one-off scripts and that's how they write their not-so one-off SQL too.
Last week I met someone who had never seen a CREATE TABLE script and who didn't know how to write an UPDATE from the top of his head, and he maintains over 10K of stored procedures
I even met someone once who opened a new query window by right clicking on a table and creating a DROP TABLE script, he then deleted the script and so he had an empty query window
He was kind of surprised when I yelled "NO WAIT!" (this was on a production server) and I was even more surprised when he told me he always opened a query window like that.
I then showed him the new query button.
These people shouldn't even be allowed near a database, yet here they are, developing and maintaining huge databases for huge companies.
And my point is, these applications shouldn't be developed in SQL in the first place, but when it is, it should at least be developed by people with proper training.
And if you need people with proper training you might as well hire developers and pick the right tool for the job.
But I guess there's two things at play here, the Dunning-Kruger effect and when all you have is a hammer every problem looks like a nail.
So we have someone who completely overestimates his SQL knowledge and now every problem is solved using SQL.
|
|
|
|
|
Sander Rossel wrote: SQL just isn't the tool to build complex systems with loops
But again bad code is just bad code. That is not a language problem.
Sander Rossel wrote: If you're running a multi billion multinational the code is never simple.
But then they should have a DBA. Probably multiple DBAs.
And designs that optimize solutions before the code is written.
And budgets that allow for refactoring legacy applications (written when the company was very small.)
Like the above none of those are problems that the language can solve.
Sander Rossel wrote: Last week I met someone who had never seen a CREATE TABLE script and who didn't know how to write an UPDATE from the top of his head, and he maintains over 10K of stored procedures
And about 10 years ago a billion dollar company lost all of their business and went bankrupt because they were storing credit card information they should not have been.
I worked at a company where the DBA not only was not using source control he did not even know what it was.
But those are one-offs.
Sander Rossel wrote: (this was on a production server)
Same DBA above did all his work on the production server.
Sander Rossel wrote: the Dunning-Kruger effect and when all you have is a hammer every problem looks like a nail.
It is a messy world out there. That is not just true for programming. How many people are injured or even die each year because they are in a trench which has not been correctly shored up.
Perfection is an ideal that can never be achieved. And legacy systems are the norm in any business which is not a brand new start up. But even a start up is driven by cost/time constraints and not elegance.
|
|
|
|
|
jschell wrote: But again bad code is just bad code. That is not a language problem. Never saying it wasn't.
Really, my only point is that SQL was never meant to write complex applications in, but people who have no clue about SQL do it anyway.
jschell wrote: I worked at a company where the DBA not only was not using source control he did not even know what it was.
But those are one-offs. A one-off?
Think again, I've never met a DBA who knew about source control and I've never seen a database in source control.
Been doing this job for 13 years now and I've seen quite a few companies in that time.
jschell wrote: But then they should have a DBA. Probably multiple DBAs.
And designs that optimize solutions before the code is written.
And budgets that allow for refactoring legacy applications (written when the company was very small.) Like you said, it's a messy world out there.
If it works then why would a manager with no clue about IT make room in his budget for designs and improvements
|
|
|
|
|
Sander Rossel wrote: Been doing this job for 13 years now and I've seen quite a few companies in that time.
I have been doing it 40 years.
Doesn't mean it doesn't happen, just that most companies, especially over time (and perhaps disasters) become more aware of it.
Sander Rossel wrote: would a manager with no clue about IT make room in his budget for designs and improvement
In my experience (above) because developers ask for it. Sometimes it is even driven from higher up just because managers are aware of things like costs of non-supported hardware/software. But also because developers can decide that the existing technology does not allow for new features.
I worked for a bank that delivered credit card payments in text files which was created from a COBOL system. They could no longer add features which would show up in the records because the COBOL system had reached the maximum record size.
|
|
|
|
|
Just in case other CPians consider joining the crew in GTA V
Epic is giving a 50% discount on "GTA V Premium Edition" for the next 4 weeks
M.D.V.
If something has a solution... Why do we have to worry about?. If it has no solution... For what reason do we have to worry about?
Help me to understand what I'm saying, and I'll explain it better to you
Rating helpful answers is nice, but saying thanks can be even nicer.
|
|
|
|
|
So, as I understand it, the "Premium Edition" amounts to...a $1,000,000 bonus to get started.
I hope R* doesn't think of itself as generous with that sort of offer.
[Edit]
Still, $15 is pretty decent for anyone who's never purchased the game...
|
|
|
|
|
To be honest... I don't know the differences or the contents. I was just having a look and I saw the offer.
M.D.V.
If something has a solution... Why do we have to worry about?. If it has no solution... For what reason do we have to worry about?
Help me to understand what I'm saying, and I'll explain it better to you
Rating helpful answers is nice, but saying thanks can be even nicer.
|
|
|
|
|
Neither did I, and that's about the only thing I could find based on their description. That, and as OG pointed out, the criminal enterprise starter pack.
In other words, their definition of "premium" amounts to something you can obtain for yourself anyway after just a few hours of gameplay. Not unique/exclusive stuff that you can't get otherwise...
|
|
|
|
|
dandy72 wrote: In other words, their definition of "premium" amounts to something you can obtain for yourself anyway after just a few hours of gameplay. Not unique/exclusive stuff that you can't get otherwise... So, making money out of buzzwords and not-knowing by potential customers...
Not sure if that is a good idea.
M.D.V.
If something has a solution... Why do we have to worry about?. If it has no solution... For what reason do we have to worry about?
Help me to understand what I'm saying, and I'll explain it better to you
Rating helpful answers is nice, but saying thanks can be even nicer.
|
|
|
|
|
Nelek wrote: Not sure if that is a good idea.
Well, it worked out for them, given that (according to multiple sources) the game has made them oer $6B (and counting)...
|
|
|
|
|
You do get the Criminal Enterprise Starter Pack[^] which gets you an office and bunker. A poor excuse for a bunker, but ... it's a start.
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
"Common sense is so rare these days, it should be classified as a super power" - Random T-shirt
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
OriginalGriff wrote: A poor excuse for a bunker,
That's kinda like the "free" arcade in Paleto Bay.
Can you imagine starting every casino heist with that drive?
|
|
|
|
|
I think the free bunker is worse, purely because even with the Chumash bunker some of the sell missions in LS can be pretty tight on time - particularly if you have a lot in stock.
With Paleto, you've added a five minute drive to that before you get to the actual deliveries part. That's pretty much why I used Paleto only for research and didn't make any weapons until I moved to Chumash.
"I have no idea what I did, but I'm taking full credit for it." - ThisOldTony
"Common sense is so rare these days, it should be classified as a super power" - Random T-shirt
AntiTwitter: @DalekDave is now a follower!
|
|
|
|
|
#Worldle #483 2/6 (100%)
π©π©π©π¨β¬β¬
οΈ
π©π©π©π©π©π
https://worldle.teuteuf.fr
had to use map
"A little time, a little trouble, your better day"
Badfinger
|
|
|
|
|
Need to do some landscaping around the house. The gravel around the sides of the house has settled; weeds are getting in; needs to be topped up.
Now, there are multiple places where you can order or pickup; different prices and delivery conditions. Also, you need to decide the "size" of the gravel. Or if you want a certain color; or "polished". Not sure what the "size" of my gravel is; I will need to measure. You can order a fixed size; or a "range", say: pebbles from 1.25 inches to 3 inches. Maybe a spread sheet will help.
Yesterday she said: "I ordered a yard of gravel ... it comes Monday."
Oh, okay.
"Before entering on an understanding, I have meditated for a long time, and have foreseen what might happen. It is not genius which reveals to me suddenly, secretly, what I have to say or to do in a circumstance unexpected by other people; it is reflection, it is meditation." - Napoleon I
|
|
|
|
|
If you are making a garden railway you will want "quarter-minus" gravel, not pea gravel.
P.S. You missed -- The first Saturday in May is World Naked Gardening Day.
modified 19-May-23 15:35pm.
|
|
|
|
|
Install asphalt surface to show dominance.
Advertise here β minimum three posts per day are guaranteed.
|
|
|
|
|
And let me guess, she's going to be busy elsewhere while you have the opportunity to move the gravel to the correct place.
Hope she likes what she ordered.
Iβve given up trying to be calm. However, I am open to feeling slightly less agitated.
Iβm begging you for the benefit of everyone, donβt be STUPID.
|
|
|
|
|
She usually offers to help but that just means I'm supposed to work faster ... so I just say: that's ok too.
"Before entering on an understanding, I have meditated for a long time, and have foreseen what might happen. It is not genius which reveals to me suddenly, secretly, what I have to say or to do in a circumstance unexpected by other people; it is reflection, it is meditation." - Napoleon I
|
|
|
|
|
I'm a little grumpy and have read way too many "tech X sucks" (and I'm responsible for some of them).
So what do you love about the languages you use?
I'll start.
C#: It runs everywhere. macOS, Linux, Windows, Raspberry Pi's, in the browser via WASM, on mobile devices, you name it. Literally every platform I support I can write code using C#. The type safety and static checking is amazing, the syntax (generally...) very clean, and given it's basically the grandson of C, the syntax is like my Mother Tongue.
Python: Again, it runs everywhere, and it often runs everywhere because it's built in by default everywhere. It's interpreted so awesome in notebooks, great to run on the command line to quickly test something, and there's just so, so much code out there. Sure the indents take getting used to, but no brackets certainly cleans the place up.
JavaScript: I love it because I deploy it one: on my server. It then runs everywhere there's a browser and I never have to worry about hardware or libraries or graphics cards or harddrive space. If there's a bug I upload a new version and everyone, immediately, is also updated.
What about you lot?
cheers
Chris Maunder
|
|
|
|
|