ibmi-brunch-learn

Announcement

Collapse
No announcement yet.

Image Handling on AS400

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • #16
    Re: Image Handling on AS400

    It is possible to save images to a database. The proper way is to define a field as a Binary Large OBject or BLOB then you can save any binary file you like to the database. However, I don't know what an RPG program would make of it and I don't know if it's possible if you're using DDS to create your tables.

    To satisfy my curiosity I did a search and found this:
    We’ve all heard by now that defining tables using DDS is becoming outdated and that developers need to use SQL in order to access the relatively new data types, including DATALINK and Large Objects (BLOB, CLOB, and DBCLOB). I recently ran into a situation where I wanted to change a field in an existing table

    Looks like it is possible using DDS after all although I wasn't aware that you had to hard-code a size for a BLOB. It looks like it's slightly different using DDS.
    Ben

    Comment


    • #17
      Re: Image Handling on AS400

      Just for more information on some findings that we came across in our testing for ChangefIT v2.23 a few weeks ago.

      Embedded blanks:
      This will not work... wrap the statement in double quotes, like so:
      Code:
      '"\\199.199.199.199\changefit\ECO\0901005\DDS PF & LF Files.pdf"'
      Special characters:
      The above statement will also not work because of the "&"
      You will have to rename the doc ( by whichever means) so this will work:
      Code:
      '"\\199.199.199.199\changefit\ECO\0901005\DDS PF and LF Files.pdf"'
      Regards

      Kit
      http://www.ecofitonline.com
      DeskfIT - ChangefIT - XrefIT
      ___________________________________
      There are only 3 kinds of people -
      Those that can count and those that can't.

      Comment


      • #18
        Re: Image Handling on AS400

        Originally posted by kitvb1 View Post
        btw... The folder must also be a shared folder and I don't believe it can be accessed using "d:...."
        This is not right. I've done some more testing and I can now access files on the local PC and they do not have to be shared.
        Code:
        strpcCMD    ('"/b g.txt"')               
        strpcCMD    ('"E:/My Documents/bg.txt"')
        What I had done before was
        Code:
        strpcCMD    ('\\192.168.178.32\My Documents\bg.txt')       
        strpcCMD    ('\\199.199.199.199\e:\My Documents\bg.txt')    
        strpcCMD    ('\\199.199.199.199\ftpcmd.txt')                
        strpcCMD    ('E:\My Documents\bg.txt')                     
        strpcCMD    ('\\E:\My Documents\bg.txt')                   
        strpcCMD    ('\\199.199.199.199\e:\My Documents\bg.txt')    
        strpcCMD    ('\\199.199.199.199\My Documents\bg.txt')       
        strpcCMD    ('"\\ku2\My Documents\bg.txt"')
        I had backslash instead of fwdslash.
        Apologies for the misinformation.
        On a positive note - also a good learning curve for me... first time I've tried STRPCCMD on a local PC file. Also notice the last entry... that one works as well.
        Last edited by kitvb1; February 26, 2009, 03:39 PM. Reason: added last sentence
        Regards

        Kit
        http://www.ecofitonline.com
        DeskfIT - ChangefIT - XrefIT
        ___________________________________
        There are only 3 kinds of people -
        Those that can count and those that can't.

        Comment


        • #19
          Re: Image Handling on AS400

          I did some more research on the embedded "&" challenge over the weekend and came up with this as being +/- the best solution for me. Maybe it'll help someone else.

          Code:
          STRPCCMD PCCMD('rundll32 url.dll,FileProtocolHandler C:\Dokumente und Einstellungen\davb\Desktop\Doku & ment.rtf')
          Note that the double-quotes are no longer needed.
          You could read more here:
          Regards

          Kit
          http://www.ecofitonline.com
          DeskfIT - ChangefIT - XrefIT
          ___________________________________
          There are only 3 kinds of people -
          Those that can count and those that can't.

          Comment


          • #20
            Re: Image Handling on AS400

            You can check also:

            Comment

            Working...
            X