If there are so many modules in Drupal, are the hard-coded functions reserved only for contributed modules? I read somewhere (cannot recall source) that a programmer was capable of doing extremely complex and tailor-suited web pages using Drupal without writing a single line of code (using hooks), just using the GUI of suitable contributed modules. Is this at all possible?

Are the Drupal 7 (and 8) functions thought as a way of extending capability via contributed modules, or is it good practice to tailor-suit your own functionality via hard-code modifications of SQL queries via hook_views_pre_view, hook_views_query_alter, hook_views_pre_render, theme_preprocess_page and all of these available functions?

I suspect that most of the time being ready to face a difficult project would need to be spent on trying dozens of different contributed modules, mutual compatibility, flexibility, etc., in order to reduce the custom code you would need.

I am not sure about this commentator being truly honest, but I find difficult not to create my own custom modules and modify queries, template.php, etc., in order to get the desired results, sometimes even by fixing long existing bugs in some contributed modules.
Only using Site Building features (no custom module development yet) should get you pretty far (if not far enough ...).
The Relativity Data Model for Drupal
Have a look at the (illuminating) article &quot;Relativity Model for Drupal&quot;, for which this is an introduction to it (quoted from this linked page):

The Relativity Data Model for Drupal is a zero-custom-code, collection of steps, procedures and methods that strive to help site builders, users and site visitors interact with Drupal in a far easier and more efficient way. This is done by:

Data architecture and data modeling merging as a single step through a documentation procedure.
Customized user interfaces that cater to individual workflows throughout permission roles.
Multi-level relational data structures that relate to other multi-level relational structures.
Mimicking the concept of database joins within Drupal's UI's.
Vastly reducing the size of Drupal sites by a small handful of modules that provide greater power, speed and expansion capabilities.


The small handful of modules (cfr. the last bullet) is like so (apart from Drupal core):

Chaos tool suite (ctools)
Date
Entity API
Entity reference
Entity connect
Field Group
Token
Pathauto
Views

Note: this same topic is also presented in the video &quot;Revolutionary DRUPAL Data Modeling Concept!! (This will change your Drupal life!)&quot;.
Typical add-on modules
Even though that small handful of modules above can get you already extremely far, I often add a subset of other contributed modules to it also, as further detailed below.
Business logic
Using the Rules and Flag module, it is possible to implement all sorts of business logic (= rules), simply using the typical Drupal admin UI for those modules.
Queries, custom reports and charts

To perform queries (listings, etc), use the Views module, possibly further extended with modules such as Views Slideshow: Galleria (there are dozens of modules to further enhance views).

The Forena module can be used as a supplement / alternative (e.g. if you'd need to also create charts or so, or if you have a need to access data in some external database such as MS SQL, Oracle, etc).
Using the Forena integration with the Feeds module it is possible to import data blocks and reports as Drupal nodes or Drupal users. For a tutorial about the available features check out the video about How to import data and reports based on data as Drupal nodes.

Create charts using the views integration of the Charts module to visualize a lot of data in a way that can be quickly digested.


Page Layout
Modules like Display Suite and/or Panels can help to enhance the look and feel of it all also.
Many more modules

Group (a pretty new alternative to Organic groups, to create arbitrary collections of your content and users and grant access control permissions on them).
Workflow (to create arbitrary workflows, and assign them to entities).
IP Geolocation Views &amp; Maps, a mapping engine to create Views-based mapping solutions using the map renderer of your choice (Google, OpenLayers or Leaflet)
Or, or  ... on and on goes the list.

Disclosure: I'm a (co-)maintainer of Forena and Charts.