Uploaded image for project: 'Beam'
  1. Beam
  2. BEAM-12511

JdbcIO.Write.withResults work without statement

Attach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • P2
    • Resolution: Fixed
    • None
    • 2.32.0
    • io-java-jdbc
    • None

    Description

      JdbcIO.Write can work without statement and preparedStatementSetter in all case except using "Write.withResults". e.g.

            PCollection<Row> dataCollection = pipeline.apply(Create.of(data));
            PCollection<Void> rowsWritten =
                dataCollection.apply(
                    JdbcIO.<Row>write()
                        .withDataSourceConfiguration(DATA_SOURCE_CONFIGURATION)
                        .withBatchSize(10L)
                        .withTable(firstTableName)
                        .withResults());
            .dataCollection .
                .apply(Wait.on(rowsWritten))
                .apply(
                    JdbcIO.<Row>write()
                        .withDataSourceConfiguration(DATA_SOURCE_CONFIGURATION)
                        .withBatchSize(10L)
                        .withTable(secondTableName));
      
            .run();
      

      Need to add ability to use "Write.withResults" without statement and preparedStatementSetter.

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            raphael.sanamyan Sanamyan Raphael
            raphael.sanamyan Sanamyan Raphael
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0h
                0h
                Logged:
                Time Spent - 3h 20m
                3h 20m

                Slack

                  Issue deployment