Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

jdbc: Support Connection.prepareStatement(sql, Statement.RETURN_GENERATED_KEYS) #77

Closed
Totktonada opened this issue Nov 1, 2018 · 1 comment · Fixed by #207
Closed

Comments

@Totktonada
Copy link
Member

This is about the following methods of the Connection interface:

  1. prepareStatement(sql, Statement.RETURN_GENERATED_KEYS)
  2. prepareStatement(sql, columnIndexes)
  3. prepareStatement(sql, columnNames)

The first one should be useful for an autoincremented primary key.

Don't sure we can support 2nd and 3rd (need to check metainfo content). If it is not so, then raise SQLFeatureNotSupportedException for these methods.

Blocked by tarantool/tarantool#2618

@Totktonada Totktonada added jdbc blocked Not ready to be implemented jdbc optional feature labels Nov 1, 2018
@Totktonada Totktonada removed the blocked Not ready to be implemented label Jan 23, 2019
@Totktonada
Copy link
Member Author

Not blocked amymore.

nicktorwald added a commit that referenced this issue Jul 16, 2019
Parse the 'generated_ids' array which is returned after successful
INSERT command has applied. This makes sense when a table primary key
has an autoincrement property. The driver always returns a predefined
result set with a single-column table (column name is 'GENERATED_KEYS')
where each row is one generated value.

Closes: #77
nicktorwald added a commit that referenced this issue Jul 16, 2019
Parse the 'generated_ids' array which is returned after successful
INSERT command has applied. This makes sense when a table primary key
has an autoincrement property. The driver always returns a predefined
result set with a single-column table (column name is 'GENERATED_KEYS')
where each row is one generated value.

Closes: #77
@nicktorwald nicktorwald self-assigned this Jul 16, 2019
nicktorwald added a commit that referenced this issue Jul 18, 2019
Parse the 'generated_ids' array which is returned after successful
INSERT command has applied. This makes sense when a table primary key
has an autoincrement property. The driver always returns a predefined
result set with a single-column table (column name is 'GENERATED_KEYS')
where each row is one generated value.

Closes: #77
nicktorwald added a commit that referenced this issue Aug 8, 2019
Parse the 'generated_ids' array which is returned after successful
INSERT command has applied. This makes sense when a table primary key
has an autoincrement property. The driver always returns a predefined
result set with a single-column table (column name is 'GENERATED_KEYS')
where each row is one generated value.

Closes: #77
nicktorwald added a commit that referenced this issue Aug 8, 2019
Parse the 'generated_ids' array which is returned after successful
INSERT command has applied. This makes sense when a table primary key
has an autoincrement property. The driver always returns a predefined
result set with a single-column table (column name is 'GENERATED_KEYS')
where each row is one generated value.

Closes: #77
nicktorwald added a commit that referenced this issue Aug 8, 2019
Parse the 'generated_ids' array which is returned after successful
INSERT command has applied. This makes sense when a table primary key
has an autoincrement property. The driver always returns a predefined
result set with a single-column table (column name is 'GENERATED_KEYS')
where each row is one generated value.

Closes: #77
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants