Conditional Error 3063

Page 1 of 1

2 Replies - 4576 Views - Last Post: 14 July 2012 - 12:48 PM

#1 AnalyticLunatic  Icon User is offline

  • D.I.C Lover

Reputation: 221
  • View blog
  • Posts: 1,030
  • Joined: 25-June 12

Conditional Error 3063

Posted 12 July 2012 - 12:45 PM

I have the following queries in Access, that when they run, I get "Error No: 3063; Duplicate output destination 'lngPermitNo'." This seems pretty self-explanatory, but I have not been able to discover the issue. Would anyone care to take a crack at what I am assuming is a very simple fix? I am not familiar with this particular error.

The first one is done when there is no ReceiptDate given, thus it is to return all records:

INSERT INTO zztblDailyReceiptSummary ( dtmReceived, intShiftPaid, intPermitCount, lngReceiptTotal, chrReceiptType, chrReceiptGate, lngPermitNo, lngPermitNo )
SELECT IIf(Len(Trim(Nz([dtmclockout])))>0,Format([dtmclockout],"mm/dd/yyyy"),Format([dtmdayout],"mm/dd/yyyy")) AS receiptdate, tblcampers.intShiftOut, tblcampers.lngPermitNo, tblcampers.curPaidatExit, "Camping" AS Expr1, "Exit" AS Expr2, tblcampers.lngPermitNo, tblcampers.lngPermitNo
FROM tblcampers
WHERE (((tblcampers.curPaidatExit)>0) AND ((Len(Trim(Nz(IIf(Len(Trim(Nz([dtmclockout])))>0,Format([dtmclockout],"dd"),Format([dtmdayout],"dd"))))))<>0) AND ((tblcampers.blnVoid)=False))
ORDER BY IIf(Len(Trim(Nz([dtmclockout])))>0,Format([dtmclockout],"mm/dd/yyyy"),Format([dtmdayout],"mm/dd/yyyy")), tblcampers.intShiftOut; 


This second one is supposed to match the Receipt Date only:

DoCmd.RunSQL "INSERT INTO zztblDailyReceiptSummary ( dtmReceived, intShiftPaid, intPermitCount, lngReceiptTotal, chrReceiptType, chrReceiptGate, lngPermitNo ) " & _
" SELECT IIf(Len(Trim(Nz([dtmclockout])))>0,Format([dtmclockout],'mm/dd/yyyy'),Format([dtmdayin],'mm/dd/yyyy')) AS receiptdate, tblvisitors.intShiftOut, tblvisitors.lngPermitNo, " & _
" tblvisitors.curPaidatExit, 'Visitor' AS Expr1, 'Exit' AS Expr2, tblvisitors.lngPermitNo FROM tblvisitors WHERE (((IIf(Len(Trim(Nz([dtmClockOut]))) > 0, Format([dtmClockOut], 'mm/dd/yyyy'), " & _
" Format([dtmDayIn], 'mm/dd/yyyy'))) = '" & strXDate & "') And ((tblvisitors.curPaidatExit) > 0) And ((Len(Trim(Nz(IIf(Len(Trim(Nz([dtmClockOut]))) > 0, Format([dtmClockOut], 'dd'), Format([dtmDayIn], 'dd')))))) <> 0) And ((tblvisitors.blnVoid) = False)) ORDER BY IIf(Len(Trim(Nz([dtmclockout])))>0,Format([dtmclockout],'mm/dd/yyyy'),Format([dtmdayin],'mm/dd/yyyy')), tblvisitors.intShiftOut;"


SLIGHTLY different queries, but they are both receiving the same error based on the condition of being given a date in the ReceiptDate textbox on the Access Form.

Any help as always is most appreciated! :sweatdrop:

Is This A Good Question/Topic? 0
  • +

Replies To: Conditional Error 3063

#2 June7  Icon User is offline

  • D.I.C Addict
  • member icon

Reputation: 104
  • View blog
  • Posts: 904
  • Joined: 09-December 08

Re: Conditional Error 3063

Posted 14 July 2012 - 12:13 PM

Duplicate thread http://www.dreaminco...1&#entry1664201
Was This Post Helpful? 0
  • +
  • -

#3 GunnerInc  Icon User is offline

  • "Hurry up and wait"
  • member icon




Reputation: 858
  • View blog
  • Posts: 2,281
  • Joined: 28-March 11

Re: Conditional Error 3063

Posted 14 July 2012 - 12:48 PM

In the future June7, please use the report button.

*** Closed ***
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1