Skip to main content
Answer

PXSelect isn't retrieving data

  • May 26, 2023
  • 7 replies
  • 355 views

abdallaahmed61
Varsity III
Forum|alt.badge.img+1

i have created a dac from a table

but when i select from it using pxselect it dosent get any data but in the screen it shows the data normally

the searchinspection in the below picture is giving me the default data everytime i debugged it the inspection number is sent normally to the select but it dosent return any data from database.

 

Best answer by abdallaahmed61

i solved it by clearing the cache

7 replies

abdallaahmed61
Varsity III
Forum|alt.badge.img+1

this is my DAC Code


abdallaahmed61
Varsity III
Forum|alt.badge.img+1
  • Author
  • Varsity III
  • Answer
  • May 26, 2023

i solved it by clearing the cache


Chris Hackett
Community Manager
Forum|alt.badge.img
  • Acumatica Community Manager
  • May 26, 2023

Thank you for sharing your solution with the community @abdallaahmed61 !


darylbowman
Captain II
Forum|alt.badge.img+15

@abdallaahmed61 - I have to admit, I’m really confused by this code. What is the purpose of performing a BQL select against the same table to get the same record result?

inspectionForm.Current is going to contain the record currently displayed in your graph. But rather than use that record, the data view delegate for that view is going to duplicate itself into a new view where the current record is matching itself, and then return that record instead of the normal one.

You don’t need to use a data view delegate. That is simply a useful tool if you need to manipulate the data you want to return. In this case, I think you’d be better off without it.


abdallaahmed61
Varsity III
Forum|alt.badge.img+1

@abdallaahmed61 - I have to admit, I’m really confused by this code. What is the purpose of performing a BQL select against the same table to get the same record result?

inspectionForm.Current is going to contain the record currently displayed in your graph. But rather than use that record, the data view delegate for that view is going to duplicate itself into a new view where the current record is matching itself, and then return that record instead of the normal one.

You don’t need to use a data view delegate. That is simply a useful tool if you need to manipulate the data you want to return. In this case, I think you’d be better off without it.

my code was getting me crazy by not working right 

thats why i played a bit with my code 

i know its not good way i was just trying to figure out why the code isnt working as i want

 


darylbowman
Captain II
Forum|alt.badge.img+15

Understood, and for sure it takes a bit to understand how everything works. I'm simply suggesting that it may create issues farther down the road the way you are doing it, as you've already experienced. I think your best bet would be to remove the data view delegate and also possibly the searchInspection data view.


abdallaahmed61
Varsity III
Forum|alt.badge.img+1

Understood, and for sure it takes a bit to understand how everything works. I'm simply suggesting that it may create issues farther down the road the way you are doing it, as you've already experienced. I think your best bet would be to remove the data view delegate and also possibly the searchInspection data view.

Yup i did that after i solved the main problem.

The main problem was i was using the same view in my tabs that was making the screen go crazy and make terrible things 😂