Forum Discussion
error when try to apply changes after creating function
- 6 years ago
Hi amaleranda ,
Try to cancel the relationship between the table where entname is located and other tables, and disable the "enhanced dataset metadata" option. Then execute the custom function for entname in the query editor.
Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi amaleranda ,
Try to cancel the relationship between the table where entname is located and other tables, and disable the "enhanced dataset metadata" option. Then execute the custom function for entname in the query editor.
Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- amaleranda6 years agoPost Patron
- amaleranda6 years agoPost Patron
Below is my PowerQuery. I use this funtion to invoke on a tabel with ServerName and EntName. I am able to invoke the function without any issues but I come across above message when I try to apply changes. I assume its due to the higilited step, but I have no Idea how to remove that step as I need to exand my jason sting.
(ServerName as text, EntName as text) as table =>
let
Source = Json.Document(Web.Contents("http://"&ServerName&"/datasnap/rest/TServerMthods1/getClasData/"&EntName&"/GetAVens")),
result = Source[result],
result1 = result{0},
#"Converted to Table" = Table.FromList(result1, Splitter.SplitByNothing(), null, null, ExtraValues.Error),
#"Expanded Column1" = Table.ExpandRecordColumn(#"Converted to Table", "Column1", {"NUMBER", "CODE", "NAME", "CATEGORY", "TERMS_CODE", "SHIP_CODE", "BILLER_COD", "TAX_CODE", "DISC_CODE", "PERSON_ORD", "PERSON_ACT", "BAL_FWDOPN", "AGE_FISCAL", "CREDIT_LIM", "TOTAL_DUE", "COLLEC_REF", "COLLEC_DAT", "YTD_PURCH", "YTD_DISCTK", "YTD_PAY", "YTD_RETURN", "YTD_DISC", "LST_PURNO", "LST_PURDT", "LST_PAYNO", "LST_PAYDT", "LST_RETNO", "LST_RETDT", "LST_PURAMT", "LST_PAYAMT", "LST_RETAMT", "CREATE_DT", "LST_CHQNO", "DUEDT_CTRL", "DUEDT_DAYS", "TEMP", "YTD_FINCHG", "HIGHST_DUE", "COMMENT", "DISC_DAYS", "PAY_BY", "FORMAT_PAY", "FAX_ACCT", "BANK_NAME", "BSB_NO", "ACCT_NO", "ACCT_NAME", "CHQ_FORMAT", "ORD_FORMAT", "PROD_TYPE", "PP_TYPE", "DAYS_FLOAT", "GL_ACCT", "VC_NUMBER", "CURRENCY", "BRANCH", "PAY_MODE", "PAY_TRANS", "REMITTANCE", "FAX_NUMBER", "VC_NOTES", "SWIFT_CODE"}, {"NUMBER", "CODE", "NAME", "CATEGORY", "TERMS_CODE", "SHIP_CODE", "BILLER_COD", "TAX_CODE", "DISC_CODE", "PERSON_ORD", "PERSON_ACT", "BAL_FWDOPN", "AGE_FISCAL", "CREDIT_LIM", "TOTAL_DUE", "COLLEC_REF", "COLLEC_DAT", "YTD_PURCH", "YTD_DISCTK", "YTD_PAY", "YTD_RETURN", "YTD_DISC", "LST_PURNO", "LST_PURDT", "LST_PAYNO", "LST_PAYDT", "LST_RETNO", "LST_RETDT", "LST_PURAMT", "LST_PAYAMT", "LST_RETAMT", "CREATE_DT", "LST_CHQNO", "DUEDT_CTRL", "DUEDT_DAYS", "TEMP", "YTD_FINCHG", "HIGHST_DUE", "COMMENT", "DISC_DAYS", "PAY_BY", "FORMAT_PAY", "FAX_ACCT", "BANK_NAME", "BSB_NO", "ACCT_NO", "ACCT_NAME", "CHQ_FORMAT", "ORD_FORMAT", "PROD_TYPE", "PP_TYPE", "DAYS_FLOAT", "GL_ACCT", "VC_NUMBER", "CURRENCY", "BRANCH", "PAY_MODE", "PAY_TRANS", "REMITTANCE", "FAX_NUMBER", "VC_NOTES", "SWIFT_CODE"})
in
#"Expanded Column1"