Skip to content
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

[Bug] dbt/quickbooks package breaking on build due to non-numerical sales_item_item_id #23

Closed
2 of 4 tasks
evancole-untitled opened this issue Mar 14, 2022 · 5 comments
Closed
2 of 4 tasks
Assignees
Labels
bug Something isn't working

Comments

@evancole-untitled
Copy link

evancole-untitled commented Mar 14, 2022

Is there an existing issue for this?

  • I have searched the existing issues

Describe the issue

I'm having some trouble getting the Quickbooks dbt package running for a client of ours.

The problem seems to be that there is an ItemRef field in Quickbooks that is typically a numerical ID, but which is sometimes set to SHIPPING_ITEM_ID in some quickbook configurations. Fivetran correctly pulls it over to our Redshift, but the Quickbooks dbt_quickbooks_source package attempts to cast this ID to integer, causing it to crash.

Example: in dbt_packages/quickbooks_source/models/stg_quickbooks__credit_memo_line.sql the sales_item_item_id field seems to be populated by this ItemRef value, which makes all of my credit memo models fail.

Relevant error log or model output

13:45:03  Running with dbt=1.0.0
13:45:04  Found 103 models, 58 tests, 0 snapshots, 2 analyses, 509 macros, 0 operations, 0 seed files, 39 sources, 0 exposures, 0 metrics
13:45:04  
13:45:05  Concurrency: 4 threads (target='dev')
13:45:05  
13:45:05  1 of 76 START table model dbt.my_first_dbt_model................................ [RUN]
13:45:05  2 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__account_tmp..... [RUN]
13:45:05  3 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__address_tmp..... [RUN]
13:45:05  4 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__bill_line_tmp... [RUN]
13:45:07  4 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__bill_line_tmp [CREATE VIEW in 1.55s]
13:45:07  5 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__bill_linked_txn_tmp [RUN]
13:45:07  3 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__address_tmp [CREATE VIEW in 1.80s]
13:45:07  6 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__bill_payment_line_tmp [RUN]
13:45:08  1 of 76 OK created table model dbt.my_first_dbt_model........................... [SELECT in 2.15s]
13:45:08  7 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__bill_payment_tmp [RUN]
13:45:08  2 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__account_tmp [CREATE VIEW in 2.50s]
13:45:08  8 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__bill_tmp........ [RUN]
13:45:08  5 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__bill_linked_txn_tmp [CREATE VIEW in 1.23s]
13:45:08  9 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__bundle_item_tmp. [RUN]
13:45:09  6 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__bill_payment_line_tmp [CREATE VIEW in 1.42s]
13:45:09  10 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__bundle_tmp..... [RUN]
13:45:09  7 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__bill_payment_tmp [CREATE VIEW in 1.54s]
13:45:09  11 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__customer_tmp... [RUN]
13:45:10  8 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__bill_tmp... [CREATE VIEW in 1.71s]
13:45:10  12 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__department_tmp. [RUN]
13:45:10  9 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__bundle_item_tmp [CREATE VIEW in 1.87s]
13:45:10  13 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__deposit_line_tmp [RUN]
13:45:10  10 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__bundle_tmp [CREATE VIEW in 1.78s]
13:45:10  14 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__deposit_tmp.... [RUN]
13:45:11  11 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__customer_tmp [CREATE VIEW in 1.61s]
13:45:11  15 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__estimate_line_tmp [RUN]
13:45:11  12 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__department_tmp [CREATE VIEW in 1.38s]
13:45:11  16 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__estimate_tmp... [RUN]
13:45:11  13 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__deposit_line_tmp [CREATE VIEW in 1.20s]
13:45:11  17 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__invoice_line_bundle_tmp [RUN]
13:45:12  14 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__deposit_tmp [CREATE VIEW in 1.16s]
13:45:12  18 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__invoice_line_tmp [RUN]
13:45:12  15 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__estimate_line_tmp [CREATE VIEW in 1.16s]
13:45:12  19 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__invoice_linked_txn_tmp [RUN]
13:45:12  16 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__estimate_tmp [CREATE VIEW in 1.16s]
13:45:12  20 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__invoice_tmp.... [RUN]
13:45:12  17 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__invoice_line_bundle_tmp [CREATE VIEW in 1.20s]
13:45:12  21 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__item_tmp....... [RUN]
13:45:13  18 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__invoice_line_tmp [CREATE VIEW in 1.18s]
13:45:13  22 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__journal_entry_line_tmp [RUN]
13:45:13  19 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__invoice_linked_txn_tmp [CREATE VIEW in 1.17s]
13:45:13  23 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__journal_entry_tmp [RUN]
13:45:13  20 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__invoice_tmp [CREATE VIEW in 1.20s]
13:45:13  24 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__payment_line_tmp [RUN]
13:45:14  21 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__item_tmp.. [CREATE VIEW in 1.14s]
13:45:14  25 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__payment_tmp.... [RUN]
13:45:14  22 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__journal_entry_line_tmp [CREATE VIEW in 1.14s]
13:45:14  26 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__purchase_line_tmp [RUN]
13:45:14  23 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__journal_entry_tmp [CREATE VIEW in 1.18s]
13:45:14  27 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__purchase_tmp... [RUN]
13:45:15  24 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__payment_line_tmp [CREATE VIEW in 1.17s]
13:45:15  28 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__refund_receipt_line_tmp [RUN]
13:45:15  25 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__payment_tmp [CREATE VIEW in 1.16s]
13:45:15  29 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__refund_receipt_tmp [RUN]
13:45:15  26 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__purchase_line_tmp [CREATE VIEW in 1.17s]
13:45:15  30 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__sales_receipt_line_tmp [RUN]
13:45:16  27 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__purchase_tmp [CREATE VIEW in 1.18s]
13:45:16  31 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__sales_receipt_tmp [RUN]
13:45:16  28 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__refund_receipt_line_tmp [CREATE VIEW in 1.18s]
13:45:16  32 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__transfer_tmp... [RUN]
13:45:16  29 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__refund_receipt_tmp [CREATE VIEW in 1.18s]
13:45:16  33 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__vendor_credit_line_tmp [RUN]
13:45:16  30 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__sales_receipt_line_tmp [CREATE VIEW in 1.17s]
13:45:16  34 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__vendor_credit_tmp [RUN]
13:45:17  31 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__sales_receipt_tmp [CREATE VIEW in 1.20s]
13:45:17  35 of 76 START view model dbt_quickbooks_staging.stg_quickbooks__vendor_tmp..... [RUN]
13:45:17  32 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__transfer_tmp [CREATE VIEW in 1.40s]
13:45:17  36 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__bill_line..... [RUN]
13:45:17  33 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__vendor_credit_line_tmp [CREATE VIEW in 1.42s]
13:45:17  37 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__address....... [RUN]
13:45:18  34 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__vendor_credit_tmp [CREATE VIEW in 1.44s]
13:45:18  38 of 76 START view model dbt.my_second_dbt_model............................... [RUN]
13:45:18  35 of 76 OK created view model dbt_quickbooks_staging.stg_quickbooks__vendor_tmp [CREATE VIEW in 1.13s]
13:45:18  39 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__account....... [RUN]
13:45:19  38 of 76 OK created view model dbt.my_second_dbt_model.......................... [CREATE VIEW in 1.00s]
13:45:19  40 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__bill_linked_txn [RUN]
13:45:19  36 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__bill_line [SELECT in 2.11s]
13:45:19  41 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__bill_payment_line [RUN]
13:45:20  37 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__address.. [SELECT in 2.58s]
13:45:20  42 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__bill_payment.. [RUN]
13:45:20  39 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__account.. [SELECT in 2.39s]
13:45:20  43 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__bill.......... [RUN]
13:45:21  40 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__bill_linked_txn [SELECT in 2.07s]
13:45:21  44 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__bundle_item... [RUN]
13:45:21  41 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__bill_payment_line [SELECT in 1.87s]
13:45:21  45 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__bundle........ [RUN]
13:45:22  42 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__bill_payment [SELECT in 2.01s]
13:45:22  46 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__customer...... [RUN]
13:45:23  43 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__bill..... [SELECT in 2.26s]
13:45:23  47 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__department.... [RUN]
13:45:23  44 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__bundle_item [SELECT in 2.12s]
13:45:23  48 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__deposit_line.. [RUN]
13:45:23  45 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__bundle... [SELECT in 2.05s]
13:45:23  49 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__deposit....... [RUN]
13:45:24  46 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__customer. [SELECT in 1.77s]
13:45:24  50 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__estimate_line. [RUN]
13:45:25  47 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__department [SELECT in 1.91s]
13:45:25  51 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__estimate...... [RUN]
13:45:25  48 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__deposit_line [SELECT in 2.37s]
13:45:25  52 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__invoice_line_bundle [RUN]
13:45:26  49 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__deposit.. [SELECT in 2.39s]
13:45:26  53 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__invoice_line.. [RUN]
13:45:26  50 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__estimate_line [SELECT in 2.15s]
13:45:26  54 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__invoice_linked_txn [RUN]
13:45:26  51 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__estimate. [SELECT in 1.65s]
13:45:26  55 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__invoice....... [RUN]
13:45:27  53 of 76 ERROR creating table model dbt_quickbooks_staging.stg_quickbooks__invoice_line [ERROR in 1.13s]
13:45:27  56 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__item.......... [RUN]
13:45:27  52 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__invoice_line_bundle [SELECT in 1.47s]
13:45:27  57 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__journal_entry_line [RUN]
13:45:28  54 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__invoice_linked_txn [SELECT in 1.71s]
13:45:28  58 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__journal_entry. [RUN]
13:45:29  55 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__invoice.. [SELECT in 2.53s]
13:45:29  59 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__payment_line.. [RUN]
13:45:31  56 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__item..... [SELECT in 3.83s]
13:45:31  60 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__payment....... [RUN]
13:45:31  57 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__journal_entry_line [SELECT in 4.18s]
13:45:31  61 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__purchase_line. [RUN]
13:45:31  58 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__journal_entry [SELECT in 3.59s]
13:45:31  62 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__purchase...... [RUN]
13:45:32  59 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__payment_line [SELECT in 2.78s]
13:45:32  63 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__refund_receipt_line [RUN]
13:45:33  60 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__payment.. [SELECT in 2.30s]
13:45:33  64 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__refund_receipt [RUN]
13:45:33  63 of 76 ERROR creating table model dbt_quickbooks_staging.stg_quickbooks__refund_receipt_line [ERROR in 1.71s]
13:45:33  65 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__sales_receipt_line [RUN]
13:45:34  62 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__purchase. [SELECT in 2.71s]
13:45:34  66 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__sales_receipt. [RUN]
13:45:34  61 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__purchase_line [SELECT in 3.18s]
13:45:34  67 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__transfer...... [RUN]
13:45:35  65 of 76 ERROR creating table model dbt_quickbooks_staging.stg_quickbooks__sales_receipt_line [ERROR in 1.54s]
13:45:35  68 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__vendor_credit_line [RUN]
13:45:35  64 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__refund_receipt [SELECT in 2.21s]
13:45:35  69 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__vendor_credit. [RUN]
13:45:37  66 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__sales_receipt [SELECT in 2.85s]
13:45:37  70 of 76 START table model dbt_quickbooks_staging.stg_quickbooks__vendor........ [RUN]
13:45:37  68 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__vendor_credit_line [SELECT in 2.66s]
13:45:38  67 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__transfer. [SELECT in 3.30s]
13:45:38  69 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__vendor_credit [SELECT in 3.11s]
13:45:38  71 of 76 SKIP relation dbt_quickbooks.quickbooks__general_ledger................ [SKIP]
13:45:38  72 of 76 SKIP relation dbt_quickbooks.quickbooks__general_ledger_by_period...... [SKIP]
13:45:38  73 of 76 SKIP relation dbt_quickbooks.quickbooks__balance_sheet................. [SKIP]
13:45:38  74 of 76 SKIP relation dbt_quickbooks.quickbooks__profit_and_loss............... [SKIP]
13:45:39  70 of 76 OK created table model dbt_quickbooks_staging.stg_quickbooks__vendor... [SELECT in 1.85s]
13:45:39  75 of 76 START table model dbt_quickbooks.quickbooks__ap_ar_enhanced............ [RUN]
13:45:39  76 of 76 SKIP relation dbt_quickbooks.quickbooks__expenses_sales_enhanced....... [SKIP]
13:45:41  75 of 76 OK created table model dbt_quickbooks.quickbooks__ap_ar_enhanced....... [SELECT in 2.03s]
13:45:41  
13:45:41  Finished running 35 view models, 41 table models in 37.61s.
13:45:41  
13:45:41  Completed with 3 errors and 0 warnings:
13:45:41  
13:45:41  Database Error in model stg_quickbooks__invoice_line (models/stg_quickbooks__invoice_line.sql)
13:45:41    Invalid digit, Value 'S', Pos 0, Type: Integer 
13:45:41    DETAIL:  
13:45:41      -----------------------------------------------
13:45:41      error:  Invalid digit, Value 'S', Pos 0, Type: Integer 
13:45:41      code:      1207
13:45:41      context:   SHIPPING_ITEM_ID
13:45:41      query:     72862595
13:45:41      location:  :0
13:45:41      process:   query0_108_72862595 [pid=0]
13:45:41      -----------------------------------------------
13:45:41    compiled SQL at target/run/quickbooks_source/models/stg_quickbooks__invoice_line.sql
13:45:41  
13:45:41  Database Error in model stg_quickbooks__refund_receipt_line (models/stg_quickbooks__refund_receipt_line.sql)
13:45:41    Invalid digit, Value 'S', Pos 0, Type: Integer 
13:45:41    DETAIL:  
13:45:41      -----------------------------------------------
13:45:41      error:  Invalid digit, Value 'S', Pos 0, Type: Integer 
13:45:41      code:      1207
13:45:41      context:   SHIPPING_ITEM_ID
13:45:41      query:     72862755
13:45:41      location:  :0
13:45:41      process:   query0_72_72862755 [pid=0]
13:45:41      -----------------------------------------------
13:45:41    compiled SQL at target/run/quickbooks_source/models/stg_quickbooks__refund_receipt_line.sql
13:45:41  
13:45:41  Database Error in model stg_quickbooks__sales_receipt_line (models/stg_quickbooks__sales_receipt_line.sql)
13:45:41    Invalid digit, Value 'S', Pos 0, Type: Integer 
13:45:41    DETAIL:  
13:45:41      -----------------------------------------------
13:45:41      error:  Invalid digit, Value 'S', Pos 0, Type: Integer 
13:45:41      code:      1207
13:45:41      context:   SHIPPING_ITEM_ID
13:45:41      query:     72862802
13:45:41      location:  :0
13:45:41      process:   query0_108_72862802 [pid=0]
13:45:41      -----------------------------------------------
13:45:41    compiled SQL at target/run/quickbooks_source/models/stg_quickbooks__sales_receipt_line.sql
13:45:41  
13:45:41  Done. PASS=68 WARN=0 ERROR=3 SKIP=5 TOTAL=76

Expected behavior

the varchar field sales_item_item_id is imported as a varchar or text and the build completes successfully

dbt Project configurations

name: 'my_transformations'
version: '1.0.3'
config-version: 2

profile: 'my_transformations'

model-paths: ["models"]
analysis-paths: ["analyses"]
test-paths: ["tests"]
seed-paths: ["seeds"]
macro-paths: ["macros"]
snapshot-paths: ["snapshots"]

target-path: "target" # directory which will store compiled SQL files
clean-targets: # directories to be removed by dbt clean

  • "target"
  • "dbt_packages"

models:
my_transformations:
staging:
+materialized: view
shopify:
+schema: staging

vars:

quickbooks vars

quickbooks_database: dev
quickbooks_schema: fivetran_quickbooks

  • the model names, connection and project name have been changed for client confidentiality

Package versions

packages:

  • package: fivetran/quickbooks
    version: 0.4.0

What database are you using dbt with?

redshift

dbt Version

installed version: 1.0.3
latest version: 1.0.3

Up to date!

Plugins:

  • postgres: 1.0.3 - Up to date!
  • redshift: 1.0.0 - Up to date!

Additional Context

No response

Are you willing to open a PR to help address this issue?

  • Yes.
  • Yes, but I will need assistance and will schedule time during our office hours for guidance
  • No.
