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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. Darkwing99

    Insert with ascending CURRENT TIMESTAMP

    It works! Thanx a lot.
  2. Darkwing99

    Insert with ascending CURRENT TIMESTAMP

    Hi experts, I have to fill rows into a database with an insert-statement. The problem is the primary (unique) key. The column is named TS_INSERT and it should be the TS, when the row was inserted. But when I write: INSERT INTO table1 SELECT CURRENT TIMESTAMP , var2 , var3 ...
  3. Darkwing99

    How do I get the first free row?

    Instead of filling or creating new tables I can make a second SELECT. First I simply lokk for LOW-RANGE. If LOW-RANGE is in the table I use the SELECT I postet first otherwise LOW-RANGE is my hit. Thanks for all. If anyone knows a simple 1-select-way post it. For now I will use the...
  4. Darkwing99

    How do I get the first free row?

    The Tables have about 200 rows and the range is by default 50 to 100 but can be changed. The One-Row-Table in DB2 is SYSIBM.SYSDUMMY1 Regards, Thomas
  5. Darkwing99

    How do I get the first free row?

    Thanx for the fast answer but it will not run. select COL1+1 from (select Col1 from tbl where Col1 between LOW-RANGE and HIGH-RANGE union select LOW-RANGE -1 union select HIGH-RANGE -1 ) as t1 where not exists (select * from tbl as t2 where...
  6. Darkwing99

    How do I get the first free row?

    I have a table where COL1 is an increasing number starting with 1. Rows can be deleted. Now I need a SELECT-statement to get the first unused number within a given range. Example: COL1 1 2 3 4 6 8 12 13 14 I neet the first free number between 10 and 20. The result has to be 10. How can I...
  7. Darkwing99

    How to reset the harddisk "error bit"?

    I found the solution: You can reset the "error bit" simply with CHKDSK f: /F Thanx for all help. Regards, Thomas
  8. Darkwing99

    How to reset the harddisk "error bit"?

    One of my hard drives is about 3 years old and it seems it doesn't work very properly when applications manipulate many data. But (except once) I NEVER had found damaged sectors or even data loss durig the SCANDISK surface scan. I regulary use Norton Disk Doctor once per month to scan this...
  9. Darkwing99

    How to reset the harddisk "error bit"?

    This REG-script can turn off the startup-auchtocheck but it doesn't reset the "hard disk error bit".
  10. Darkwing99

    How to reset the harddisk "error bit"?

    Hi, first the things I already know: Windows checks at startup the "hard disk error bit" and the "clean shutdown bit". If any of them is set to ZERO, Windows performs a SCANDISK. You can find Infos about the bits here:http://annamaria.net/tools/scandisk.htm (the article is...
  11. Darkwing99

    How to switch between text and binary mode?

    As long as I compile my source with an host-c-compiler (C/370) I assume that '\n' is translated by 0x15. But simple write the two bytes in binary doesn't result in a CRLF. I tried it in more than one way: putc('\r',out); putc('\n',out); or fprintf(out,"\r\n"); or char r = 0x0D...
  12. Darkwing99

    How to switch between text and binary mode?

    There must be a difference between writing 0x0D and 0x15 (CR and LF in EBCDIC) in binary and '\n' in text-mode but I didn't find it. The '\n' in text works, the other not. Maybe it's z/OS that needs some more to interpret the two bytes as CRLF. If I reopen the output with out =...
  13. Darkwing99

    How to switch between text and binary mode?

    First something I find out: A "real LF" is a combination of CarrierReturn (CR) and LF. If you write '\n' to a text-file it is automatic converted to a real LF. If you write it to a binary-file no conversion will happen and so no real LF is in your output. > Have you tried fixing this...
  14. Darkwing99

    How to switch between text and binary mode?

    To explain why I have to insert LineFeeds (LF) in a binary dataset: The dataset was transfered "binary" from an UNIX-system to the z/OS-Host. The original format was VB, this means every line has a different lenght defined by an 4-byte-length-field at the beginning of each row. But...
  15. Darkwing99

    How to switch between text and binary mode?

    Hello, I have a "binary" dataset on an z/OS-system where I have to put some LineFeeds at special positions. If I open the output-dataset in "binary"-mode (e.g. "wb") the '\n' will not be a real LineFeed and if I open it in "text"-mode all HEX'15' of my...
  16. Darkwing99

    How to trap return code of a job in rexx program

    If you use SDSF I have a REXX that my be helpful: Run this script in a loop until return ^= "XXMAXRC> JobId empty" /* REXX */ /* Receive MAXRC out of SDSF...
  17. Darkwing99

    COBOL pgm calling a DB2 pgm?

    You HAVE to use the IKJEFT01-JCL even if your main program doesn't use DB2-commands. An you have to bind a plan for this program. Ohterwise you cannot connect to the DB2-system an receive a SQL-Code -927. Regards, Thomas
  18. Darkwing99

    COBOL pgm calling a DB2 pgm?

    Here is a JCL-sample for a program that uses DB2 itself or in a sub-program: //GO EXEC PGM=IKJEFT01,DYNAMNBR=20,REGION=4M //STEPLIB DD DISP=SHR,DSN=TEST.LM // DD DISP=SHR,DSN=PROD.LM // DD DISP=SHR,DSN=DBNT.DSNEXIT // DD DISP=SHR,DSN=DBNT.DSNLOAD //SYSOUT DD...
  19. Darkwing99

    Getting Rexx to talk to DB2....

    Hmmm... First of all two questions: 1) Do you use a PREFIX and if YES did you write the filename in quotes '...'? 2) Where do you use the ISPSTART-Command? Do you invoke ISPF-Funktions or -Panels? It should be working when you start a REXX with 'TSO rexxname'. Try 'TSO ISRDDN' and look at...
  20. Darkwing99

    Getting Rexx to talk to DB2....

    Then you have to allocate the DSNLOAD to your ISPLLIB: ADDRESS TSO "CD FI(ISPLLIB) DA('DBNT.DSNLOAD')" Regards, Thomas

Part and Inventory Search

Back
Top