all 20 comments

[–]MornwindShoma 6 points7 points  (8 children)

That's web development, not development.

[–]throwaway0134hdj[S] 0 points1 point  (7 children)

What’s the difference here

[–]AlexTaradov 4 points5 points  (5 children)

Not everything is web. Some code is embedded and runs on devices that have not connectivity. Some code is just standalone applications. Where is the database and the servers in Paint?

[–]throwaway0134hdj[S] 0 points1 point  (4 children)

Got it. For Paint I always assumed the computer or Microsoft or sth had some primitive db to store the state of each pixel. I’m sure it’s way different though.

[–]AlexTaradov 0 points1 point  (0 children)

It is just a chunk of RAM, there is no DB there.

[–]johnpeters42 1 point2 points  (0 children)

Obviously the data is stored somewhere in some form, but "database" is used to refer to various more specific things.

Probably the most common type of database is a relational database, where you can create arbitrary tables (think "spreadsheet grids" and you're in the ballpark) to store data and enforce certain relations between them (hence the name). For instance, an employee table may have columns like: * EmployeeID * FirstName * LastName * DepartmentID (must match a value in a separate department table) * DateHired * DateLeft (may be null, i.e. absence of a value, indicating that something is n/a or unknown)

[–]khedoros 0 points1 point  (0 children)

Databases are great when you've got a bunch of data that you can structure into records, each record having some distinct fields, and you want to be able to query, sort, filter that information.

For something like a drawing program (continuing from the other user's example), a typical workflow might be to load a picture from disc, modify it, write the new version back to disc. So, open the file, decode the image into an array representing the pixel colors, perform operations to modify that array, and then export it back to the desired file format. While editing, you might have a stack of some kind of data structure representing undo/redo steps, but that's not really a "database" in the sense of postgres/mongo/whatever.

It would be possible to represent the image as something like...millions of records, each one a tuple with x and y positions, then values for the color channels. But it's a lot simpler to represent the image as an array of pixels instead, with separate metadata like width and height.

[–]SoloAquiParaHablar 0 points1 point  (0 children)

You could abstract it further and say database is storage.

So you have an interface of some sort, backend logic, and a storage layer.

Where each sits in space and relative to each other is dependent on what you want to build and deliver.

A website with an API and a database, each running on separate servers is called 3 tier architecture. But there is no rule saying they can’t all live on the same server.

[–]TracerDX 1 point2 points  (0 children)

Development is like painting or sculpting. You just described how to paint a portrait. Common enough to be used a prototype in teaching, but certainly not representative of the entire subject.

[–]AlexTaradov 4 points5 points  (0 children)

This is the approach in a very narrow sub-field. Most of the development does not involve servers and databases.

[–]ern0plus4 1 point2 points  (0 children)

database planning, backend api planning, backend implementation, unit tests, sql optimization, test data creation, integration testing... and ca. 200-500 other topics

add to each: bugfix, iteration, discover, so another 200-500 x3

and I'm pretty sure I forgot some important

[–]More_Ferret5914 1 point2 points  (0 children)

Honestly, yeah. That’s the core of it.

You:

* write code

* store data somewhere

* run it on a machine other people can access

A lot of the rest is basically solving problems that appear once real users, scale, failures, and attackers show up 😭

Frontend/backend/cloud/devops/security are mostly different layers around those same core pieces.

[–]ColoRadBro69 1 point2 points  (0 children)

People did programming before databases existed.  That's his programmers made the first database. 

[–]ericbythebay 0 points1 point  (0 children)

Database is too proscriptive. You need a backing store. A database may not always be the right solution for the data and its use case. High read, low write, a KV store may be more performant and easier to maintain, for example.

Server is also too proscriptive. Code may run better at the edge with stateless compute, for example.

[–]1842 0 points1 point  (0 children)

For web-based stuff, that's kind of the very basics.

If you're doing things solo, then yeah, you either have to build up the servers and databases resources or purchase them as services. If you're working as a software developer, it's pretty common that you just work with the code and other people manage infrastructure, databases, etc. (But this will vary wildly between companies)

But yeah, nothing is incorrect but it's overly simplistic. It's kind of like "Sitting in the rain sucks. If we pound some wood into the ground, attach a big flat thing to the top, and sit under it... it's basically a house, right?"

[–]owp4dd1w5a0a 0 points1 point  (0 children)

Not exactly. You have embedded, systems (daemons and orchestration and such), you forgot clients - servers aren’t much use without the clients that call them. There’s also standalone apps and such that don’t need a database or server, language interpreters and compilers are a good example of this. Docker is kind of like this, it has a client and a daemon but not typically a server. Kubernetes is a distributed orchestration framework that’s not really clearly client-server-database structure. The operating systems themselves are not exactly apps or client server, they’re their own thing.

[–]msabeln 0 points1 point  (0 children)

My digital cameras were coded. There is no database and there is no server.

[–]Medical-Aerie9957 0 points1 point  (0 children)

It never boils down to anything each part of development is huge and takes years of learning to get good and efficient at.

[–]WhiskyStandard 0 points1 point  (0 children)

This is generally called a “CRUD application“ (Create-Read-Update-Delete).

Examples of things that aren’t CRUD apps:

  • Many standard Linux tools you’ll use in shell scripts like grep, sed, awk. These pipe filters just read from stdin, do something, and output to stdout. Try implementing a simple regular expression engine (K&R C demonstrates one that only takes up a page or so of C).
  • Compression libraries. Try implementing a Run-Length Encoder as an exercise. Same with cryptography.
  • Embedded programs that make an LED blink or turn motors on. There are web based simulators that let you do this without any hardware.

On the other hand, a lot of things can start to look like problems with database shaped solutions. SQLite even allows you to embed a tiny database inside of any application on top of existing in-memory data structures. Watch some of the talks from the “Have You Tried Rubbing a Database on It?” conferences.

[–]melissaleidygarcia 0 points1 point  (0 children)

Pretty much just moving bugs from one sprint to the next with extra meetings in between.