aspose file tools*
The moose likes JDBC and the fly likes COUNT NUmber of folder Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "COUNT NUmber of folder" Watch "COUNT NUmber of folder" New topic
Author

COUNT NUmber of folder

deepak carter
Ranch Hand

Joined: Feb 19, 2011
Posts: 165
Hi ,

Dont know whether this is the right place to ask this.

How to count number of folder.

There is a application in which docuemnt are placed inside a folder.There is one column in a database "isFolder" whcih cantell whether its a folder or not but there is no such separate table for folder.
Then how can we count number of folders.
Rob Spoor
Sheriff

Joined: Oct 27, 2005
Posts: 19720
    
  20

SELECT * FROM <table> WHERE isFolder = 1 (true, or whatever your column type requires) will return you all folders, right? So SELECT COUNT(*) will return the number.


SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6
How To Ask Questions How To Answer Questions
deepak carter
Ranch Hand

Joined: Feb 19, 2011
Posts: 165
How to count the number of documents in a folder???
Tim McGuire
Ranch Hand

Joined: Apr 30, 2003
Posts: 820

there is a field that says which folder a document belongs in, right? This sounds like parents and children in the same table. Can you post the real structure of the table?
 
Don't get me started about those stupid light bulbs.
 
subject: COUNT NUmber of folder