简体   繁体   English

如何在 Gemfire 中找到密钥

[英]How to find key in Gemfire

How to find inside Gemfire region, what column defined as key during data load?如何在 Gemfire 区域内查找在数据加载期间定义为键的列?

List and describe is not giving required info列出和描述未提供所需信息

Example i am.looking something smiler to oracke "ALL_CONSTRAINTS" where you can run following sql to find primary key示例我正在寻找一些微笑的东西来 oracke “ALL_CONSTRAINTS”,您可以在其中运行 sql 以查找主键

        SELECT a.COLUMN_NAME
                FROM all_cons_columns a INNER JOIN 
               all_constraints c 
              ON a.constraint_name = c.constraint_name 
                    WHERE c.table_name = 'TBL'
                     AND c.constraint_type = 'P'

I'm not entirely sure about what you mean by find inside Region , but my guess is that you're trying to find wether a particular entry exists within a given GemFire region.我不完全确定find inside Region是什么意思,但我的猜测是您正在尝试查找特定条目是否存在于给定的 GemFire 区域中。

If that's the case, then you can use the get method from the Region class.如果是这种情况,那么您可以使用 class 区域中的get方法。 If you want to use GemFire SHell directly instead of a custom Java application, on the other hand, you can use the get command .另一方面,如果您想直接使用GemFire SHell而不是自定义 Java 应用程序,则可以使用get 命令 Last, but not least, you could also execute a OQL query with the query command , as an example: query --query="SELECT e.value FROM /MyRegion.entries e WHERE e.key='myKey'"最后但同样重要的是,您还可以使用query 命令执行OQL 查询,例如: query --query="SELECT e.value FROM /MyRegion.entries e WHERE e.key='myKey'"

Hope this helps.希望这可以帮助。 Cheers.干杯。

I have found, please find correct solution here我找到了,请在这里找到正确的解决方案

         query --query="select * from /region_name.keySet()"

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM