Page 1 of 1
Database people help me out
Posted: Sun Oct 02, 2005 9:10 pm
by bitWISE
I'm using Oracle9i and I need to SELECT an isbn number from a column but have it return as 9-999-99999-9. I can't seem to find anything that helps.
Posted: Sun Oct 02, 2005 9:39 pm
by seremtan
helpdesk?
Posted: Sun Oct 02, 2005 9:47 pm
by bitWISE
I ended up figuring it out:
SELECT SUBSTR(isbn, 1,1) || '-' || SUBSTR(isbn, 2,3) || '-' || SUBSTR(isbn, 5,4) || '-' || SUBSTR(isbn, 9,1) "ISBN", title FROM books WHERE category = 'COMPUTER';
Posted: Sun Oct 02, 2005 10:24 pm
by ^misantropia^
Why not move it to the client? If the load is heavy, this kind of post-processing might just be the thing that causes the server to crash and burn.