Live entries to a database possible?

My website relies on a user imputing data, and immediately seeing that data on the page without refreshing the site. I’ve used a database to store and show any data that’s been submitted by a user. I can call the dataset and show it when the site is first loaded, but when you enter a new piece of data, it doesn’t show until you refresh the page. When I open the logs, it shows that it’s “refreshing” the data (through setInterval), but it doesn’t find anything new. If there were 15 pieces of data when you go to the site, it’ll always see those same 15 pieces no matter how much I enter into the database. When I refresh the page, it shows the new data. Is it possible to see live entries to a database?

$w.onReady( function () {

myFunction();
setInterval(myFunction,1000);

});

function myFunction() {

$w.onReady( () => {
$w(“#dataset2”).onReady( () => {
$w(“#dataset2”).getItems(0, 1000)
.then( (result) => {
let items = result.items;
let allTexts = “”;
for(let i = 0; i < items.length; i++){
allTexts += items[i].letter;//use your own field key instead of “title”
}
$w(“#text31”).text = allTexts;

  } ) 
  . **catch** ( (err) => { 

let errMsg = err.message;
let errCode = err.code;
} );
} );
} );

}