I am working on an application which keeps records of check ins and checkouts of the customer. i want to embed the background worker class in my project.
here is the situation:
I want list of rooms to be upadted automatically on saving the information on the new room... for displaying room i am using gridview and for adding new room i created a new form and add LINQ to SQL query code to save the information of new room.
kindly help me with this.. or suggest me something else. how to implement it.. for you information and i am using LINQ to SQL class..
Technologies I am using:
Editor: Visual Studio2010
Language: C#
back end Database in MYSQL Server 2008
using LINQtoSQL for creating connection with the data base
As you can see in this question, the Linq-to-Sql does not provide access to MySQL database out-of-box, however, there are several workaround.
Related
I'm designing a real-estate website and I was wondering can I link my front-end webpage that shows the available properties for sale that a new property icon is added when I add to my MongoDB ? to elaborate more, I have a template for each single property which includes picture and some other info about the property, what i want to do is when i add a new collection to my database to appear on my webpage with this template. Thanks in advance
MongoDB can be watched, since your question has 'node.js' tag so assume you use node.js in the server side, I check the doc and there's a watch API returning a ChangeStream object which you may use, just for your reference
If you want to use angular for retrieving and showing data.
You can refer to these sites :
This one tells how to populate data in angular.
&
To get a crisp of doing it with mongo db
What you actually need is server side event system updating your frontend, Changestream that #user1108069 mentioned can be useful in detecting new changes or you can literally identify that when a request is being made to add a new property.
The task here is to update the frontend's current connections to update their view to get the new (load) changes, you can do this in multiple ways.
Use something like firebase realtime DB on the side Firebase Realtime DB
Use any other server side events broker for you This should work too
You can create your own full duplex system, using something like socket.io but do remember that concurrent connections needs to be handled properly. You cannot keep them connected to your server all the time.
Cheers!
I'm totally new to Handsontable and I want to use it in my Nodejs&React app to save data in a Postgresql database.
Basically, I've tried to render the table component and its custom headers but I can't see how it can be used in with Nodejs, despite all the Googling I did.
My current table on a page
I'd appreciate your help.
step1. Use a hands-on table to have the user fill in the data and when they press the save button, use "getSourceData" or "getData" to
Obtain table data.
step2. Submit the data acquired in step1 to the nodejs server and save the data to the Postgresql database.
I think this will make it possible.
When a document is added to the MongoDB Collection, I want to add a new HTML element (div,p,img,etc..) to my homepage.html . The homepage.html has to be dynamically updated by the server, by 'Detecting' the changes in the MongoDB database Collection. I'm using Express.js to respond to client requests.
Your task cannot be done by only using those technologies. You have to use some kind of socket programming framework like socket.io.
I recommend you to refer this real time chat app creating blog post to get some sort of idea of your case. here is the link
Thanks. Hope you will understand me.
I'm confused how to explain myself well here is my scenario.
I have a database named "database1" and i have used typed dataset in visual studio and have added more than 200 stored procedures in the table adapters.
it is a desktop based application. now i want to deployee the same software in other school same database but i have changed the database name
when i generate new database from query and write all the stored procedures in the database and change the database name in the connection string it doesn't work.
I'd recommend you don't change the database name, or if it's something specific to the first client (like ParisTechnicalCollegeDatabase), change it now to something generic (SchoolManager) so you never have to change it again. There's no specific problem I can think of regards reusing a typed dataSet on a different database: I do it daily on database that aren't clones of each other. Ensure your second server is set up with a user and default schema that is specified in the connection string. The problem will eithe per be faulty connection string or incorrect database setup, not the fault of the dataSet
For more targeted help, post up the error messages that appear when you try to run your app on the new database
We've got an application in Django running against a PGSQL database. One of the functions we've grown to support is real-time messaging to our UI when data is updated in the backend DB.
So... for example we show the contents of a customer table in our UI, as records are added/removed/updated from the backend customer DB table we echo those updates to our UI in real-time via some redis/socket.io/node.js magic.
Currently we've rolled our own solution for this entire thing using overloaded save() methods on the Django table models. That actually works pretty well for our current functions but as tables continue to grow into GB's of data, it is starting to slow down on some larger tables as our engine digs through the current 'subscribed' UI's and messages out appropriately which updates are needed as which clients.
Curious what other options might exist here. I believe MongoDB and other no-sql type engines support some constructs like this out of the box but I'm not finding an exact hit when Googling for better solutions.
Currently we've rolled our own solution for this entire thing using
overloaded save() methods on the Django table models.
Instead of working on the app level you might want to work on the lower, database level.
Add a PostgreSQL trigger after row insertion, and use pg_notify to notify external apps of the change.
Then in NodeJS:
var PGPubsub = require('pg-pubsub');
var pubsubInstance = new PGPubsub('postgres://username#localhost/tablename');
pubsubInstance.addChannel('channelName', function (channelPayload) {
// Handle the notification and its payload
// If the payload was JSON it has already been parsed for you
});
See that and that.
And you will be able to to the same in Python https://pypi.python.org/pypi/pgpubsub/0.0.2.
Finally, you might want to use data-partitioning in PostgreSQL. Long story short, PostgreSQL has already everything you need :)