@evancole-untitled evancole-untitled added the bug Something isn't working label Mar 14, 2022
@evancole-untitled
Copy link
Author

The logs are from a previous run, before I had a few other packages installed and before I updated dbt to 1.0.3. However, updating to 1.0.3 did not resolve the issue, so I included the more recent version info reflect my current configuration.

@evancole-untitled
Copy link
Author

Below is a list of what I believe to be affected models.

(dbt-env) evan@evan-XPS-15-9500:~/code/dbt/my-transformations/my_transformations/dbt_packages$ grep -r 'cast(sales_item_item' | grep -v '"'
quickbooks_source/models/stg_quickbooks__sales_receipt_line.sql: cast(sales_item_item_id as {{ dbt_utils.type_int() }}) as sales_item_item_id,
quickbooks_source/models/stg_quickbooks__invoice_line_bundle.sql: cast(sales_item_item_id as {{ dbt_utils.type_int() }}) as sales_item_item_id,
quickbooks_source/models/stg_quickbooks__invoice_line.sql: cast(sales_item_item_id as {{ dbt_utils.type_int() }}) as sales_item_item_id,
quickbooks_source/models/stg_quickbooks__credit_memo_line.sql: cast(sales_item_item_id as {{ dbt_utils.type_int() }}) as sales_item_item_id,
quickbooks_source/models/stg_quickbooks__refund_receipt_line.sql: cast(sales_item_item_id as {{ dbt_utils.type_int() }}) as sales_item_item_id,

@fivetran-joemarkiewicz
Copy link
Contributor

@evancole-untitled I just made a few changes and see the error is resolved on my end. Would you be able to try the following branch of the Quickbooks package and let me know if you still see the error.

packages:
  - git: https://github.com/fivetran/dbt_quickbooks.git
    revision: bugfix/evancole-untitled-casting
    warn-unpinned: false

@fivetran-joemarkiewicz
Copy link
Contributor

After adjusting the account_name within the int_quickbooks__retained_earnings model, we noticed the issue resolved itself.

I will be making a few last minute updates to the package and will be preparing it for review. Once it is approved during the review phase we will plan to merge this into the next release!

@fivetran-joemarkiewicz fivetran-joemarkiewicz self-assigned this Apr 7, 2022
@fivetran-joemarkiewicz
Copy link
Contributor

@evancole-untitled this issue will now be resolved in the latest version of the dbt_quickbooks v0.5.0 release! You can expect this release to be live at the top of the hour. Thank you again for all your help on pushing this bugfix along!

Feel free to open another issue if you encounter any errors, or open a FR if you would like to see more functionality from the package 😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants