Asked by:
SQL. connectiondstrings? entitity? xml? performance?

Question
-
User-1982615125 posted
hello,
im drowning in SQL.
i googled how it worked. i added a connectionstring to the web.config and then the documentation just ended. whut?
then i found another sample of code that added a row to a table, ignoring the connectionstring alltogether. whuuut?
there is also a huge disconnect between the continuety of documentation using a .mdf file in app_data, or actually using a SQL process.
then there is also entity framework which makes all of it even more fragmented. (please do not explain entity to me, i will explode).
im now useing xml serialisation of classes. it takes 2 seconds to read and write the file which is now 18MB big. but ive seen it escalate to 1,7GB!. i really prefer now everything is typed, and i can just use it as native code because its all still .net objects.
how do i simplify my life now?
im personally not a fan of the outdated database idea. it should be serialised by the api. and we should be able to use it as class objects. instead of commands. just the idea of commands, im feeling depressed already.
i can only imagine the file lock and keeping the sql file in memory by using the sql process saves reaction times. but actual processing would be slower using commands, or do i understand that wrong?
for example, how fast would a 10k rowed table react if i wanted to read all of them out? it would mean it all has to be transfered over TCP.. man.. just the idea!! or does a database process have processing abilities? i can imagine that you could use conditions in the command query, which only has to transfer the affected results over TCP.
please make me happier. its been going on for a while. it makes me so depressed, im pausing all my projects.
Monday, January 8, 2018 5:08 PM
All replies
-
User475983607 posted
im now useing xml serialisation of classes. it takes 2 seconds to read and write the file which is now 18MB big. but ive seen it escalate to 1,7GB!. i really prefer now everything is typed, and i can just use it as native code because its all still .net objects.
how do i simplify my life now?
An XML relational data store is much slower than a database unless the XML file is a few k bytes. Keep in mind that the serializer is using reflection to parse the XML nodes to create an object.
im personally not a fan of the outdated database idea. it should be serialised by the api. and we should be able to use it as class objects. instead of commands. just the idea of commands, im feeling depressed already.Huh? databases are outdated?
for example, how fast would a 10k rowed table react if i wanted to read all of them out?It depends on the size of a record.
it would mean it all has to be transfered over TCP.. man.. just the idea!! or does a database process have processing abilities?It's unusual to transfer 10k records to the UI. Yes a database can process result sets as that's what databases are designed to do.
i can imagine that you could use conditions in the command query, which only has to transfer the affected results over TCP.Yes, a WHERE clause filters the result set.
Monday, January 8, 2018 7:09 PM -
User541108374 posted
Hi,
please always provide the links to the parts you're talking about (in this case the documentation pages you mentioned).
fazioliamboina
outdated database ideaWhere did you get the idea that databases are outdated? They're more relevant, albeit in different flavors like relational, noSQL, document databases etc, than ever.
fazioliamboina
just the idea of commands, im feeling depressed alreadyStill one of the fastest way to obtain data from a database in combination with a SqlDataReader. If you don't like writing commands, can't blame you there, take a look into Entity Framework or nHibernate or dapper or any other ORM framework to make your life easier.
Tip: reading from disk is way slower than reading from a database or memory.
Kris.
Tuesday, January 9, 2018 12:32 PM -
User-1982615125 posted
im not ready for all that stuff yet.. i cant even seem to get my database accesable. i even tried books, but i just dont get it.
ive been able to setup and work with an oracle database within 15 minutes in school. i think documentation and the internet as a whole should be controlled!! there is no way to find proper or relevant information anymore.
and yes databases are VERY outdated. its just that in your head there is way no imagine something newer because you are talking 'relevant'. its based on 90s technology, and it completely sucks. to make databases great we need to restructirise how the internet and OS isolation works as a whole. to start with, i would want to browse the database tables trough intellisense. not using commands, this makes tcp already absolete to use. entity is just making it more work, it shouldnt be neccesary, its just here because of the bad design in the first place.
the webbrowser is also outdated. people are not able to make proper websites, so there is no potential greatness in webbrowsing anyway, i see no future in it, and at some point in alternaty it gotta be replaced anyhow. satya nadella knows this, he was chosen because he recognised the problem at microsoft that they where trying to ideal up existing crap with quality microsoft replacements. but thats not how we grow. we grow be inventing new things, and thats what microsoft is trying to do. they do one thing at a time, and i dont see how databases will be on the priority list anytime soon.
the market share of webbrowsers and websites is waay to big to be overwon by something more superior.
id say we should throw away anything digital we know, and rebuild this planet without any market share affecting our progress.
Monday, January 15, 2018 12:10 AM -
User541108374 posted
Hi,
fazioliamboina
there is no way to find proper or relevant information anymoreThere has never been so much documentation and information around as nowadays. Like https://docs.microsoft.com/en-us/aspnet/entity-framework.
fazioliamboina
at some point in alternaty it gotta be replaced anyhowThat's what they're trying to do with conversational UI's like chatbots.
fazioliamboina
they do one thing at a timeThey do a lot of things and invent a lot of new things all the time, in parallel. If you only take a look at HoloLens, Azure cloud computing, Surface books, Teams, ...
Actually I noticed one of your former threads https://forums.asp.net/p/2130620/6173198.aspx?Re+keeping+an+object+in+memory+when+working+with+models where you basically complain about the same thing and that you don't want to learn SQL. If you dislike ASP.NET / SQL / EF / ... then I suggest you try to find a technology stack/scenario that you like and what works for you.
In the past I was part of a team that worked with classic ASP, XML and XSLT to make up a fast website with a lot of users and that worked out great for us and the customer. The XML itself was generated from a SQL Server database and we had a forms application made in Access that directly interacted with the SQL Server so that the customer could simply update/add/remove information.
Kris.
Monday, January 15, 2018 9:01 AM