[ 
https://issues.apache.org/jira/browse/GEODE-3988?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16302026#comment-16302026
 ] 

Fred Krone commented on GEODE-3988:
-----------------------------------

Testing notes:

'primary-key-in-value' did not seem to work.  It's always overriden by the key 
in the entry on a .put(key,value)

'field-mapping' did not seem to work.  Example: if I set 
 --field-mapping=age:name 

it should put the age into the name column of the table.  But throws:

Column name 'NAME' appears more than once times in the column list of an INSERT 
statement.

It works fine if I set all the k,v like this:

--field-mapping=age:age,id:name,name:id

I'll open a new ticket for this. 

> Implement create jdbc-region-mapping command
> --------------------------------------------
>
>                 Key: GEODE-3988
>                 URL: https://issues.apache.org/jira/browse/GEODE-3988
>             Project: Geode
>          Issue Type: Sub-task
>          Components: docs, regions
>            Reporter: Fred Krone
>            Assignee: Darrel Schneider
>             Fix For: 1.4.0
>
>
> {noformat}
> NAME
>     create jdbc-region-mapping
> SYNOPSIS
>     Specify the mapping between DB table columns and the GemFire region 
> fields.
> SYNTAX
>     create jdbc-region-mapping --connection-name=value --region=value 
> --table=value --pdx-name=[value] [--primary-key-in-value] 
> [--fields=field:db-column[,field:db-column...]]
> PARAMETERS
>     connection-name
>         Name of the previously created JDBC connection configuration to be 
> used
>         Required: true
>     pdx-name
>         Name for GemFire PDX to parse the PDX fields.
>         Required: false
>     region
>         Name/path of the region to be associated with DB table.
>       Required: true
>     table
>         Name of DB table to be associated with GemFire region. 
>         Required: true
>     primary-key-in-value
>         Is the value for the primary key located in the region entry value 
> (as opposed to being the entry key).
>         Required: false
>         Default: false (currently)
>     fields
>         Key, value pairs for mapping fields of Pdx instance to database 
> columns.
>         Required: false
>         Default: Pdx field names are used as database column names
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to