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

SingleColumnValueFilter Syntax #34

Closed
mithralaya opened this issue Sep 14, 2015 · 2 comments
Closed

SingleColumnValueFilter Syntax #34

mithralaya opened this issue Sep 14, 2015 · 2 comments

Comments

@mithralaya
Copy link

Hello David,

Could you please help me get the syntax right for the following query.

scanner = client
            .table('UserLog')
            .scan({
                //startRow: '1437696000000',
                //maxVersions: 1,
                filter: {
                    "op": "MUST_PASS_ALL",
                    "type": "FilterList",
                    "filters": [
                        {
                            "op": "EQUAL",
                            "type": "SingleColumnValueFilter",
                            "family": "entry",
                            "qualifier": "merchantId",
                            "comparator": {
                                "value": "30",
                                "type": "BinaryComparator"
                            },
                            "ifMissing": true,
                            "latestVersion": true
                        },
                        {
                            "op": "EQUAL",
                            "type": "SingleColumnValueFilter",
                            "family": "entry",
                            "qualifier": "tag",
                            "comparator": {
                                "value": "CloseOut, Transaction",
                                "type": "BinaryComparator"
                            },
                            "ifMissing": true,
                            "latestVersion": true
                        },
                        {
                            "op": "GREATER_OR_EQUAL",
                            "type": "SingleColumnValueFilter",
                            "family": "entry",
                            "qualifier": "addedTime",
                            "comparator": {
                                "value": "1437696000000",
                                "type": "BinaryComparator"
                            },
                            "ifMissing": true,
                            "latestVersion": true
                        },
                        {
                            "op": "LESS_OR_EQUAL",
                            "type": "SingleColumnValueFilter",
                            "family": "entry",
                            "qualifier": "addedTime",
                            "comparator": {
                                "value": "1437764400000",
                                "type": "BinaryComparator"
                            },
                            "ifMissing": true,
                            "latestVersion": true
                        }
                    ]
                }
            });

Many thanks,
Karthik

@wdavidw
Copy link
Member

wdavidw commented Sep 14, 2015

Thats a tuff one, getting this right isnt easy as not every filter are supported and implented the same (some need encoding, other dont) and i didnt try all of them

@wdavidw
Copy link
Member

wdavidw commented Aug 28, 2018

Old issue, closing.

@wdavidw wdavidw closed this as completed Aug 28, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants