Drew Davies Posted October 21, 2021 Share Posted October 21, 2021 Hi all, I've recently updated to the new Importer and whilst attempting to configure the conf.json I keep running into an issue where the value of 'status' that we're passing over is not being accepted. Here is the relevant line from the SQL query: THEN 'active' ELSE 'archived' END AS [status] Here is the entry in conf.json: "Status":{ "Action":"Both", "Value":"{{.status}}" }, The error states: Error: The value '{{.status}}' for element <accountStatus> is not an allowable value at location '/methodCall/params/accountStatus' Can anyone advise what I've done wrong? Link to comment Share on other sites More sharing options...
Steve Giller Posted October 21, 2021 Share Posted October 21, 2021 @Drew Davies Active and Archived are display values - in the database you need to use 0 for Active and 2 for Archived. Link to comment Share on other sites More sharing options...
Drew Davies Posted October 21, 2021 Author Share Posted October 21, 2021 @Steve Giller No luck with that either I'm afraid. Here's the snippet from the documentation on the wiki: "Status":{ "Action":"Both", /* options : Create/Update/Both ; on what action to change the User Account Status */ "Value":"active" /* options : active/suspended/archived */ }, Link to comment Share on other sites More sharing options...
Steve Giller Posted October 21, 2021 Share Posted October 21, 2021 @Drew Davies Sorry, my mistake - I think I misread the error. 2 hours ago, Drew Davies said: The value '{{.status}}' for element <accountStatus> is not an allowable value It's the {{.status}} that's not being accepted. The Tool translates the active/suspended/archived to the correct numeric value. Can I check that you're using the SQL User Import tool? If so which version are you using, and what is your Data Source? Link to comment Share on other sites More sharing options...
Drew Davies Posted October 21, 2021 Author Share Posted October 21, 2021 @Steve Giller I'm using the latest importer that I extracted from goDb2HUserImport_win_x64_v2_2_8.zip on Releases · hornbill/goDb2HUserImport · GitHub MSSQL Server is the source and I've been using this documentation: SQL User Import - Hornbill Link to comment Share on other sites More sharing options...
Drew Davies Posted October 21, 2021 Author Share Posted October 21, 2021 And although I'm sure you already presumed as much, all other values that I'm passing into it are being accepted. It's only the Status that it's taking issue to. Link to comment Share on other sites More sharing options...
Drew Davies Posted October 22, 2021 Author Share Posted October 22, 2021 Bump as this is still an issue. Is it a case of the importer only accepting hard-coded values? I'd rather do it all with a single .json file than have to use multiple Link to comment Share on other sites More sharing options...
SamS Posted December 23, 2021 Share Posted December 23, 2021 (edited) Hi @Drew Davies, The value set in Status.Value isn't actually merged with data from the DB. The utility is literally passing through the value set in the configuration file. It's on my radar - I'll get it added in 2.3.1 (or so; check the CHANGELOG). FYI: there are two places within the utility-code which expect that to be static within the configuration (so it is not as easy as "just merge"). ---> added to 2.3.1 : https://github.com/hornbill/goDb2HUserImport/releases/latest Edited December 23, 2021 by SamS Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now