Trongate Docs
switch to dark modeswitch to dark mode
»
»
How Trongate Works With Databases

How Trongate Works With Databases

Trongate comes with a fully featured class for assisting with database interaction.  The class is called 'Model' and is stored on a file, inside the engine folder, named Model.php.

The Model class contains the following methods:

  • Get
  • Get Where
  • Get Where Custom
  • Get One Where
  • Get Many Where
  • Count
  • Count Where
  • Count Rows
  • Get Max
  • Insert
  • Update
  • Delete
  • Query
  • Query Bind
  • Insert Batch

Top Tip
When you're working with the Model, get comfortable with the idea of opening up Model.php and having a quick look at the methods to find out how they work and what arguments they might accept.

Coming Up

We're going to explore each of the methods above, but first - let's consider how to get set up and also how to view the SQL queries that are generated when we use the Model.


HELP & SUPPORT

If you have a question or a comment relating to anything you've see here, please goto the Help Bar.

 
×