:: Professional ::
 
You are here: Blog
 

Hilbert Solutions, LLC Latest Dotnetnuke Modules...

Advanced News Ticker        Constant Contact Sign Up

 

Blog
May5

Written by:slhilbert
5/5/2009 9:52 AM 

DotNetNuke provides those with “Host” level access a great screen to execute SQL commands against.

This screen is located under the “Host” menu and is named, “SQL”.  It is a simple box that you simply write your query or paste in your stored procedure script and then press, “Execute”. It is a great way to quickly looking up table information or run a delete command if your EventLog gets to full.

I find myself using this box often to look up information in a table.  The only problem is that I am never quite sure what the name of the table is that I am looking up.  That is when I use this simple SQL command to pull out all the names of tables so I can then do some “SELECT” statements on the table I need.

The command below lists all of the tables in your database.  This code is a copy of the code from here.

SELECT name [Table Name]
FROM sysobjects
WHERE xtype = 'U'
order by 'Table Name'

Tags:

Your name:
Your email:
(Optional) Email used only to show Gravatar.
Your website:
Title:
Comment:
Security Code
Enter the code shown above in the box below
Add Comment  Cancel 
Search Blog
Blog Archive
Terms Of Use| Privacy Statement Hilbert Solutions, LLC Since 2007