-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to match with date fields? #40
Comments
Hi @Mike-Cleaver-LB - This should work fine. I'm using a date match for my client. How is the date field configured? It is a date on the user object and in the form? My example so you can compare configuration: Log record: Submitted Values: {Contact_Date_of_Birth__c=2001-01-01, Crime_Ref_Number__c=21240000219, Email=[email protected], FirstName=JACK, LastName=TEST, Mobile_Phone_Unformatted__c=07448411354, confirmPassword=HIDDEN, password=HIDDEN} Let me know and might be able to identify if there is an issue to fix. |
I corrected my metadata to be the user api name for birthdate and the error is similar ... |
Hi @Mike-Cleaver-LB - I believe I've spotted the issue. I was able to reproduce it in my customer org based on what you provided above. I'll fix this in v1.9 which is due for release soon. In the code, where it maps the form fields to the user, the component takes everything as a string and doesn't convert to the correct data type for the field. Currently, where the component queries for an existing Person Account/Business Account or creates a new Person Account/Business Account the data type conversion works fine as long as the custom field doesn't exist on the user as well. As soon as it does, it goes bang! There is a call to a function called "convertFormDataToCorrectDataType" which does the conversion, which is not called when checking existence for fields on the User object. So I believe the fix is as follows: Is there a possibility you could push the code from the feature/passwordless branch in a sandbox and test out your query against the new version before I release it please? The fix seems to work on my end. Alternatively, you can get at a beta version to install it here:https://login.salesforce.com/packaging/installPackage.apexp?p0=04tWU0000003g5x - however this does come with a caveat that once in beta, you will break the upgrade path until you manually uninstall and re-install a major release version again. |
Hi team, I am trying to add DOB as a date field and use it for matching.
I have set up a custom DOB field on the user object, and the query references it (several times, the client wants a 3 of 5 match)
but the error is "
Invalid bind expression type of String for column of type Date
" It is passing the date yyyy-mm-dd into the query successfully by my understanding, but presumably it is in the wrong format? I don't see anyway to set the format on a date inputI know how to do it with some apex, but I don't have that option here. Any ideas would be welcome!
The log message is as follows
Form Values:
{Birthdate=1987-12-10, Email=[mike.cleaver+dobtest@.....[trimmed].... password=HIDDEN}
There was a problem executing the specific query in the Custom Query property. Query used:
The text was updated successfully, but these errors were encountered: