ResellerFinder

ResellerFinder.asmx

This web service provides a method to return customers or ship-to based on the distance of a zip code. This can be useful in situations when consumers try to find the nearest store where they can purchase your products.  The distance is calculated based on the latitude and longitude values in the zip code table. The latitude and longitude in the zip code table represent the geographic location center of the zip code area. Therefore, the calculated distance of a customer or ship-to to a particular zip code is not 100% correct.  But it is good enough for most situations.

FindReseller

This method uses a relational engine to execute SQL commands and retrieve customers or ship-to based on a zip code in a certain distance range.

Usage:

FindResellerResult = A.FindResller(UserName, UserPassword, ZipCode, MaxDistance, LocationDataSource, ActiveCustomerOnly, GetAttribute, AttributeWebFlag, GetNotes, NotesWebFlag, GetLinks, GetEcontact, OrderBy, AdditionalWhere, ShipToAdditionalWhere)

Parameters UserName and UserPassword are not used at this moment.

Input Parameter

Parameter

Type

Detail

zipCode

String

Required. Must be a valid 5-digit zip code in the United States.

maxDistance

Double

Required. Indicates the return customer or ship-to records must be within the maximum distance from the zip code.

locationDataSource

String

This indicates where to get the data that matches the distance criteria.  The valid options are B, C and S.

  • C = Customer
  • S = Ship-To
  • B = Both

activeCustomerOnly

String

If you specify Y, then only customers and associated ship-to's whose sales last year or sales this year are greater than zero will be returned in the dataset.  If you need a   more finite way to control the returned records, use additional where parameter.

getAttribute

String

Specify Y to retrieve the corresponding attributes for the customers and ship-to.  This can be helpful if you have certain attribute information to return on the searching result.  Do not indicate “Y” unless you need the data.  Otherwise, performance can get slowed down unnecessarily.

attributesWebFlag

String

If you specify Y to previous parameters, this specifies the criteria that the attribute must be a web attribute before being returned.

getNotes

String

Similar to getAttribute, but for notes.  This can be helpful if you have notes that describe your reseller to return on the search result. Do not indicate “Y” unless you need the data.  Otherwise, performance can get slowed down unnecessarily.

notesWebFlag

String

Similar to attributesWebFlag but for notes.

getLinks

String

Specify “Y” to retrieve links.  This can be helpful if your reseller has a website for you to return on the searching result. Do not indicate “Y” unless you need the data.  Otherwise, performance can get slowed down unnecessarily.

getEcontact

String

“Y” to retrieve eContacts. Do not indicate “Y” unless you need the data.  Otherwise, performance can get slowed down unnecessarily.

orderBy

String

This is the additional order by clause.  Specify the customer or ship to dataset columns.  If you wish to sort by distance, specify “DISTANCE.”

additionalWhere

String

This is the additional where clause when retrieving data from customer table.  Applicable if location data includes customer (e.g., B or C).  For example, you may specify “CUS_TP = ‘GOLD’” to limit the return of customer that its customer type = ‘GOLD’ only.

shipToAdditionalWhere

String

This is the additional where clause to apply when retrieve ship to table.  Applicable if location source includes ship to (e.g., B or S)

 

FindResellerResult Structure

Property

Type

Detail

ReturnCode

Integer

Contains return code. Zero means OK; for other return codes, please see “EliloginService Return Code” section.

AttributeTemplates

Dataset

 

Resellers

DataSet

Contains the following datasets: Customer, Attributes, EContacts, Links and Notes. For detail information of the dataset table, please refer to the following section.

 

AttributeTemplates Structure

When getAttribute = “Y.” This table contains the same column heading as the SYATRFIL table.  It will contain all attribute code records if the return dataset is set to getAttribute = “Y.”

Property

Detail

SYATRFIL_CODE

 

SYATRFIL_DESC_1

 

SYATRFIL_DESC_2

 

SYATRFIL_REF_1_FLAG

 

SYATRFIL_REF_1_LIT

 

..

 

SYATRFIL_REF_5_FLAG

 

SYATRFIL_REF_5_LIT

 

SYATRFIL_DATE_1_FLAG

 

SYATRFIL_DATE_2_LIT

 

 

SYATRFIL_AMT_1_FLAG

 

SYATRFIL_AMT_1_LIT

 

 

 

Resellers Structure

Property

Detail

Customer

Dataset with return records and columns in ARCUSFIL table

ShipTo

Dataset with return records and columns in CPSHPFIL table

Attributes

Dataset with return records and columns in SYATTRIB table

EContact

Dataset with return records and columns in SYCONREL and SYCONTCT tables

Links

Dataset with return records and columns in SYLNKFIL table

Notes

Dataset with return records and columns in NOTES table

 

Code Example

The following sample code will return customers’ records within 20 miles distance from zip code 91789 with customer type equal to “GOLD.”

 

Dim Service As New webServicesReseller.ResellerFinder

Dim Result As New webServicesReseller.FindResellerResult

Result = Service.FindResller("", "", "91789", 20, "C", "", "", "", "", "", "", "", "DISTANCE", "CUS_TP = 'GOLD'", "")

If Result.ReturnCode = 0 Then

    lblResult.Text = "Resellers Found"

Else

    lblResult.Text = "Error! Error code: " + Result.ReturnCode.ToString

End If

ResellerFinder Return Code

0 = OK (No Error),

30000 = Database Error

30001 = No Record Found

30002 = General Error

CLS

Developer Documentations

  1. Received Code 9999 with Web Services Call
  2. Received Return Status Code 3 When Using Elilogin Login Method
  3. Elliott Web Service Requirements
  4. Elliott eStore Checklist
  5. LN API
  6. FN API
  7. RN API
  8. IN and DF API Change (V9.0)
  9. FA API Changes (V9.0)
  10. VA API Changes (V9.0)
  11. CartService
  12. EliarachService
  13. ElicshtxService
  14. EliattrbService
  15. ElisyscdService
  16. EliNoteService
  17. El2rstimService
  18. EliOrderService
  19. ItemInquiry
  20. EliitmiqService
  21. EliShiptoService
  22. El2getfrService
  23. Steps Required to Test ReportWriter in V8.2
  24. Installation of ElliottService, NETcellent’s Web Services for Elliott
  25. ResellerFinder
  26. EliaptrxService
  27. VendorInquiry
  28. EliloginService
  29. ElislsmnService
  30. EliserhsService
  31. EliatpobService
  32. ElievprcService
  33. ElihdtrxService
  34. ElicuswlService
  35. QueryTurnaround
  36. InvoiceInquiry
  37. ElicustmService
  38. EligetcdService
  39. OrderInquiry
  40. EliordiqService
  41. EliecontService
  42. EliautdpService
  43. El2CrCrdService
  44. Log-Timer / ElliottTimer.Ini Support
  45. Alpha Document Number Support (V8.5/V9.0)
  46. ElliottService System.TypeInitializationException
  47. Feature - Printing API to Dynamically Set Number of Copies
  48. The Values and Meanings of Distribution Types - ARDISFIL, APDISFIL, IMDISFIL, BMDISFIL
  49. DD API Changes (V9.0)
  50. PA API (8.5)
  51. Validate License API
  52. AP API
  53. TP API: Temporary Path
  54. Data Structures for Report Desk Defaults and Enforcements
  55. COBOL to VB Interface Programs
  56. IN API: Option to Support Files and Folders Validation
  57. FF API: File Functions
  58. ID API
  59. LK: Links API
  60. FFLNearYou
  61. Report Desk Developing and Debugging
  62. Developing a New Elliott V8.6 Report Desk User Defined Report (UDR)
  63. CustomerInquiry
  64. Elliott API (JSON Web Service)
  65. Animating COBOL Code in Elliott V8.5
  66. Preliminary Programming Changes for Elliott 8.6
  67. CV API
  68. System Lock File Requirements
  69. How to Write Test Codes for C# ESS Projects
  70. Solving the Inability to Debug Elliott on a New Server
  71. Report Desk: Developing Custom Reports
  72. Report Desk Tables
  73. Report Desk Database Delivery Strategy

Feedback and Knowledge Base