Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Recent content by jimirvine

  1. jimirvine

    SQL Help

    It is bad manners to get a solution from a different forum and then post it here as yours. You should also probably acknowledge the people who helped you on the other forum.
  2. jimirvine

    Jioning two tables

    You would need to post the logic as to why the data should join like that. i.e. why would 189 be associated with 100 and not 200?
  3. jimirvine

    Need Advice - Can we use Oracle in this situation?

    Does Dagon's response more fully answer your question?
  4. jimirvine

    Need Advice - Can we use Oracle in this situation?

    Short answer? You are going to need IT to maintain this.
  5. jimirvine

    Date in varchar2 format

    I would very, very strongly advise you to endeavour to get the datatype of that column changed to a date. There is never a good reason to have a date stored as text in a database such as Oracle.
  6. jimirvine

    tuning sql for counting no of rows with x no of consecutive numbers

    Maybe I'm missing something, but surely a simple analytic will do the job: WITH T AS ( SELECT 'user a' usr, TO_DATE('9:00','HH:MI') tm, 'logged in' stat FROM DUAL UNION ALL SELECT 'user a', TO_DATE('9:01','HH:MI'), 'logged in' FROM DUAL UNION ALL SELECT 'user a', TO_DATE('9:02','HH:MI')...
  7. jimirvine

    Programmatically load CSV file into oracle table using VB.Net

    You are entitled to your opinion of course.
  8. jimirvine

    Programmatically load CSV file into oracle table using VB.Net

    VB is a completely innappropriate tool for doing this. Use External Tables.
  9. jimirvine

    Not a single-group group function

    1. I would doubt this (in either case of the code) as I'm pretty sure that BO won't accept aliasing in its dynamically created sql. 2. SYSDATE is a date, why would you use a to_date on it? Makes no sense whatsoever. although, as Santa points out, your main issue seems to be with your brackets.
  10. jimirvine

    NVL(7.50, 0) or TO_CHAR(7.50, 0) give 7.5 instead of 7.50

    Only If those values are now text i.e. there was most likely a to_char performed on the value within the definition of the view. If they are not text, then they do not have trailing zeros. Jim
  11. jimirvine

    NVL(7.50, 0) or TO_CHAR(7.50, 0) give 7.5 instead of 7.50

    Serves me right for not reading fully the question. Answer number 1 is that the 'numbers' must be stored/passed as strings. storing/passing them as numbers will normalise the number and instantly become useless for anything with trailing zeros. after that, a little bit of arithmetic (an...
  12. jimirvine

    NVL(7.50, 0) or TO_CHAR(7.50, 0) give 7.5 instead of 7.50

    Maybe a quick demo: SQL> select to_char(7.5,'0') 2 from dual; TO -- 8 SQL> ed Wrote file afiedt.buf 1 select to_char(7.5,0) 2* from dual SQL> / TO -- 8 SQL> ed Wrote file afiedt.buf 1 select to_char(7.5,'00') 2* from dual SQL> / TO_ --- 08 SQL> ed Wrote file afiedt.buf...
  13. jimirvine

    Case..When..Statement

    Why not just SELECT DISTINCT b.amount_code_description, to_char(sum(CASE WHEN b.year = '2005' THEN to_char(b.ytd_amount, '9999999999.99') ELSE...
  14. jimirvine

    What is Redo1.log file from Oracle 9.2/Oradata/dbname

    NEVER modify the contents of your redo log files.
  15. jimirvine

    Execute Immediate: ORA-01008: not all variables bound

    Maybe this'll help: DROP TABLE foo; CREATE TABLE foo (eg NUMBER, x NUMBER, y NUMBER, z NUMBER); --Example 1 DECLARE l_x NUMBER := 1; l_y NUMBER := 2; l_z NUMBER := 3; l_str VARCHAR2(32767); err_line EXCEPTION; PRAGMA exception_init(err_line, -01008); BEGIN BEGIN EXECUTE...

Part and Inventory Search

Back
Top