• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

babelfish-for-postgresql / babelfish_extensions / 10197752006
74%
BABEL_5_X_DEV: 77%

Build:
Build:
LAST BUILD BRANCH: fix_script_injection
DEFAULT BRANCH: BABEL_5_X_DEV
Ran 01 Aug 2024 12:34PM UTC
Jobs 1
Files 114
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

01 Aug 2024 11:52AM UTC coverage: 73.538% (+0.003%) from 73.535%
10197752006

push

github

web-flow
Fix behaviour of error message for GRANT (#2810) (#2818)

Currently on executing queries like "GRANT EXECUTE ON PROCEDURE::test TO public;", Babelfish throws error with error message 'GRANT ON PROCEDURE is not currently supported in Babelfish' which is incorrect as the above query has an incorrect syntax. With this change it now shows 'syntax error' for such cases and 'not currently supported' for allowed object types (according to GRANT documentation) which are not supported by us currently.

The issue arrised because the GRANT query is being successfully parsed by our antlr parser and then the check for supported/unsupported occurs resulting in the error being thrown in the TsqlUnsupportedFeatureHandler() rather than the antlr parser.

In the rule definition of GRANT/REVOKE/DENY in TSqlParser.g4, object_type is used which contains some types like PROCEDURE, TABLE which are not syntactically correct according to the GRANT/REVOKE/DENY documentation. In this PR, I have created a new permission_object_type which contains only those types which are syntactically correct for GRANT/REVOKE/DENY and added relevant tests for the same. After this change, Babelfish throws error during the parsing and gives syntax error.


Task: BABEL-5079

Signed-off-by: P Aswini Kumar <aswinii@amazon.com>

6 of 6 new or added lines in 2 files covered. (100.0%)

42452 of 57728 relevant lines covered (73.54%)

110523.81 hits per line

Jobs
ID Job ID Ran Files Coverage
1 10197752006.1 01 Aug 2024 12:34PM UTC 114
73.54
GitHub Action Run
Source Files on build 10197752006
  • Tree
  • List 114
  • Changed 59
  • Source Changed 2
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #10197752006
  • ad7026cd on github
  • Prev Build on BABEL_3_X_DEV (#10197304316)
  • Next Build on BABEL_3_X_DEV (#10213438751)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc