Hey gang, I have an issue that I need a very simple answer too. I am build a set of custom tags to allow the end coder to get all of the information about a datasource that you would ever want to know and some things you wouldn't.
My issue is that some databases support certain attributes and others do not. If you are using my tag and you ask for a some feature of a database that is not supported by that DBMS it will throw a SQLException. What I would like your opinion on is what would you expect the tag to do. The solution I have come up with so far is to let you pass in a throwOnException attribute and if the feature you are asking for is not supported you can choose how the tag will respond with or with out an error. If you choose to throwOnException="false" the value you are asking for will be given back to you as it existed when the tag was initialized. My specific problem with all of this is that for any given information I am passing back to the user, it may or may not be a string. The solution I have come up with is detailed in the code snippet below. If anyone is interested in looking into the tagset I am proposing you can go to http://java.sun.com/j2se/1.4/docs/api/java/sql/DatabaseMetaData.html and look at all the information that is available through your database driver. try{ source_data_type = columns.getShort(22); }catch(SQLException e){ if(throwOnException){ throw new JspException(e.toString()); } } =========================================================================== To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST". For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST". Some relevant archives, FAQs and Forums on JSPs can be found at: http://java.sun.com/products/jsp http://archives.java.sun.com/jsp-interest.html http://forums.java.sun.com http://www.jspinsider.com