I wanted to change a PXSelector attribute on a DAC field to Fluent BQL syntax if possible in order to include a subquery. Is there any way to do a Fluent BQL equivalent of PXSelector that you know of?
Page 1 / 1
Hi
Just add at the end the clause SearchFor
Then you can build your query in BQL Fluent style
Hi
I rushed to give you the missing piece. Here is an example extracted from Acumatica itself
// INItemClass.cs
bPXSelector(typeof(SearchFor<CSAttributeGroup.attributeID>.
Where<CSAttributeGroup.entityClassID.
IsEqual<PX.Data.BQL.RTrim<Use<itemClassID.FromCurrent>.AsString>>.
And<CSAttributeGroup.entityType.IsEqual<Common.Constants.DACName<InventoryItem>>>.
And<CSAttributeGroup.attributeCategory.
IsEqual<CSAttributeGroup.attributeCategory.variant>>.
And<CSAttributeGroup.attributeID.
IsNotEqual<defaultRowMatrixAttributeID.FromCurrent>.
Or<defaultRowMatrixAttributeID.FromCurrent.IsNull>>>),
typeof(CSAttributeGroup.attributeID),
DescriptionField = typeof(CSAttributeGroup.description))]
You can do your complex query using FBQL. However, I have had some weird behaviors in the past. I think last versions of Acumatica have fixed it. Give it a try.
For the sake of learning...
Nevermind, I now see clearly
Thanks
Reply
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.