I have created a small data collection for my wixsite with three fields FirstName (field id is firstName) LastName (field id is lastName) Email (field id is email) I have a button on my webpage (#button1). All i want is to access the record with particular email and display the values of individual fields. I have tried using wix-data.query object. Can anyone plz help?
import wixData from 'wix-data';
// ...
wixData.query("quiz2")
.eq("mail","ishuuw@gmail.com")
.find()
.then( (results) => {
//using a text box to check if results have got any record
$w("#text71").text=results.totalCount
} )
.catch( (err) => {
let errorMsg = err;
} );