Access table outside the form

I have a form
This form is not connected to table
I need to access a table in the Database
How do in SQL?
EXAMPLE
There is a table “A” where I need to put a new value
To find the value
I will table B
and see what value is this field
See table B
that has a value and then update it based
save table B
and bring this new value to the table “A”
save table A

Help me

Checkout databaseManager.getFoundSet(“server”, “table”) to get and manipulate foundsets without form binding. Some random sample code:

var page = databaseManager.getFoundSet("sutra_cms","web_page")
page.find()
page.id_page = site.id_page__home
var count = page.search()
if (count != 1) {
	obj.error.code = 404
	obj.error.message = "No default page specified for this site"
	return
}
else {
	pageID = page.id_page
	databaseManager.refreshRecordFromDatabase(page, 0)
}