You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@beam.apache.org by Vardhan Thigle via user <us...@beam.apache.org> on 2024/02/22 16:19:42 UTC

Query about `JdbcIO`

Hi,
I had a small query about `JdbcIO`.
As per the documentation
<https://beam.apache.org/releases/javadoc/current/org/apache/beam/sdk/io/jdbc/JdbcIO.html>
 `readWithPartitions` is supported for  Long, DateTime
<https://static.javadoc.io/joda-time/joda-time/2.10.10/org/joda/time/DateTime.html?is-external=true>
, String types for the partition column but on top of the tree code,
`PRESET_HELPERS`
(ref
<https://github.com/apache/beam/blob/384c1034cd55fd0aa2a297581e113b9a4f6a4847/sdks/java/io/jdbc/src/main/java/org/apache/beam/sdk/io/jdbc/JdbcUtil.java#L492>)
support only Long and DateTime.

Was the support for `String` rolled back? If yes could you please help me
with the exact problem that caused the rollback (or any pointers to a
previous Issue)?

Regards and Thanks,
Vardhan Thigle,
+919535346204 <+91%2095353%2046204>

Regards and Thanks,
Vardhan Thigle,
+919535346204

Re: Query about `JdbcIO`

Posted by Vardhan Thigle via user <us...@beam.apache.org>.
Thanks for the pointer, xqhu@ !
Regards and Thanks,
Vardhan Thigle,
+919535346204


On Sun, Feb 25, 2024 at 2:19 AM XQ Hu <xq...@google.com> wrote:

> I did not find BEAM-13846 but this suggests String is never supported:
>
>
> https://github.com/apache/beam/blob/master/sdks/java/io/jdbc/src/test/java/org/apache/beam/sdk/io/jdbc/JdbcUtilTest.java#L59
>
> However, you could use the code from the test to create yours.
>
> On Thu, Feb 22, 2024 at 11:20 AM Vardhan Thigle via user <
> user@beam.apache.org> wrote:
>
>> Hi,
>> I had a small query about `JdbcIO`.
>> As per the documentation
>> <https://beam.apache.org/releases/javadoc/current/org/apache/beam/sdk/io/jdbc/JdbcIO.html>
>>  `readWithPartitions` is supported for  Long, DateTime
>> <https://static.javadoc.io/joda-time/joda-time/2.10.10/org/joda/time/DateTime.html?is-external=true>
>> , String types for the partition column but on top of the tree code, `PRESET_HELPERS`
>> (ref
>> <https://github.com/apache/beam/blob/384c1034cd55fd0aa2a297581e113b9a4f6a4847/sdks/java/io/jdbc/src/main/java/org/apache/beam/sdk/io/jdbc/JdbcUtil.java#L492>)
>> support only Long and DateTime.
>>
>> Was the support for `String` rolled back? If yes could you please help me
>> with the exact problem that caused the rollback (or any pointers to a
>> previous Issue)?
>>
>> Regards and Thanks,
>> Vardhan Thigle,
>> +919535346204 <+91%2095353%2046204>
>>
>> Regards and Thanks,
>> Vardhan Thigle,
>> +919535346204 <+91%2095353%2046204>
>>
>

Re: Query about `JdbcIO`

Posted by XQ Hu via user <us...@beam.apache.org>.
I did not find BEAM-13846 but this suggests String is never supported:

https://github.com/apache/beam/blob/master/sdks/java/io/jdbc/src/test/java/org/apache/beam/sdk/io/jdbc/JdbcUtilTest.java#L59

However, you could use the code from the test to create yours.

On Thu, Feb 22, 2024 at 11:20 AM Vardhan Thigle via user <
user@beam.apache.org> wrote:

> Hi,
> I had a small query about `JdbcIO`.
> As per the documentation
> <https://beam.apache.org/releases/javadoc/current/org/apache/beam/sdk/io/jdbc/JdbcIO.html>
>  `readWithPartitions` is supported for  Long, DateTime
> <https://static.javadoc.io/joda-time/joda-time/2.10.10/org/joda/time/DateTime.html?is-external=true>
> , String types for the partition column but on top of the tree code, `PRESET_HELPERS`
> (ref
> <https://github.com/apache/beam/blob/384c1034cd55fd0aa2a297581e113b9a4f6a4847/sdks/java/io/jdbc/src/main/java/org/apache/beam/sdk/io/jdbc/JdbcUtil.java#L492>)
> support only Long and DateTime.
>
> Was the support for `String` rolled back? If yes could you please help me
> with the exact problem that caused the rollback (or any pointers to a
> previous Issue)?
>
> Regards and Thanks,
> Vardhan Thigle,
> +919535346204 <+91%2095353%2046204>
>
> Regards and Thanks,
> Vardhan Thigle,
> +919535346204 <+91%2095353%2046204>
>