SQLAlchemy and Twisted [closed] - sqlalchemy

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 9 months ago.
Improve this question
I'v learned twisted for somewhile and would like to do some network communication and local db operation as well.BTW, MySQL DB adopted, non-blocking required and perferred.
Someone told me that sqlalchemy is just great. But as far as I have known from the Internet, the two may not work together perfectly(http://twistedmatrix.com/pipermail/twisted-python/2009-March/019359.html ).
So I would like to know if anyone has this kind of experience(either successful or a failure is welcomed) to make both of them work together?
And Could anyone tell why there is no way for them to work together?
Thank you in advance!

SQLAlchemy presents a blocking interface to database access. You can use it with Twisted if you use it in a separate thread. It's frequent to use many threads with SQLAlchemy anyway, so there's nothing really special going when you try to use it with Twisted. It only seems strange because Twisted itself mostly offers APIs which you don't need threads for.

Been searching for a while and found alchimia that lets you use most of the SQLAlchemy-core API with Twisted, it does not allow you to use the ORM.

Related

Why do some people prefer SQLite over MySQL? I am a MSSQL user [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 5 years ago.
Improve this question
I am curios why some prefer MYSQL over SQLITE, i am interested on learning MYSQL
SQLite is an embedded library, it requires no server process, and everything it saves is contained within a single, portable file. MySQL is an RDBMS server that's a lot more work to set up, but is multi-user, more scalable, and far more featured.
For example, SQLite is used for mobile applications as well as "development" instances of code where it's only lightly loaded. It can be used at scale but generally isn't, its simple design has limitations.
If you're writing a mobile application and need a local database, SQLite is not a bad call. Spinning up a huge, cumbersome MySQL process to do the same thing on a mobile device is a bad plan.
Although they're both "SQL databases" and have a lot of functional overlap, they're engineered to solve some very different problems. In some trivial use cases it might be an arbitrary choice as to which is best, but in most cases it's pretty obvious which of the two you need.

Is PostgreSQL or MySQL more popular with Node.js? [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 7 years ago.
Improve this question
In absolute terms, Postgres has more features and has been used at scale by Instagram, etc. while MySQL has a much bigger user base and has been used at scale by likes of Facebook, Quora, etc. But how about in combination with NodeJS?
Which is more popular with NodeJS?
MySQL is probably more popular, solely in terms of userbase. (You sorta answered this yourself)
MySQL probably has more examples around the net which could help make things easier to set up. You'll probably also find MySQL more likely to come preloaded on a VPS if that's the sort of route you're taking. However setting up PostgreSQL on your server is not difficult, and there is plenty of documentation available.
It really depends on what your intentions are with your data. Digital Ocean wrote a nice concise comparison of MySQL and PostgreSQL found here
As far as how these play with node.js, in my experience the node modules for PostgreSQL and MySQL are equally pleasant to work with. Ultimately its more about picking the database that suits your data and what you want to do with your data. Then deciding how it fits into your node stack.

Voting system on NoSQL [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 9 years ago.
Improve this question
Is it possible/reasonable to have a voting system on NoSQL database ?
For example how would be possible to store StackOverflow question into the NoSQL database.
I can easily imagine almost everything except how the relation will work between question/vote/user. Everything else can be stored in one document, like tags, comments(assuming there are relatively small amount of comments on posts, in my case I will not have comments anyway), user information, etc... but can't imagine how to store user votes as document will become huge. One of the options is that I can have votes stored in separate collection/document, but it will mean that while loading a question there will be a need to send another request to check if the user have voted for a question or not.
A good reference is the MongoDB documentation on Embedded documents vs Referenced documents, since those are what you seem to be referring into your question. There's no perfect solution, as both have their trade offs. You just have to make the best decision based on the type of operations/queries and their frequencies that you're expecting to be run on your database.
Honestly, until your database starts getting some serious traffic, the difference between SQL and NoSQL won't matter. Pre optimization can end up doing more harm than good, so I would just go with the one that is easiest to get deployed and you're more comfortable with to begin with.

Start with MySQL and change to MongoDB in the future? [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 9 years ago.
Improve this question
I'm new to node.js
I have plan to use database other than MySQL (lets say MongoDB), but I'm only familiar with MySQL.
Do you think better to use MySQL first and change to MongoDB in the future? or learn MongoDB quickly and use MongoDB from beginning?
If you know how to appropriately use MySQL, then use it.
If you want to learn about MongoDB (or any other thing), then find some time to play with it on toy systems, just as you did when learning MySQL (or any other thing).
If, after having reasonable experience with both things, you think MongoDB has a place in your system, then use it. Either replacing or complementing whatever you already have.
But don't do it just because it's the cool thing to do.
First of all, you have to wonder why you want to use a NoSQL database. Is it because it's easier to develop for your application ? More efficient ? Scales better ? because of the hype ?
Then, if you think MongoDB is a good choice, go ahead with it. Implementing a first solution in SQL, then switching, looks like a waste of time to me (you will have to change a lot of your design).

How to write documentation for microsoft access database? [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 5 years ago.
Improve this question
I've been developing a small database for my summer internship and I need to write a manual/documentation for it aimed at both users and developers for future use. Thing is...I have no idea where to start or what information to include. Many people I work with have no idea what databases can do so I need to keep it as simple as possible. The database is implemented in Access and I experimented with the database documenter but I think that is overkill. Is there some kind of documentation standard that I can follow or anything of that nature?
As a starter for ten, I'd have thought that the user documentation should be task orientated.
(i.e: How to achieve 'X'.)
In terms of the developer documentation, defining the meaning of any non-obvious fields in your schemas, how they're used and the relationships between different tables, etc. would be a good start. (I'm presuming your VBA code is well commented, etc.) You may also want to examine the existing "Documenting Visual Basic with Doxygen" question/answer.
Just straightforward english if you are explaining a process.
If you have a series of Macros do a document highlighting to code used in each macro and the order it should be employed. This could aid someone down the line if they are trying to automate the process.