7 Replies Latest reply: Feb 20, 2013 5:42 AM by Marwim RSS

    Unable to load .CSV file data through PL/SQL program

    981984
      I am using the logic to load .CSV file data into the table. If there is no comma in the field/column data then this program working. If there is any comma in the field data like "ABC, Tester" then this is not working. I had tried with placing the column double quotes "" but there is no success.

      Edited by: user8564931 on 20 Feb, 2013 3:48 AM
        • 1. Re: Unable to load .CSV file data through PL/SQL program
          Marwim
          Post duplicated by Jive

          Edited by: Marwim on 20.02.2013 12:40
          • 2. Re: Unable to load .CSV file data through PL/SQL program
            981984
            I am using this logic through oracle D2k form
            • 3. Re: Unable to load .CSV file data through PL/SQL program
              Marwim
              Hello,

              you should put your code int
               tags to preserve formatting. It would make your code more readable.
              
              Why do you want to reinvent the wheel instead of using External Tables or SQL*Loader?
              
              Regards
              Marcus                                                                                                                                                                                                                                                                                                                                                                                                                                                            
              • 4. Re: Unable to load .CSV file data through PL/SQL program
                981984
                I am using this logic through oracle D2k form
                • 5. Re: Unable to load .CSV file data through PL/SQL program
                  BluShadow
                  Marwim wrote:
                  Hello,

                  you should put your code int {noformat}
                  {noformat} tags to prederve formatting. It would make your code more readable.
                  I was going to edit his post and put {noformat}
                  {noformat} tags for him... but unfortunately, what he pasted in isn't even formatted, so it would make no difference, except change the font.
                  
                  
                  Why do you want to reinvent the wheel instead of using External Tables or SQL*Loader?
                  My thoughts exactly.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   
                  • 6. Re: Unable to load .CSV file data through PL/SQL program
                    BluShadow
                    user8564931 wrote:
                    I am using this logic through oracle D2k form
                    you would be better pushing the CSV file to the database server and then call a procedure on the database to use External Tables to read the data directly into it.
                    • 7. Re: Unable to load .CSV file data through PL/SQL program
                      Marwim
                      You can select from an External Table just as you select from a "real" table. This works in Forms too.

                      See {message:id=1145730}

                      Edited by: Marwim on 20.02.2013 12:42