ColumnConfigurationProperty Struct
Provides information about how Amazon Kendra should use the columns of a database in an index.
| Source | |
|---|---|
| Type last changed |
Example
ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_kendra as kendra } from 'aws-cdk-lib';
const columnConfigurationProperty: kendra.CfnDataSource.ColumnConfigurationProperty = {
changeDetectingColumns: ['changeDetectingColumns'],
documentDataColumnName: 'documentDataColumnName',
documentIdColumnName: 'documentIdColumnName',
// the properties below are optional
documentTitleColumnName: 'documentTitleColumnName',
fieldMappings: [{
dataSourceFieldName: 'dataSourceFieldName',
indexFieldName: 'indexFieldName',
// the properties below are optional
dateFieldFormat: 'dateFieldFormat',
}],
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_kendra as kendra
column_configuration_property = kendra.CfnDataSource.ColumnConfigurationProperty(
change_detecting_columns=["changeDetectingColumns"],
document_data_column_name="documentDataColumnName",
document_id_column_name="documentIdColumnName",
# the properties below are optional
document_title_column_name="documentTitleColumnName",
field_mappings=[kendra.CfnDataSource.DataSourceToIndexFieldMappingProperty(
data_source_field_name="dataSourceFieldName",
index_field_name="indexFieldName",
# the properties below are optional
date_field_format="dateFieldFormat"
)]
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.kendra.*;
ColumnConfigurationProperty columnConfigurationProperty = ColumnConfigurationProperty.builder()
.changeDetectingColumns(List.of("changeDetectingColumns"))
.documentDataColumnName("documentDataColumnName")
.documentIdColumnName("documentIdColumnName")
// the properties below are optional
.documentTitleColumnName("documentTitleColumnName")
.fieldMappings(List.of(DataSourceToIndexFieldMappingProperty.builder()
.dataSourceFieldName("dataSourceFieldName")
.indexFieldName("indexFieldName")
// the properties below are optional
.dateFieldFormat("dateFieldFormat")
.build()))
.build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.Kendra;
var columnConfigurationProperty = new ColumnConfigurationProperty {
ChangeDetectingColumns = new [] { "changeDetectingColumns" },
DocumentDataColumnName = "documentDataColumnName",
DocumentIdColumnName = "documentIdColumnName",
// the properties below are optional
DocumentTitleColumnName = "documentTitleColumnName",
FieldMappings = new [] { new DataSourceToIndexFieldMappingProperty {
DataSourceFieldName = "dataSourceFieldName",
IndexFieldName = "indexFieldName",
// the properties below are optional
DateFieldFormat = "dateFieldFormat"
} }
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"
columnConfigurationProperty := &ColumnConfigurationProperty{
ChangeDetectingColumns: []*string{
jsii.String("changeDetectingColumns"),
},
DocumentDataColumnName: jsii.String("documentDataColumnName"),
DocumentIdColumnName: jsii.String("documentIdColumnName"),
// the properties below are optional
DocumentTitleColumnName: jsii.String("documentTitleColumnName"),
FieldMappings: []interface{}{
&DataSourceToIndexFieldMappingProperty{
DataSourceFieldName: jsii.String("dataSourceFieldName"),
IndexFieldName: jsii.String("indexFieldName"),
// the properties below are optional
DateFieldFormat: jsii.String("dateFieldFormat"),
},
},
}
Properties
changeDetectingColumnsstring[]change_detecting_columnstyping.List[str]changeDetectingColumnsList<String>ChangeDetectingColumnsstring[]ChangeDetectingColumns*[]*string required #One to five columns that indicate when a document in the database has changed.
documentDataColumnNamestringdocument_data_column_namestrdocumentDataColumnNameStringDocumentDataColumnNamestringDocumentDataColumnName*string required #The column that contains the contents of the document.
documentIdColumnNamestringdocument_id_column_namestrdocumentIdColumnNameStringDocumentIdColumnNamestringDocumentIdColumnName*string required #The column that provides the document's identifier.
documentTitleColumnNameoptionalstringdocument_title_column_nameoptionalstrdocumentTitleColumnNameoptionalStringDocumentTitleColumnNameoptionalstringDocumentTitleColumnNameoptional*string #The column that contains the title of the document.
fieldMappingsoptionalIResolvable | IResolvable | CfnDataSource.field_mappingsoptionaltyping.Union[IResolvable, typing.List[typing.Union[IResolvable, DataSourceToIndexFieldMappingProperty]]]fieldMappingsoptionalIResolvableFieldMappingsoptionalIResolvableFieldMappingsoptionalinterface{} #An array of objects that map database column names to the corresponding fields in an index.
You must first create the fields in the index using the UpdateIndex operation.