• Jobs
  • About Us
  • professionals
    • Home
    • Jobs
    • Courses and challenges
  • business
    • Home
    • Post vacancy
    • Our process
    • Pricing
    • Assessments
    • Payroll
    • Blog
    • Sales
    • Salary Calculator

0

196
Views
What is the best approach for API calling for the Records with large attributes?

Hi, let me explain the scenario first.

Say, I have a DB with -

a) 10,000 Records

b) 20 Records/page (pagination)

c) 100 attributes for each Record

Now I need to call an API for getting the Records as pagination. On button click, I also need to see details of any product. Now what is the best approach of the two below?

Approach 1: Call an API for getting the Records as pagination. While calling the API, send all 100 attributes for each Record. Now on button click, show the details of any Record (No new API will be called for details view)

Approach 2: Call an API for getting the Records as pagination. While calling the API, send only the required attributes (maybe 4/5 attributes) for each Record. Now on button click, call a new API and show the details of any Record (with 100 attributes)

Please let me know the best approach of the two. Any other better solution is also appreciable. Thanks in advance.

almost 3 years ago · Juan Pablo Isaza
1 answers
Answer question

0

I think the approach 2 is better because it's good for the UX because user can get the required attributes to work on, So they don't have to wait the unnecessary attributes to do their job. and the same reason for network traffic.

almost 3 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Our process Sales
Legal
Terms and conditions Privacy policy
© 2025 PeakU Inc. All Rights Reserved.

Andres GPT

Recommend me some offers
I have an error