咨询库存项目屏幕属性标签存储属性值的DAC/表及GI访问方法
Stock Items Attributes: DACs/Tables & Generic Inquiry Setup
Hey there! Let's walk through exactly what you need to access those attribute values in a Generic Inquiry (GI) for the Stock Items screen's Attributes tab.
Key DACs & Corresponding Database Tables
The attribute values for Stock Items (and most Acumatica entities) are stored in these core objects:
CSAnswersDAC (database table:CSAnswers): This is the primary table holding the actual attribute values (answers) linked to your inventory items. Each row maps an attribute to a specific stock item via theRefNoteIDfield.CSAttributeDAC (database table:CSAttributes): Stores the definition of each attribute (like its name, type, and settings). Use this if you want to pull attribute names instead of just their IDs in your GI.CSAttributeDetailDAC (database table:CSAttributeDetails): For dropdown/multi-select attributes, this table holds predefined option values and their descriptions. Use it to display user-friendly text instead of raw code values.InventoryItemDAC (database table:InventoryItem): The base DAC for stock items, which you'll use to link to attribute values via itsNoteIDfield.
Setting Up the Generic Inquiry
Follow these steps to build a GI that pulls inventory item attributes:
- Add DACs to your GI: Include
InventoryItem,CSAnswers, and optionallyCSAttributeandCSAttributeDetail. - Configure Joins:
- Link
InventoryItem.NoteIDtoCSAnswers.RefNoteID(this connects each stock item to its attribute values). - If using
CSAttribute, linkCSAnswers.AttributeIDtoCSAttribute.AttributeIDto get attribute names. - For dropdown attributes, link
CSAnswers.AttributeIDtoCSAttributeDetail.AttributeIDandCSAnswers.ValuetoCSAttributeDetail.Valueto retrieve option descriptions.
- Link
- Select Fields: Pick the fields you need, for example:
InventoryItem.InventoryCD(Stock Item ID)CSAttribute.Descr(Attribute Name)CSAnswers.Value(Raw Attribute Value)CSAttributeDetail.Description(Friendly Dropdown Option Text)
- Add Filters (optional but recommended):
- Add a filter for
CSAnswers.EntityTypeequalsInventoryItemto ensure you only pull attributes related to stock items. - Add filters on
InventoryItemfields to narrow down to specific stock items if needed.
- Add a filter for
- Test & Adjust: Run the GI to verify you're seeing the correct attribute values, and tweak joins/fields as necessary based on your attribute types (text, dropdown, etc.).
A quick tip: If you're having trouble seeing the data, double-check that the joins are correctly set up using NoteID/RefNoteID—this is the critical link between stock items and their attributes.
内容的提问来源于stack exchange,提问作者Jerry Welliver
相关产品推荐
相关产品推荐

