Can Views be used with a table? If so, how is the Views content added?

Comments

cog.rusty’s picture

Views are lists of posts (nodes). They don't list data which are not nodes. They can list the nodes as title lists, as teaser lists, as whole posts, and also as tables containing specified fields from the nodes.

nevets’s picture

Views 2 can do more than just list nodes and related tables. It can also for example list users. Views 2 has the concept of base tables and comes with several base tables defined. Other modules define additional tables and one can right a module extending existing definitions and adding new base tables.

wrwright’s picture

What I would like to do is make a web page with a table in that holds the info provided by Views so I can place it where I want at different locations in the table. Is that possible? Will a table created in Views work that way?

mcfilms’s picture

First: a disclaimer: I'm relatively new at Drupal.

My understanding is that Views alone won't allow you to have that one-to-one data association you are looking for. A module like panels allows you to carve up a region on a page a little more. But my understanding is, that you will ultimately have to write (or edit) a Theme to display the info provided by Views2 where you want it.

A list of some of the Drupal sites I have designed and/or developed can be viewed at motioncity.com

cog.rusty’s picture

There are several modules for attaching a view to a node instead of using the view's own page, if that is close to what you mean.

http://drupal.org/project/insert_view
http://drupal.org/project/viewfield
http://drupal.org/project/viewreference
http://drupal.org/project/views_attach

I can't elaborate much on their differences.

If you mean the opposite, a view that list nodes, and each listed node contains a field which is a table, there used to be a http://drupal.org/project/cck_table project but never ended up in a release.

jimthunderbird’s picture

You might find http://drupal.org/node/99721 is helpful. Basically views_get_view and views_build_view gives you flexibility to output view content on demand.

Attitude is mind's paintbrush, it can color anything.