How to write the content of a text file in CLOB using c and Pro*c?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Gyan Prakash
    New Member
    • Jan 2011
    • 1

    How to write the content of a text file in CLOB using c and Pro*c?

    I need to write a Pro*c application which selects the records from database and then writes them into a file.
    Then it opens the file in read mode and writes the content in CLOB. I got stuck at the last part as I am new to Pro*c and don't know how can I write into CLOB.

    Please provide me with your valuable suggestions.
    Thanks in Advance !
  • weaknessforcats
    Recognized Expert Expert
    • Mar 2007
    • 9214

    #2
    Pro*C is just C with special macros provided to make accessing Oracle easy.

    Read your Pro*C documentation.

    Essentially, you will open the Oracle database and process a SELECT to get your records. You will use Pro*C macros for this.

    Next, when you build, the Pro*C is processed by a Pro*C compiler that will convert the Pro*C macros into actual C code. This converted code is what you pass to your C preprocessr that wil pprocess for the C compiler.

    Try a simple program first:
    1)open your Oracle database
    2)select from a known table
    3)display your result

    Comment

    Working...