hwj.log 107 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411
  1. INFO 2019-10-17 10:11:05,598 basehttp 124 "GET /areas/ HTTP/1.1" 200 10
  2. INFO 2019-10-17 13:26:27,171 autoreload 597 Watching for file changes with StatReloader
  3. INFO 2019-10-17 13:27:09,435 autoreload 217 E:\12446\PycharmProjects\wangli\wanjia\awj\awj\setting\dev.py changed, reloading.
  4. INFO 2019-10-17 13:27:10,260 autoreload 597 Watching for file changes with StatReloader
  5. INFO 2019-10-17 13:27:35,090 autoreload 217 E:\12446\PycharmProjects\wangli\wanjia\awj\awj\setting\dev.py changed, reloading.
  6. INFO 2019-10-17 13:27:35,938 autoreload 597 Watching for file changes with StatReloader
  7. INFO 2019-10-17 13:28:06,660 autoreload 597 Watching for file changes with StatReloader
  8. INFO 2019-10-17 13:28:39,906 autoreload 597 Watching for file changes with StatReloader
  9. WARNING 2019-10-17 14:12:35,299 log 228 Not Found: /areas/
  10. WARNING 2019-10-17 14:12:35,300 basehttp 154 "GET /areas/ HTTP/1.1" 404 1955
  11. WARNING 2019-10-17 14:12:37,216 log 228 Not Found: /areas/
  12. WARNING 2019-10-17 14:12:37,216 basehttp 154 "GET /areas/ HTTP/1.1" 404 1955
  13. INFO 2019-10-17 14:15:22,231 basehttp 154 "GET /areas/ HTTP/1.1" 200 10
  14. INFO 2019-10-17 14:15:45,505 basehttp 154 "GET /areas/ HTTP/1.1" 200 10
  15. ERROR 2019-10-17 14:21:46,626 log 228 Internal Server Error: /areas/
  16. Traceback (most recent call last):
  17. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  18. response = get_response(request)
  19. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  20. response = self.process_exception_by_middleware(e, request)
  21. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  22. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  23. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  24. return self.dispatch(request, *args, **kwargs)
  25. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  26. return handler(request, *args, **kwargs)
  27. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 11, in get
  28. with connection.cursor() as cursor:
  29. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 255, in cursor
  30. return self._cursor()
  31. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 232, in _cursor
  32. self.ensure_connection()
  33. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 216, in ensure_connection
  34. self.connect()
  35. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 196, in connect
  36. self.init_connection_state()
  37. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 365, in init_connection_state
  38. "The database driver doesn't support modern datatime types.")
  39. django.core.exceptions.ImproperlyConfigured: The database driver doesn't support modern datatime types.
  40. ERROR 2019-10-17 14:21:46,628 basehttp 154 "GET /areas/ HTTP/1.1" 500 99869
  41. ERROR 2019-10-17 14:22:09,101 log 228 Internal Server Error: /areas/
  42. Traceback (most recent call last):
  43. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  44. response = get_response(request)
  45. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  46. response = self.process_exception_by_middleware(e, request)
  47. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  48. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  49. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  50. return self.dispatch(request, *args, **kwargs)
  51. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  52. return handler(request, *args, **kwargs)
  53. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 11, in get
  54. with connection.cursor() as cursor:
  55. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 255, in cursor
  56. return self._cursor()
  57. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 232, in _cursor
  58. self.ensure_connection()
  59. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 216, in ensure_connection
  60. self.connect()
  61. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 196, in connect
  62. self.init_connection_state()
  63. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 365, in init_connection_state
  64. "The database driver doesn't support modern datatime types.")
  65. django.core.exceptions.ImproperlyConfigured: The database driver doesn't support modern datatime types.
  66. ERROR 2019-10-17 14:22:09,103 basehttp 154 "GET /areas/ HTTP/1.1" 500 99864
  67. ERROR 2019-10-17 14:23:11,195 log 228 Internal Server Error: /areas/
  68. Traceback (most recent call last):
  69. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  70. response = get_response(request)
  71. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  72. response = self.process_exception_by_middleware(e, request)
  73. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  74. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  75. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  76. return self.dispatch(request, *args, **kwargs)
  77. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  78. return handler(request, *args, **kwargs)
  79. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 11, in get
  80. with connection.cursor() as cursor:
  81. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 255, in cursor
  82. return self._cursor()
  83. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 232, in _cursor
  84. self.ensure_connection()
  85. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 216, in ensure_connection
  86. self.connect()
  87. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 196, in connect
  88. self.init_connection_state()
  89. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 365, in init_connection_state
  90. "The database driver doesn't support modern datatime types.")
  91. django.core.exceptions.ImproperlyConfigured: The database driver doesn't support modern datatime types.
  92. ERROR 2019-10-17 14:23:11,197 basehttp 154 "GET /areas/ HTTP/1.1" 500 99866
  93. ERROR 2019-10-17 14:23:55,955 log 228 Internal Server Error: /areas/
  94. Traceback (most recent call last):
  95. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  96. response = get_response(request)
  97. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  98. response = self.process_exception_by_middleware(e, request)
  99. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  100. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  101. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  102. return self.dispatch(request, *args, **kwargs)
  103. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  104. return handler(request, *args, **kwargs)
  105. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 11, in get
  106. with connection.cursor() as cursor:
  107. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 255, in cursor
  108. return self._cursor()
  109. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 232, in _cursor
  110. self.ensure_connection()
  111. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 216, in ensure_connection
  112. self.connect()
  113. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 196, in connect
  114. self.init_connection_state()
  115. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 365, in init_connection_state
  116. "The database driver doesn't support modern datatime types.")
  117. django.core.exceptions.ImproperlyConfigured: The database driver doesn't support modern datatime types.
  118. ERROR 2019-10-17 14:23:55,957 basehttp 154 "GET /areas/ HTTP/1.1" 500 99876
  119. ERROR 2019-10-17 14:24:23,614 log 228 Internal Server Error: /areas/
  120. Traceback (most recent call last):
  121. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  122. response = get_response(request)
  123. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  124. response = self.process_exception_by_middleware(e, request)
  125. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  126. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  127. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  128. return self.dispatch(request, *args, **kwargs)
  129. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  130. return handler(request, *args, **kwargs)
  131. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 11, in get
  132. with connection.cursor() as cursor:
  133. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 255, in cursor
  134. return self._cursor()
  135. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 232, in _cursor
  136. self.ensure_connection()
  137. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 216, in ensure_connection
  138. self.connect()
  139. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 196, in connect
  140. self.init_connection_state()
  141. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 365, in init_connection_state
  142. "The database driver doesn't support modern datatime types.")
  143. django.core.exceptions.ImproperlyConfigured: The database driver doesn't support modern datatime types.
  144. ERROR 2019-10-17 14:24:23,615 basehttp 154 "GET /areas/ HTTP/1.1" 500 99876
  145. ERROR 2019-10-17 14:26:39,285 log 228 Internal Server Error: /areas/
  146. Traceback (most recent call last):
  147. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  148. response = get_response(request)
  149. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  150. response = self.process_exception_by_middleware(e, request)
  151. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  152. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  153. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  154. return self.dispatch(request, *args, **kwargs)
  155. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  156. return handler(request, *args, **kwargs)
  157. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 14, in get
  158. with connection.cursor() as cursor:
  159. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 255, in cursor
  160. return self._cursor()
  161. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 232, in _cursor
  162. self.ensure_connection()
  163. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 216, in ensure_connection
  164. self.connect()
  165. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 196, in connect
  166. self.init_connection_state()
  167. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 365, in init_connection_state
  168. "The database driver doesn't support modern datatime types.")
  169. django.core.exceptions.ImproperlyConfigured: The database driver doesn't support modern datatime types.
  170. ERROR 2019-10-17 14:26:39,287 basehttp 154 "GET /areas/ HTTP/1.1" 500 100119
  171. ERROR 2019-10-17 14:29:28,143 log 228 Internal Server Error: /areas/
  172. Traceback (most recent call last):
  173. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  174. response = get_response(request)
  175. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  176. response = self.process_exception_by_middleware(e, request)
  177. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  178. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  179. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  180. return self.dispatch(request, *args, **kwargs)
  181. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  182. return handler(request, *args, **kwargs)
  183. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 11, in get
  184. with connection.cursor() as cursor:
  185. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 255, in cursor
  186. return self._cursor()
  187. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 232, in _cursor
  188. self.ensure_connection()
  189. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 216, in ensure_connection
  190. self.connect()
  191. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 196, in connect
  192. self.init_connection_state()
  193. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 365, in init_connection_state
  194. "The database driver doesn't support modern datatime types.")
  195. django.core.exceptions.ImproperlyConfigured: The database driver doesn't support modern datatime types.
  196. ERROR 2019-10-17 14:29:28,145 basehttp 154 "GET /areas/ HTTP/1.1" 500 99876
  197. ERROR 2019-10-17 14:36:51,606 log 228 Internal Server Error: /areas/
  198. Traceback (most recent call last):
  199. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  200. response = get_response(request)
  201. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  202. response = self.process_exception_by_middleware(e, request)
  203. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  204. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  205. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  206. return self.dispatch(request, *args, **kwargs)
  207. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  208. return handler(request, *args, **kwargs)
  209. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 11, in get
  210. with connection.cursor() as cursor:
  211. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 255, in cursor
  212. return self._cursor()
  213. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 232, in _cursor
  214. self.ensure_connection()
  215. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 216, in ensure_connection
  216. self.connect()
  217. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 196, in connect
  218. self.init_connection_state()
  219. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 365, in init_connection_state
  220. "The database driver doesn't support modern datatime types.")
  221. django.core.exceptions.ImproperlyConfigured: The database driver doesn't support modern datatime types.
  222. ERROR 2019-10-17 14:36:51,608 basehttp 154 "GET /areas/ HTTP/1.1" 500 99792
  223. ERROR 2019-10-17 14:38:25,722 log 228 Internal Server Error: /areas/
  224. Traceback (most recent call last):
  225. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  226. response = get_response(request)
  227. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  228. response = self.process_exception_by_middleware(e, request)
  229. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  230. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  231. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  232. return self.dispatch(request, *args, **kwargs)
  233. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  234. return handler(request, *args, **kwargs)
  235. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 12, in get
  236. cursor = connection.cursor()
  237. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 255, in cursor
  238. return self._cursor()
  239. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 232, in _cursor
  240. self.ensure_connection()
  241. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 216, in ensure_connection
  242. self.connect()
  243. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 196, in connect
  244. self.init_connection_state()
  245. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 365, in init_connection_state
  246. "The database driver doesn't support modern datatime types.")
  247. django.core.exceptions.ImproperlyConfigured: The database driver doesn't support modern datatime types.
  248. ERROR 2019-10-17 14:38:25,723 basehttp 154 "GET /areas/ HTTP/1.1" 500 99949
  249. ERROR 2019-10-17 14:44:01,821 log 228 Internal Server Error: /areas/
  250. Traceback (most recent call last):
  251. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  252. response = get_response(request)
  253. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  254. response = self.process_exception_by_middleware(e, request)
  255. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  256. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  257. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  258. return self.dispatch(request, *args, **kwargs)
  259. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  260. return handler(request, *args, **kwargs)
  261. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 12, in get
  262. cursor = connection.cursor()
  263. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 255, in cursor
  264. return self._cursor()
  265. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 232, in _cursor
  266. self.ensure_connection()
  267. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 216, in ensure_connection
  268. self.connect()
  269. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 196, in connect
  270. self.init_connection_state()
  271. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 365, in init_connection_state
  272. "The database driver doesn't support modern datatime types.")
  273. django.core.exceptions.ImproperlyConfigured: The database driver doesn't support modern datatime types.
  274. ERROR 2019-10-17 14:44:01,823 basehttp 154 "GET /areas/ HTTP/1.1" 500 99949
  275. ERROR 2019-10-17 14:46:00,691 log 228 Internal Server Error: /areas/
  276. Traceback (most recent call last):
  277. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  278. response = get_response(request)
  279. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  280. response = self.process_exception_by_middleware(e, request)
  281. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  282. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  283. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  284. return self.dispatch(request, *args, **kwargs)
  285. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  286. return handler(request, *args, **kwargs)
  287. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 11, in get
  288. with connection.cursor() as cursor:
  289. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 255, in cursor
  290. return self._cursor()
  291. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 232, in _cursor
  292. self.ensure_connection()
  293. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 216, in ensure_connection
  294. self.connect()
  295. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\base\base.py", line 196, in connect
  296. self.init_connection_state()
  297. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 365, in init_connection_state
  298. "The database driver doesn't support modern datatime types.")
  299. django.core.exceptions.ImproperlyConfigured: The database driver doesn't support modern datatime types.
  300. ERROR 2019-10-17 14:46:00,693 basehttp 154 "GET /areas/ HTTP/1.1" 500 100396
  301. WARNING 2019-10-17 14:46:00,830 log 228 Not Found: /favicon.ico
  302. WARNING 2019-10-17 14:46:00,832 basehttp 154 "GET /favicon.ico HTTP/1.1" 404 2126
  303. INFO 2019-10-17 14:48:52,834 basehttp 154 "GET /areas/ HTTP/1.1" 200 10
  304. INFO 2019-10-17 14:52:36,899 basehttp 154 "GET /areas/ HTTP/1.1" 200 10
  305. INFO 2019-10-17 16:21:08,859 basehttp 154 "GET /areas/ HTTP/1.1" 200 10
  306. WARNING 2019-10-17 17:33:38,727 log 228 Forbidden (CSRF cookie not set.): /areas/
  307. WARNING 2019-10-17 17:33:38,727 basehttp 154 "POST /areas/ HTTP/1.1" 403 2868
  308. INFO 2019-10-17 17:33:42,872 basehttp 154 "GET /areas/ HTTP/1.1" 200 10
  309. INFO 2019-10-17 17:34:25,001 basehttp 154 "GET /invoice/ HTTP/1.1" 200 10
  310. WARNING 2019-10-17 17:40:06,205 log 228 Forbidden (CSRF cookie not set.): /invoice/
  311. WARNING 2019-10-17 17:40:06,206 basehttp 154 "POST /invoice/ HTTP/1.1" 403 2868
  312. ERROR 2019-10-17 17:40:59,373 log 228 Internal Server Error: /invoice/
  313. Traceback (most recent call last):
  314. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  315. response = get_response(request)
  316. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 137, in _get_response
  317. "returned None instead." % (callback.__module__, view_name)
  318. ValueError: The view stockinvoice.views.InvoiceView didn't return an HttpResponse object. It returned None instead.
  319. ERROR 2019-10-17 17:40:59,374 basehttp 154 "POST /invoice/ HTTP/1.1" 500 61366
  320. INFO 2019-10-17 17:42:00,134 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  321. ERROR 2019-10-17 17:44:11,957 log 228 Internal Server Error: /invoice/
  322. Traceback (most recent call last):
  323. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 96, in inner
  324. return func(*args, **kwargs)
  325. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 581, in fetchone
  326. row = self.cursor.fetchone()
  327. pyodbc.ProgrammingError: No results. Previous SQL was not a query.
  328. The above exception was the direct cause of the following exception:
  329. Traceback (most recent call last):
  330. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  331. response = get_response(request)
  332. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  333. response = self.process_exception_by_middleware(e, request)
  334. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  335. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  336. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  337. return self.dispatch(request, *args, **kwargs)
  338. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  339. return handler(request, *args, **kwargs)
  340. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 14, in get
  341. row = cursor.fetchone()
  342. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 96, in inner
  343. return func(*args, **kwargs)
  344. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 89, in __exit__
  345. raise dj_exc_value.with_traceback(traceback) from exc_value
  346. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 96, in inner
  347. return func(*args, **kwargs)
  348. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 581, in fetchone
  349. row = self.cursor.fetchone()
  350. django.db.utils.ProgrammingError: No results. Previous SQL was not a query.
  351. ERROR 2019-10-17 17:44:11,959 basehttp 154 "GET /invoice/ HTTP/1.1" 500 102978
  352. ERROR 2019-10-17 17:45:20,027 log 228 Internal Server Error: /invoice/
  353. Traceback (most recent call last):
  354. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 96, in inner
  355. return func(*args, **kwargs)
  356. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 581, in fetchone
  357. row = self.cursor.fetchone()
  358. pyodbc.ProgrammingError: No results. Previous SQL was not a query.
  359. The above exception was the direct cause of the following exception:
  360. Traceback (most recent call last):
  361. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  362. response = get_response(request)
  363. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  364. response = self.process_exception_by_middleware(e, request)
  365. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  366. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  367. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  368. return self.dispatch(request, *args, **kwargs)
  369. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  370. return handler(request, *args, **kwargs)
  371. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 14, in get
  372. row = cursor.fetchone()
  373. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 96, in inner
  374. return func(*args, **kwargs)
  375. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 89, in __exit__
  376. raise dj_exc_value.with_traceback(traceback) from exc_value
  377. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 96, in inner
  378. return func(*args, **kwargs)
  379. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 581, in fetchone
  380. row = self.cursor.fetchone()
  381. django.db.utils.ProgrammingError: No results. Previous SQL was not a query.
  382. ERROR 2019-10-17 17:45:20,028 basehttp 154 "GET /invoice/ HTTP/1.1" 500 103115
  383. INFO 2019-10-17 17:45:40,818 basehttp 154 "GET /invoice/ HTTP/1.1" 200 10
  384. ERROR 2019-10-17 17:47:14,790 log 228 Internal Server Error: /invoice/
  385. Traceback (most recent call last):
  386. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 96, in inner
  387. return func(*args, **kwargs)
  388. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 581, in fetchone
  389. row = self.cursor.fetchone()
  390. pyodbc.ProgrammingError: No results. Previous SQL was not a query.
  391. The above exception was the direct cause of the following exception:
  392. Traceback (most recent call last):
  393. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  394. response = get_response(request)
  395. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  396. response = self.process_exception_by_middleware(e, request)
  397. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  398. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  399. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  400. return self.dispatch(request, *args, **kwargs)
  401. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  402. return handler(request, *args, **kwargs)
  403. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 14, in get
  404. row = cursor.fetchone()
  405. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 96, in inner
  406. return func(*args, **kwargs)
  407. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 89, in __exit__
  408. raise dj_exc_value.with_traceback(traceback) from exc_value
  409. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 96, in inner
  410. return func(*args, **kwargs)
  411. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 581, in fetchone
  412. row = self.cursor.fetchone()
  413. django.db.utils.ProgrammingError: No results. Previous SQL was not a query.
  414. ERROR 2019-10-17 17:47:14,792 basehttp 154 "GET /invoice/ HTTP/1.1" 500 103115
  415. ERROR 2019-10-17 17:47:52,312 log 228 Internal Server Error: /invoice/
  416. Traceback (most recent call last):
  417. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 96, in inner
  418. return func(*args, **kwargs)
  419. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 581, in fetchone
  420. row = self.cursor.fetchone()
  421. pyodbc.ProgrammingError: No results. Previous SQL was not a query.
  422. The above exception was the direct cause of the following exception:
  423. Traceback (most recent call last):
  424. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  425. response = get_response(request)
  426. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  427. response = self.process_exception_by_middleware(e, request)
  428. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  429. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  430. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  431. return self.dispatch(request, *args, **kwargs)
  432. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  433. return handler(request, *args, **kwargs)
  434. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 14, in get
  435. row = cursor.fetchone()
  436. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 96, in inner
  437. return func(*args, **kwargs)
  438. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 89, in __exit__
  439. raise dj_exc_value.with_traceback(traceback) from exc_value
  440. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 96, in inner
  441. return func(*args, **kwargs)
  442. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 581, in fetchone
  443. row = self.cursor.fetchone()
  444. django.db.utils.ProgrammingError: No results. Previous SQL was not a query.
  445. ERROR 2019-10-17 17:47:52,314 basehttp 154 "GET /invoice/ HTTP/1.1" 500 103117
  446. ERROR 2019-10-17 17:52:52,408 log 228 Internal Server Error: /invoice/
  447. Traceback (most recent call last):
  448. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 96, in inner
  449. return func(*args, **kwargs)
  450. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 594, in fetchall
  451. return self.format_rows(self.cursor.fetchall())
  452. pyodbc.ProgrammingError: No results. Previous SQL was not a query.
  453. The above exception was the direct cause of the following exception:
  454. Traceback (most recent call last):
  455. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  456. response = get_response(request)
  457. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  458. response = self.process_exception_by_middleware(e, request)
  459. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  460. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  461. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  462. return self.dispatch(request, *args, **kwargs)
  463. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  464. return handler(request, *args, **kwargs)
  465. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 14, in get
  466. row = cursor.fetchall()
  467. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 96, in inner
  468. return func(*args, **kwargs)
  469. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 89, in __exit__
  470. raise dj_exc_value.with_traceback(traceback) from exc_value
  471. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 96, in inner
  472. return func(*args, **kwargs)
  473. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 594, in fetchall
  474. return self.format_rows(self.cursor.fetchall())
  475. django.db.utils.ProgrammingError: No results. Previous SQL was not a query.
  476. ERROR 2019-10-17 17:52:52,409 basehttp 154 "GET /invoice/ HTTP/1.1" 500 102677
  477. INFO 2019-10-17 17:59:44,327 basehttp 154 "GET /invoice/ HTTP/1.1" 200 10
  478. INFO 2019-10-17 18:00:03,991 basehttp 154 "GET /invoice/ HTTP/1.1" 200 10
  479. INFO 2019-10-17 18:01:04,025 basehttp 154 "GET /invoice/ HTTP/1.1" 200 10
  480. INFO 2019-10-17 18:01:52,909 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  481. ERROR 2019-10-17 18:03:36,505 log 228 Internal Server Error: /invoice/
  482. Traceback (most recent call last):
  483. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 83, in _execute
  484. return self.cursor.execute(sql)
  485. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  486. return self.cursor.execute(sql, params)
  487. pyodbc.ProgrammingError: ('42S22', "[42S22] [Microsoft][SQL Server Native Client 10.0][SQL Server]列名 'CUS_NO' 无效。 (207) (SQLExecDirectW)")
  488. The above exception was the direct cause of the following exception:
  489. Traceback (most recent call last):
  490. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  491. response = get_response(request)
  492. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  493. response = self.process_exception_by_middleware(e, request)
  494. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  495. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  496. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  497. return self.dispatch(request, *args, **kwargs)
  498. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  499. return handler(request, *args, **kwargs)
  500. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 12, in get
  501. cursor.execute("INSERT INTO PRDT(CUS_NO,NAME)VALUES ('QQ12345','DSDADADA')")
  502. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  503. return super().execute(sql, params)
  504. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  505. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  506. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  507. return executor(sql, params, many, context)
  508. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  509. return self.cursor.execute(sql, params)
  510. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 89, in __exit__
  511. raise dj_exc_value.with_traceback(traceback) from exc_value
  512. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 83, in _execute
  513. return self.cursor.execute(sql)
  514. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  515. return self.cursor.execute(sql, params)
  516. django.db.utils.ProgrammingError: ('42S22', "[42S22] [Microsoft][SQL Server Native Client 10.0][SQL Server]列名 'CUS_NO' 无效。 (207) (SQLExecDirectW)")
  517. ERROR 2019-10-17 18:03:36,507 basehttp 154 "GET /invoice/ HTTP/1.1" 500 119454
  518. ERROR 2019-10-17 18:04:03,824 log 228 Internal Server Error: /invoice/
  519. Traceback (most recent call last):
  520. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 83, in _execute
  521. return self.cursor.execute(sql)
  522. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  523. return self.cursor.execute(sql, params)
  524. pyodbc.ProgrammingError: ('42000', "[42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]'`' 附近有语法错误。 (102) (SQLExecDirectW)")
  525. The above exception was the direct cause of the following exception:
  526. Traceback (most recent call last):
  527. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  528. response = get_response(request)
  529. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  530. response = self.process_exception_by_middleware(e, request)
  531. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  532. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  533. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  534. return self.dispatch(request, *args, **kwargs)
  535. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  536. return handler(request, *args, **kwargs)
  537. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 12, in get
  538. cursor.execute("INSERT INTO PRDT(CUS_NO,`NAME`)VALUES ('QQ12345','DSDADADA')")
  539. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  540. return super().execute(sql, params)
  541. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  542. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  543. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  544. return executor(sql, params, many, context)
  545. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  546. return self.cursor.execute(sql, params)
  547. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 89, in __exit__
  548. raise dj_exc_value.with_traceback(traceback) from exc_value
  549. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 83, in _execute
  550. return self.cursor.execute(sql)
  551. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  552. return self.cursor.execute(sql, params)
  553. django.db.utils.ProgrammingError: ('42000', "[42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]'`' 附近有语法错误。 (102) (SQLExecDirectW)")
  554. ERROR 2019-10-17 18:04:03,825 basehttp 154 "GET /invoice/ HTTP/1.1" 500 119498
  555. ERROR 2019-10-17 18:05:23,538 log 228 Internal Server Error: /invoice/
  556. Traceback (most recent call last):
  557. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 83, in _execute
  558. return self.cursor.execute(sql)
  559. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  560. return self.cursor.execute(sql, params)
  561. pyodbc.ProgrammingError: ('42S22', "[42S22] [Microsoft][SQL Server Native Client 10.0][SQL Server]列名 'CUS_NO' 无效。 (207) (SQLExecDirectW)")
  562. The above exception was the direct cause of the following exception:
  563. Traceback (most recent call last):
  564. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  565. response = get_response(request)
  566. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  567. response = self.process_exception_by_middleware(e, request)
  568. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  569. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  570. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  571. return self.dispatch(request, *args, **kwargs)
  572. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  573. return handler(request, *args, **kwargs)
  574. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 12, in get
  575. cursor.execute("INSERT INTO PRDT(CUS_NO,[NAME])VALUES ('QQ12345','DSDADADA')")
  576. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  577. return super().execute(sql, params)
  578. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  579. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  580. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  581. return executor(sql, params, many, context)
  582. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  583. return self.cursor.execute(sql, params)
  584. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 89, in __exit__
  585. raise dj_exc_value.with_traceback(traceback) from exc_value
  586. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 83, in _execute
  587. return self.cursor.execute(sql)
  588. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  589. return self.cursor.execute(sql, params)
  590. django.db.utils.ProgrammingError: ('42S22', "[42S22] [Microsoft][SQL Server Native Client 10.0][SQL Server]列名 'CUS_NO' 无效。 (207) (SQLExecDirectW)")
  591. ERROR 2019-10-17 18:05:23,540 basehttp 154 "GET /invoice/ HTTP/1.1" 500 119474
  592. ERROR 2019-10-17 18:06:14,326 log 228 Internal Server Error: /invoice/
  593. Traceback (most recent call last):
  594. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  595. return self.cursor.execute(sql, params)
  596. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  597. return self.cursor.execute(sql, params)
  598. pyodbc.ProgrammingError: ('42S22', "[42S22] [Microsoft][SQL Server Native Client 10.0][SQL Server]列名 'CUS_NO' 无效。 (207) (SQLExecDirectW); [42S22] [Microsoft][SQL Server Native Client 10.0][SQL Server]无法预定义语句。 (8180)")
  599. The above exception was the direct cause of the following exception:
  600. Traceback (most recent call last):
  601. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  602. response = get_response(request)
  603. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  604. response = self.process_exception_by_middleware(e, request)
  605. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  606. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  607. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  608. return self.dispatch(request, *args, **kwargs)
  609. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  610. return handler(request, *args, **kwargs)
  611. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 12, in get
  612. cursor.execute("INSERT INTO PRDT(CUS_NO,[NAME])VALUES ('QQ12345',%s)",[a])
  613. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  614. return super().execute(sql, params)
  615. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  616. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  617. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  618. return executor(sql, params, many, context)
  619. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  620. return self.cursor.execute(sql, params)
  621. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 89, in __exit__
  622. raise dj_exc_value.with_traceback(traceback) from exc_value
  623. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  624. return self.cursor.execute(sql, params)
  625. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  626. return self.cursor.execute(sql, params)
  627. django.db.utils.ProgrammingError: ('42S22', "[42S22] [Microsoft][SQL Server Native Client 10.0][SQL Server]列名 'CUS_NO' 无效。 (207) (SQLExecDirectW); [42S22] [Microsoft][SQL Server Native Client 10.0][SQL Server]无法预定义语句。 (8180)")
  628. ERROR 2019-10-17 18:06:14,328 basehttp 154 "GET /invoice/ HTTP/1.1" 500 120137
  629. INFO 2019-10-17 18:06:36,521 basehttp 154 "GET /invoice/ HTTP/1.1" 200 10
  630. INFO 2019-10-17 21:27:12,877 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  631. INFO 2019-10-17 22:08:39,806 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  632. INFO 2019-10-17 22:11:55,840 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  633. INFO 2019-10-17 22:12:22,921 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  634. INFO 2019-10-17 22:12:43,199 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  635. INFO 2019-10-17 22:13:51,143 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  636. ERROR 2019-10-17 22:15:09,179 log 228 Internal Server Error: /invoice/
  637. Traceback (most recent call last):
  638. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  639. return self.cursor.execute(sql, params)
  640. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  641. return self.cursor.execute(sql, params)
  642. pyodbc.ProgrammingError: ('42S02', "[42S02] [Microsoft][SQL Server Native Client 10.0][SQL Server]对象名 'SLAM' 无效。 (208) (SQLExecDirectW); [42S02] [Microsoft][SQL Server Native Client 10.0][SQL Server]无法预定义语句。 (8180)")
  643. The above exception was the direct cause of the following exception:
  644. Traceback (most recent call last):
  645. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  646. response = get_response(request)
  647. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  648. response = self.process_exception_by_middleware(e, request)
  649. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  650. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  651. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  652. return self.dispatch(request, *args, **kwargs)
  653. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  654. return handler(request, *args, **kwargs)
  655. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 54, in post
  656. row_usr = cursor.execute("SELECT COUNT(*) FROM SLAM WHERE CUS_NO=%s",[USR]).fetchall()[0][0]
  657. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  658. return super().execute(sql, params)
  659. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  660. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  661. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  662. return executor(sql, params, many, context)
  663. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  664. return self.cursor.execute(sql, params)
  665. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 89, in __exit__
  666. raise dj_exc_value.with_traceback(traceback) from exc_value
  667. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  668. return self.cursor.execute(sql, params)
  669. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  670. return self.cursor.execute(sql, params)
  671. django.db.utils.ProgrammingError: ('42S02', "[42S02] [Microsoft][SQL Server Native Client 10.0][SQL Server]对象名 'SLAM' 无效。 (208) (SQLExecDirectW); [42S02] [Microsoft][SQL Server Native Client 10.0][SQL Server]无法预定义语句。 (8180)")
  672. ERROR 2019-10-17 22:15:09,183 basehttp 154 "POST /invoice/ HTTP/1.1" 500 124347
  673. ERROR 2019-10-17 22:15:33,723 log 228 Internal Server Error: /invoice/
  674. Traceback (most recent call last):
  675. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  676. return self.cursor.execute(sql, params)
  677. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  678. return self.cursor.execute(sql, params)
  679. pyodbc.ProgrammingError: ('42S02', "[42S02] [Microsoft][SQL Server Native Client 10.0][SQL Server]对象名 'SLAM' 无效。 (208) (SQLExecDirectW); [42S02] [Microsoft][SQL Server Native Client 10.0][SQL Server]无法预定义语句。 (8180)")
  680. The above exception was the direct cause of the following exception:
  681. Traceback (most recent call last):
  682. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  683. response = get_response(request)
  684. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  685. response = self.process_exception_by_middleware(e, request)
  686. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  687. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  688. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  689. return self.dispatch(request, *args, **kwargs)
  690. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  691. return handler(request, *args, **kwargs)
  692. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 54, in post
  693. row_usr = cursor.execute("SELECT COUNT(*) FROM SLAM WHERE SAL_NO=%s",[USR]).fetchall()[0][0]
  694. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  695. return super().execute(sql, params)
  696. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  697. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  698. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  699. return executor(sql, params, many, context)
  700. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  701. return self.cursor.execute(sql, params)
  702. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 89, in __exit__
  703. raise dj_exc_value.with_traceback(traceback) from exc_value
  704. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  705. return self.cursor.execute(sql, params)
  706. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  707. return self.cursor.execute(sql, params)
  708. django.db.utils.ProgrammingError: ('42S02', "[42S02] [Microsoft][SQL Server Native Client 10.0][SQL Server]对象名 'SLAM' 无效。 (208) (SQLExecDirectW); [42S02] [Microsoft][SQL Server Native Client 10.0][SQL Server]无法预定义语句。 (8180)")
  709. ERROR 2019-10-17 22:15:33,727 basehttp 154 "POST /invoice/ HTTP/1.1" 500 124350
  710. INFO 2019-10-17 22:16:30,085 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  711. INFO 2019-10-17 22:19:35,485 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  712. INFO 2019-10-17 22:19:41,014 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  713. INFO 2019-10-17 22:22:30,127 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  714. INFO 2019-10-17 22:22:32,199 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  715. INFO 2019-10-17 22:31:58,427 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  716. INFO 2019-10-17 22:32:25,280 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  717. INFO 2019-10-17 22:32:37,349 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  718. INFO 2019-10-17 22:32:56,619 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  719. INFO 2019-10-17 22:34:21,074 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  720. INFO 2019-10-17 22:56:34,519 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  721. INFO 2019-10-17 22:57:58,780 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  722. INFO 2019-10-17 22:58:01,718 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  723. INFO 2019-10-17 22:58:30,375 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  724. INFO 2019-10-17 22:58:46,584 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  725. INFO 2019-10-17 22:59:12,091 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  726. WARNING 2019-10-17 23:07:47,139 log 228 Forbidden: /invoice/
  727. WARNING 2019-10-17 23:07:47,140 basehttp 154 "POST /invoice/ HTTP/1.1" 403 12
  728. ERROR 2019-10-17 23:14:23,137 log 228 Internal Server Error: /invoice/
  729. Traceback (most recent call last):
  730. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  731. return self.cursor.execute(sql, params)
  732. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  733. return self.cursor.execute(sql, params)
  734. pyodbc.IntegrityError: ('23000', "[23000] [Microsoft][SQL Server Native Client 10.0][SQL Server]违反了 PRIMARY KEY 约束 'PK__MF_PSS'。不能在对象 'dbo.MF_PSS' 中插入重复键。 (2627) (SQLExecDirectW); [23000] [Microsoft][SQL Server Native Client 10.0][SQL Server]语句已终止。 (3621)")
  735. The above exception was the direct cause of the following exception:
  736. Traceback (most recent call last):
  737. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  738. response = get_response(request)
  739. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  740. response = self.process_exception_by_middleware(e, request)
  741. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  742. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  743. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  744. return self.dispatch(request, *args, **kwargs)
  745. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  746. return handler(request, *args, **kwargs)
  747. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 75, in post
  748. datetime.datetime.strptime(LZ_DD, '%Y-%m-%d'),AMT])
  749. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  750. return super().execute(sql, params)
  751. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  752. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  753. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  754. return executor(sql, params, many, context)
  755. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  756. return self.cursor.execute(sql, params)
  757. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 89, in __exit__
  758. raise dj_exc_value.with_traceback(traceback) from exc_value
  759. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  760. return self.cursor.execute(sql, params)
  761. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  762. return self.cursor.execute(sql, params)
  763. django.db.utils.IntegrityError: ('23000', "[23000] [Microsoft][SQL Server Native Client 10.0][SQL Server]违反了 PRIMARY KEY 约束 'PK__MF_PSS'。不能在对象 'dbo.MF_PSS' 中插入重复键。 (2627) (SQLExecDirectW); [23000] [Microsoft][SQL Server Native Client 10.0][SQL Server]语句已终止。 (3621)")
  764. ERROR 2019-10-17 23:14:23,139 basehttp 154 "POST /invoice/ HTTP/1.1" 500 129497
  765. ERROR 2019-10-17 23:15:02,233 log 228 Internal Server Error: /invoice/
  766. Traceback (most recent call last):
  767. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  768. response = get_response(request)
  769. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  770. response = self.process_exception_by_middleware(e, request)
  771. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  772. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  773. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  774. return self.dispatch(request, *args, **kwargs)
  775. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  776. return handler(request, *args, **kwargs)
  777. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 78, in post
  778. VALUES('PC',%s,%s,'0000','AQ001',,1,1,%f,%f,5,1,1,%f)""", ['PC'+ZL_NO[2::], datetime.datetime.strptime(LZ_DD, '%Y-%m-%d'),AMT,AMT,AMT])
  779. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  780. return super().execute(sql, params)
  781. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  782. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  783. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  784. return executor(sql, params, many, context)
  785. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  786. return self.cursor.execute(sql, params)
  787. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 542, in execute
  788. sql = self.format_sql(sql, params)
  789. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 510, in format_sql
  790. sql = sql % tuple('?' * len(params))
  791. TypeError: must be real number, not str
  792. ERROR 2019-10-17 23:15:02,235 basehttp 154 "POST /invoice/ HTTP/1.1" 500 111057
  793. ERROR 2019-10-17 23:17:43,751 log 228 Internal Server Error: /invoice/
  794. Traceback (most recent call last):
  795. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  796. response = get_response(request)
  797. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  798. response = self.process_exception_by_middleware(e, request)
  799. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  800. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  801. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  802. return self.dispatch(request, *args, **kwargs)
  803. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  804. return handler(request, *args, **kwargs)
  805. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 78, in post
  806. VALUES('PC',%s,%s,'0000','AQ001',1,1,%f,%f,5,1,1,%f)""", ['PC'+ZL_NO[2::], datetime.datetime.strptime(LZ_DD, '%Y-%m-%d'),AMT,AMT,AMT])
  807. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  808. return super().execute(sql, params)
  809. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  810. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  811. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  812. return executor(sql, params, many, context)
  813. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  814. return self.cursor.execute(sql, params)
  815. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 542, in execute
  816. sql = self.format_sql(sql, params)
  817. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 510, in format_sql
  818. sql = sql % tuple('?' * len(params))
  819. TypeError: must be real number, not str
  820. ERROR 2019-10-17 23:17:43,754 basehttp 154 "POST /invoice/ HTTP/1.1" 500 111047
  821. ERROR 2019-10-17 23:24:18,477 log 228 Internal Server Error: /invoice/
  822. Traceback (most recent call last):
  823. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  824. return self.cursor.execute(sql, params)
  825. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  826. return self.cursor.execute(sql, params)
  827. pyodbc.IntegrityError: ('23000', "[23000] [Microsoft][SQL Server Native Client 10.0][SQL Server]违反了 PRIMARY KEY 约束 'PK__MF_PSS'。不能在对象 'dbo.MF_PSS' 中插入重复键。 (2627) (SQLExecDirectW); [23000] [Microsoft][SQL Server Native Client 10.0][SQL Server]语句已终止。 (3621)")
  828. The above exception was the direct cause of the following exception:
  829. Traceback (most recent call last):
  830. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  831. response = get_response(request)
  832. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  833. response = self.process_exception_by_middleware(e, request)
  834. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  835. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  836. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  837. return self.dispatch(request, *args, **kwargs)
  838. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  839. return handler(request, *args, **kwargs)
  840. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 75, in post
  841. datetime.datetime.strptime(LZ_DD, '%Y-%m-%d'),AMT])
  842. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  843. return super().execute(sql, params)
  844. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  845. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  846. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  847. return executor(sql, params, many, context)
  848. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  849. return self.cursor.execute(sql, params)
  850. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 89, in __exit__
  851. raise dj_exc_value.with_traceback(traceback) from exc_value
  852. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  853. return self.cursor.execute(sql, params)
  854. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  855. return self.cursor.execute(sql, params)
  856. django.db.utils.IntegrityError: ('23000', "[23000] [Microsoft][SQL Server Native Client 10.0][SQL Server]违反了 PRIMARY KEY 约束 'PK__MF_PSS'。不能在对象 'dbo.MF_PSS' 中插入重复键。 (2627) (SQLExecDirectW); [23000] [Microsoft][SQL Server Native Client 10.0][SQL Server]语句已终止。 (3621)")
  857. ERROR 2019-10-17 23:24:18,480 basehttp 154 "POST /invoice/ HTTP/1.1" 500 129530
  858. INFO 2019-10-17 23:24:39,910 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  859. ERROR 2019-10-18 14:08:39,860 log 228 Internal Server Error: /invoice/
  860. Traceback (most recent call last):
  861. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  862. return self.cursor.execute(sql, params)
  863. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  864. return self.cursor.execute(sql, params)
  865. pyodbc.IntegrityError: ('23000', "[23000] [Microsoft][SQL Server Native Client 10.0][SQL Server]违反了 PRIMARY KEY 约束 'PK__MF_PSS'。不能在对象 'dbo.MF_PSS' 中插入重复键。 (2627) (SQLExecDirectW); [23000] [Microsoft][SQL Server Native Client 10.0][SQL Server]语句已终止。 (3621)")
  866. The above exception was the direct cause of the following exception:
  867. Traceback (most recent call last):
  868. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  869. response = get_response(request)
  870. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  871. response = self.process_exception_by_middleware(e, request)
  872. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  873. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  874. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  875. return self.dispatch(request, *args, **kwargs)
  876. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  877. return handler(request, *args, **kwargs)
  878. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 75, in post
  879. datetime.datetime.strptime(LZ_DD, '%Y-%m-%d'),AMT])
  880. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  881. return super().execute(sql, params)
  882. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  883. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  884. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  885. return executor(sql, params, many, context)
  886. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  887. return self.cursor.execute(sql, params)
  888. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 89, in __exit__
  889. raise dj_exc_value.with_traceback(traceback) from exc_value
  890. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  891. return self.cursor.execute(sql, params)
  892. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  893. return self.cursor.execute(sql, params)
  894. django.db.utils.IntegrityError: ('23000', "[23000] [Microsoft][SQL Server Native Client 10.0][SQL Server]违反了 PRIMARY KEY 约束 'PK__MF_PSS'。不能在对象 'dbo.MF_PSS' 中插入重复键。 (2627) (SQLExecDirectW); [23000] [Microsoft][SQL Server Native Client 10.0][SQL Server]语句已终止。 (3621)")
  895. ERROR 2019-10-18 14:08:39,897 basehttp 154 "POST /invoice/ HTTP/1.1" 500 129655
  896. INFO 2019-10-18 14:10:22,226 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  897. INFO 2019-10-18 14:12:42,840 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  898. ERROR 2019-10-18 14:24:23,829 log 228 Internal Server Error: /invoice/
  899. Traceback (most recent call last):
  900. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  901. response = get_response(request)
  902. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  903. response = self.process_exception_by_middleware(e, request)
  904. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  905. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  906. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  907. return self.dispatch(request, *args, **kwargs)
  908. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  909. return handler(request, *args, **kwargs)
  910. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 87, in post
  911. datetime.datetime.strptime(LZ_DD,'%Y-%m-%d'),INV_NO,AMT,AMT,AMT,datetime.datetime.strptime(LZ_DD,'%Y-%m-%d')])
  912. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  913. return super().execute(sql, params)
  914. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  915. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  916. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  917. return executor(sql, params, many, context)
  918. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  919. return self.cursor.execute(sql, params)
  920. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 542, in execute
  921. sql = self.format_sql(sql, params)
  922. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 510, in format_sql
  923. sql = sql % tuple('?' * len(params))
  924. TypeError: not all arguments converted during string formatting
  925. ERROR 2019-10-18 14:24:23,831 basehttp 154 "POST /invoice/ HTTP/1.1" 500 112068
  926. ERROR 2019-10-18 14:26:22,690 log 228 Internal Server Error: /invoice/
  927. Traceback (most recent call last):
  928. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  929. response = get_response(request)
  930. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  931. response = self.process_exception_by_middleware(e, request)
  932. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  933. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  934. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  935. return self.dispatch(request, *args, **kwargs)
  936. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  937. return handler(request, *args, **kwargs)
  938. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 87, in post
  939. datetime.datetime.strptime(LZ_DD,'%Y-%m-%d'),INV_NO,datetime.datetime.strptime(LZ_DD,'%Y-%m-%d')])
  940. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  941. return super().execute(sql, params)
  942. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  943. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  944. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  945. return executor(sql, params, many, context)
  946. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  947. return self.cursor.execute(sql, params)
  948. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 542, in execute
  949. sql = self.format_sql(sql, params)
  950. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 510, in format_sql
  951. sql = sql % tuple('?' * len(params))
  952. TypeError: not all arguments converted during string formatting
  953. ERROR 2019-10-18 14:26:22,695 basehttp 154 "POST /invoice/ HTTP/1.1" 500 111683
  954. ERROR 2019-10-18 14:27:31,739 log 228 Internal Server Error: /invoice/
  955. Traceback (most recent call last):
  956. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  957. response = get_response(request)
  958. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  959. response = self.process_exception_by_middleware(e, request)
  960. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  961. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  962. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  963. return self.dispatch(request, *args, **kwargs)
  964. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  965. return handler(request, *args, **kwargs)
  966. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 87, in post
  967. datetime.datetime.strptime(LZ_DD,'%Y-%m-%d'),INV_NO,datetime.datetime.strptime(LZ_DD,'%Y-%m-%d')])
  968. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  969. return super().execute(sql, params)
  970. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  971. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  972. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  973. return executor(sql, params, many, context)
  974. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  975. return self.cursor.execute(sql, params)
  976. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 542, in execute
  977. sql = self.format_sql(sql, params)
  978. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 510, in format_sql
  979. sql = sql % tuple('?' * len(params))
  980. TypeError: not all arguments converted during string formatting
  981. ERROR 2019-10-18 14:27:31,740 basehttp 154 "POST /invoice/ HTTP/1.1" 500 111600
  982. INFO 2019-10-18 14:29:33,513 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  983. INFO 2019-10-18 14:30:49,220 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  984. INFO 2019-10-18 14:33:54,856 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  985. INFO 2019-10-18 16:55:49,676 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  986. WARNING 2019-10-18 17:35:41,041 log 228 Forbidden: /invoice/
  987. WARNING 2019-10-18 17:35:41,042 basehttp 154 "POST /invoice/ HTTP/1.1" 403 12
  988. WARNING 2019-10-18 17:36:40,118 log 228 Forbidden: /invoice/
  989. WARNING 2019-10-18 17:36:40,118 basehttp 154 "POST /invoice/ HTTP/1.1" 403 12
  990. WARNING 2019-10-18 17:37:26,363 log 228 Forbidden: /invoice/
  991. WARNING 2019-10-18 17:37:26,363 basehttp 154 "POST /invoice/ HTTP/1.1" 403 12
  992. ERROR 2019-10-18 17:40:08,827 log 228 Internal Server Error: /invoice/
  993. Traceback (most recent call last):
  994. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  995. return self.cursor.execute(sql, params)
  996. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  997. return self.cursor.execute(sql, params)
  998. pyodbc.ProgrammingError: ('42000', "[42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]',' 附近有语法错误。 (102) (SQLExecDirectW); [42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]无法预定义语句。 (8180)")
  999. The above exception was the direct cause of the following exception:
  1000. Traceback (most recent call last):
  1001. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  1002. response = get_response(request)
  1003. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  1004. response = self.process_exception_by_middleware(e, request)
  1005. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  1006. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  1007. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  1008. return self.dispatch(request, *args, **kwargs)
  1009. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  1010. return handler(request, *args, **kwargs)
  1011. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 71, in post
  1012. row_usr = cursor.execute("SELECT COUNT(*) FROM SALM WHERE SAL_NO=%s,NAME=%s",[USR,USR_NAME]).fetchall()[0][0]
  1013. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  1014. return super().execute(sql, params)
  1015. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  1016. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  1017. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  1018. return executor(sql, params, many, context)
  1019. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  1020. return self.cursor.execute(sql, params)
  1021. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 89, in __exit__
  1022. raise dj_exc_value.with_traceback(traceback) from exc_value
  1023. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  1024. return self.cursor.execute(sql, params)
  1025. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  1026. return self.cursor.execute(sql, params)
  1027. django.db.utils.ProgrammingError: ('42000', "[42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]',' 附近有语法错误。 (102) (SQLExecDirectW); [42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]无法预定义语句。 (8180)")
  1028. ERROR 2019-10-18 17:40:08,829 basehttp 154 "POST /invoice/ HTTP/1.1" 500 126022
  1029. ERROR 2019-10-18 17:42:05,691 log 228 Internal Server Error: /invoice/
  1030. Traceback (most recent call last):
  1031. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  1032. response = get_response(request)
  1033. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  1034. response = self.process_exception_by_middleware(e, request)
  1035. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  1036. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  1037. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  1038. return self.dispatch(request, *args, **kwargs)
  1039. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  1040. return handler(request, *args, **kwargs)
  1041. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 91, in post
  1042. UNI_NO_PAY,SAL_ADR,SAL_TEL,SAL_KH_BANK,SAL_ID_CODE])
  1043. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  1044. return super().execute(sql, params)
  1045. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  1046. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  1047. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  1048. return executor(sql, params, many, context)
  1049. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  1050. return self.cursor.execute(sql, params)
  1051. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 542, in execute
  1052. sql = self.format_sql(sql, params)
  1053. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 510, in format_sql
  1054. sql = sql % tuple('?' * len(params))
  1055. TypeError: not enough arguments for format string
  1056. ERROR 2019-10-18 17:42:05,693 basehttp 154 "POST /invoice/ HTTP/1.1" 500 114075
  1057. INFO 2019-10-18 18:14:39,620 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  1058. ERROR 2019-10-18 18:19:40,492 log 228 Internal Server Error: /invoice/
  1059. Traceback (most recent call last):
  1060. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  1061. response = get_response(request)
  1062. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  1063. response = self.process_exception_by_middleware(e, request)
  1064. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  1065. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  1066. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  1067. return self.dispatch(request, *args, **kwargs)
  1068. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  1069. return handler(request, *args, **kwargs)
  1070. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 108, in post
  1071. (%,200001,'LP',21,%s,%s,%s,%s,1,1,1)""", [ZL_NO, CUS_NO,CUS_NO_NAME,CUS_NO_NAME,AMT])
  1072. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  1073. return super().execute(sql, params)
  1074. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  1075. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  1076. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  1077. return executor(sql, params, many, context)
  1078. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  1079. return self.cursor.execute(sql, params)
  1080. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 542, in execute
  1081. sql = self.format_sql(sql, params)
  1082. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 510, in format_sql
  1083. sql = sql % tuple('?' * len(params))
  1084. ValueError: unsupported format character ',' (0x2c) at index 123
  1085. ERROR 2019-10-18 18:19:40,494 basehttp 154 "POST /invoice/ HTTP/1.1" 500 112036
  1086. INFO 2019-10-18 18:20:06,062 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  1087. INFO 2019-10-18 18:24:54,648 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  1088. INFO 2019-10-18 18:43:21,037 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  1089. ERROR 2019-10-18 19:37:18,327 log 228 Internal Server Error: /invoice/
  1090. Traceback (most recent call last):
  1091. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  1092. return self.cursor.execute(sql, params)
  1093. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  1094. return self.cursor.execute(sql, params)
  1095. pyodbc.ProgrammingError: ('42000', "[42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]在 SET 子句中多次指定了列名 'UP'。在同一 SET 子句中不得为一个列分配多个值。请修改 SET 子句,以确保一个列仅更新一次。如果 SET 子句更新了某视图的多列,那么列名 'UP' 可能会在该视图定义中出现两次。 (264) (SQLExecDirectW); [42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]无法预定义语句。 (8180)")
  1096. The above exception was the direct cause of the following exception:
  1097. Traceback (most recent call last):
  1098. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  1099. response = get_response(request)
  1100. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  1101. response = self.process_exception_by_middleware(e, request)
  1102. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  1103. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  1104. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  1105. return self.dispatch(request, *args, **kwargs)
  1106. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  1107. return handler(request, *args, **kwargs)
  1108. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 84, in post
  1109. VALUES('PC',%s,%s,'0000','AQ001',1,1,%s,%s,5,1,1,%s,%s)""", ['PC'+ZL_NO[2::], datetime.datetime.strptime(LZ_DD, '%Y-%m-%d'),AMT,AMT,AMT,AMT])
  1110. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  1111. return super().execute(sql, params)
  1112. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  1113. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  1114. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  1115. return executor(sql, params, many, context)
  1116. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  1117. return self.cursor.execute(sql, params)
  1118. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 89, in __exit__
  1119. raise dj_exc_value.with_traceback(traceback) from exc_value
  1120. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  1121. return self.cursor.execute(sql, params)
  1122. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  1123. return self.cursor.execute(sql, params)
  1124. django.db.utils.ProgrammingError: ('42000', "[42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]在 SET 子句中多次指定了列名 'UP'。在同一 SET 子句中不得为一个列分配多个值。请修改 SET 子句,以确保一个列仅更新一次。如果 SET 子句更新了某视图的多列,那么列名 'UP' 可能会在该视图定义中出现两次。 (264) (SQLExecDirectW); [42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]无法预定义语句。 (8180)")
  1125. ERROR 2019-10-18 19:37:18,330 basehttp 154 "POST /invoice/ HTTP/1.1" 500 131455
  1126. ERROR 2019-10-18 19:39:04,222 log 228 Internal Server Error: /invoice/
  1127. Traceback (most recent call last):
  1128. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  1129. response = get_response(request)
  1130. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  1131. response = self.process_exception_by_middleware(e, request)
  1132. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  1133. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  1134. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  1135. return self.dispatch(request, *args, **kwargs)
  1136. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  1137. return handler(request, *args, **kwargs)
  1138. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 84, in post
  1139. VALUES('PC',%s,%s,'0000','AQ001',1,%s,%s,%s,5,1,1,%s,%s)""", ['PC'+ZL_NO[2::], datetime.datetime.strptime(LZ_DD, '%Y-%m-%d'),AMT,AMT,AMT,AMT])
  1140. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  1141. return super().execute(sql, params)
  1142. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  1143. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  1144. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  1145. return executor(sql, params, many, context)
  1146. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  1147. return self.cursor.execute(sql, params)
  1148. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 542, in execute
  1149. sql = self.format_sql(sql, params)
  1150. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 510, in format_sql
  1151. sql = sql % tuple('?' * len(params))
  1152. TypeError: not enough arguments for format string
  1153. ERROR 2019-10-18 19:39:04,224 basehttp 154 "POST /invoice/ HTTP/1.1" 500 113069
  1154. ERROR 2019-10-18 19:41:17,426 log 228 Internal Server Error: /invoice/
  1155. Traceback (most recent call last):
  1156. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  1157. response = get_response(request)
  1158. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  1159. response = self.process_exception_by_middleware(e, request)
  1160. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  1161. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  1162. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  1163. return self.dispatch(request, *args, **kwargs)
  1164. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  1165. return handler(request, *args, **kwargs)
  1166. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 84, in post
  1167. VALUES('PC',%s,%s,'0000','AQ001',1,%s,%s,%s,5,1,1,%s,%s)""", ['PC'+ZL_NO[2::], datetime.datetime.strptime(LZ_DD, '%Y-%m-%d'),AMT,AMT,AMT])
  1168. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  1169. return super().execute(sql, params)
  1170. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  1171. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  1172. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  1173. return executor(sql, params, many, context)
  1174. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  1175. return self.cursor.execute(sql, params)
  1176. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 542, in execute
  1177. sql = self.format_sql(sql, params)
  1178. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 510, in format_sql
  1179. sql = sql % tuple('?' * len(params))
  1180. TypeError: not enough arguments for format string
  1181. ERROR 2019-10-18 19:41:17,428 basehttp 154 "POST /invoice/ HTTP/1.1" 500 112945
  1182. ERROR 2019-10-18 19:41:50,353 log 228 Internal Server Error: /invoice/
  1183. Traceback (most recent call last):
  1184. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  1185. return self.cursor.execute(sql, params)
  1186. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  1187. return self.cursor.execute(sql, params)
  1188. pyodbc.IntegrityError: ('23000', "[23000] [Microsoft][SQL Server Native Client 10.0][SQL Server]违反了 PRIMARY KEY 约束 'PK__MF_PSS'。不能在对象 'dbo.MF_PSS' 中插入重复键。 (2627) (SQLExecDirectW); [23000] [Microsoft][SQL Server Native Client 10.0][SQL Server]语句已终止。 (3621)")
  1189. The above exception was the direct cause of the following exception:
  1190. Traceback (most recent call last):
  1191. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  1192. response = get_response(request)
  1193. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  1194. response = self.process_exception_by_middleware(e, request)
  1195. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  1196. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  1197. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  1198. return self.dispatch(request, *args, **kwargs)
  1199. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  1200. return handler(request, *args, **kwargs)
  1201. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 81, in post
  1202. datetime.datetime.strptime(LZ_DD, '%Y-%m-%d'),AMT])
  1203. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  1204. return super().execute(sql, params)
  1205. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  1206. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  1207. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  1208. return executor(sql, params, many, context)
  1209. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  1210. return self.cursor.execute(sql, params)
  1211. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 89, in __exit__
  1212. raise dj_exc_value.with_traceback(traceback) from exc_value
  1213. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  1214. return self.cursor.execute(sql, params)
  1215. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  1216. return self.cursor.execute(sql, params)
  1217. django.db.utils.IntegrityError: ('23000', "[23000] [Microsoft][SQL Server Native Client 10.0][SQL Server]违反了 PRIMARY KEY 约束 'PK__MF_PSS'。不能在对象 'dbo.MF_PSS' 中插入重复键。 (2627) (SQLExecDirectW); [23000] [Microsoft][SQL Server Native Client 10.0][SQL Server]语句已终止。 (3621)")
  1218. ERROR 2019-10-18 19:41:50,355 basehttp 154 "POST /invoice/ HTTP/1.1" 500 130619
  1219. ERROR 2019-10-18 19:42:27,658 log 228 Internal Server Error: /invoice/
  1220. Traceback (most recent call last):
  1221. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  1222. return self.cursor.execute(sql, params)
  1223. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  1224. return self.cursor.execute(sql, params)
  1225. pyodbc.ProgrammingError: ('42000', "[42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]在 SET 子句中多次指定了列名 'UP'。在同一 SET 子句中不得为一个列分配多个值。请修改 SET 子句,以确保一个列仅更新一次。如果 SET 子句更新了某视图的多列,那么列名 'UP' 可能会在该视图定义中出现两次。 (264) (SQLExecDirectW); [42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]无法预定义语句。 (8180)")
  1226. The above exception was the direct cause of the following exception:
  1227. Traceback (most recent call last):
  1228. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  1229. response = get_response(request)
  1230. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  1231. response = self.process_exception_by_middleware(e, request)
  1232. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  1233. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  1234. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  1235. return self.dispatch(request, *args, **kwargs)
  1236. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  1237. return handler(request, *args, **kwargs)
  1238. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 84, in post
  1239. VALUES('PC',%s,%s,'0000','AQ001',1,1,%s,%s,5,1,1,%s,%s)""", ['PC'+ZL_NO[2::], datetime.datetime.strptime(LZ_DD, '%Y-%m-%d'),AMT,AMT,AMT,AMT])
  1240. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  1241. return super().execute(sql, params)
  1242. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  1243. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  1244. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  1245. return executor(sql, params, many, context)
  1246. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  1247. return self.cursor.execute(sql, params)
  1248. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 89, in __exit__
  1249. raise dj_exc_value.with_traceback(traceback) from exc_value
  1250. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  1251. return self.cursor.execute(sql, params)
  1252. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  1253. return self.cursor.execute(sql, params)
  1254. django.db.utils.ProgrammingError: ('42000', "[42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]在 SET 子句中多次指定了列名 'UP'。在同一 SET 子句中不得为一个列分配多个值。请修改 SET 子句,以确保一个列仅更新一次。如果 SET 子句更新了某视图的多列,那么列名 'UP' 可能会在该视图定义中出现两次。 (264) (SQLExecDirectW); [42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]无法预定义语句。 (8180)")
  1255. ERROR 2019-10-18 19:42:27,659 basehttp 154 "POST /invoice/ HTTP/1.1" 500 131458
  1256. ERROR 2019-10-18 19:43:44,138 log 228 Internal Server Error: /invoice/
  1257. Traceback (most recent call last):
  1258. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  1259. return self.cursor.execute(sql, params)
  1260. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  1261. return self.cursor.execute(sql, params)
  1262. pyodbc.ProgrammingError: ('42000', "[42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]在 SET 子句中多次指定了列名 'UP'。在同一 SET 子句中不得为一个列分配多个值。请修改 SET 子句,以确保一个列仅更新一次。如果 SET 子句更新了某视图的多列,那么列名 'UP' 可能会在该视图定义中出现两次。 (264) (SQLExecDirectW); [42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]无法预定义语句。 (8180)")
  1263. The above exception was the direct cause of the following exception:
  1264. Traceback (most recent call last):
  1265. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  1266. response = get_response(request)
  1267. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  1268. response = self.process_exception_by_middleware(e, request)
  1269. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  1270. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  1271. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  1272. return self.dispatch(request, *args, **kwargs)
  1273. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  1274. return handler(request, *args, **kwargs)
  1275. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 84, in post
  1276. VALUES('PC',%s,%s,'0000','AQ001',1,1,%s,%s,5,1,1,%s,%s)""", ['PC'+ZL_NO[2::], datetime.datetime.strptime(LZ_DD, '%Y-%m-%d'),AMT,AMT,AMT,AMT])
  1277. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  1278. return super().execute(sql, params)
  1279. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  1280. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  1281. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  1282. return executor(sql, params, many, context)
  1283. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  1284. return self.cursor.execute(sql, params)
  1285. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 89, in __exit__
  1286. raise dj_exc_value.with_traceback(traceback) from exc_value
  1287. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  1288. return self.cursor.execute(sql, params)
  1289. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  1290. return self.cursor.execute(sql, params)
  1291. django.db.utils.ProgrammingError: ('42000', "[42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]在 SET 子句中多次指定了列名 'UP'。在同一 SET 子句中不得为一个列分配多个值。请修改 SET 子句,以确保一个列仅更新一次。如果 SET 子句更新了某视图的多列,那么列名 'UP' 可能会在该视图定义中出现两次。 (264) (SQLExecDirectW); [42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]无法预定义语句。 (8180)")
  1292. ERROR 2019-10-18 19:43:44,139 basehttp 154 "POST /invoice/ HTTP/1.1" 500 131458
  1293. ERROR 2019-10-18 19:45:12,557 log 228 Internal Server Error: /invoice/
  1294. Traceback (most recent call last):
  1295. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  1296. return self.cursor.execute(sql, params)
  1297. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  1298. return self.cursor.execute(sql, params)
  1299. pyodbc.ProgrammingError: ('42000', "[42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]在 SET 子句中多次指定了列名 'UP'。在同一 SET 子句中不得为一个列分配多个值。请修改 SET 子句,以确保一个列仅更新一次。如果 SET 子句更新了某视图的多列,那么列名 'UP' 可能会在该视图定义中出现两次。 (264) (SQLExecDirectW); [42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]无法预定义语句。 (8180)")
  1300. The above exception was the direct cause of the following exception:
  1301. Traceback (most recent call last):
  1302. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  1303. response = get_response(request)
  1304. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  1305. response = self.process_exception_by_middleware(e, request)
  1306. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  1307. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  1308. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  1309. return self.dispatch(request, *args, **kwargs)
  1310. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  1311. return handler(request, *args, **kwargs)
  1312. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 84, in post
  1313. VALUES('PC',%s,%s,'0000','AQ001',1,1,%s,%s,5,1,1,%s,%s)""", ['PC'+ZL_NO[2::], datetime.datetime.strptime(LZ_DD, '%Y-%m-%d'),AMT,AMT,AMT,AMT])
  1314. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  1315. return super().execute(sql, params)
  1316. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  1317. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  1318. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  1319. return executor(sql, params, many, context)
  1320. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  1321. return self.cursor.execute(sql, params)
  1322. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 89, in __exit__
  1323. raise dj_exc_value.with_traceback(traceback) from exc_value
  1324. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  1325. return self.cursor.execute(sql, params)
  1326. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  1327. return self.cursor.execute(sql, params)
  1328. django.db.utils.ProgrammingError: ('42000', "[42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]在 SET 子句中多次指定了列名 'UP'。在同一 SET 子句中不得为一个列分配多个值。请修改 SET 子句,以确保一个列仅更新一次。如果 SET 子句更新了某视图的多列,那么列名 'UP' 可能会在该视图定义中出现两次。 (264) (SQLExecDirectW); [42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]无法预定义语句。 (8180)")
  1329. ERROR 2019-10-18 19:45:12,560 basehttp 154 "POST /invoice/ HTTP/1.1" 500 131458
  1330. ERROR 2019-10-18 19:47:07,834 log 228 Internal Server Error: /invoice/
  1331. Traceback (most recent call last):
  1332. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  1333. return self.cursor.execute(sql, params)
  1334. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  1335. return self.cursor.execute(sql, params)
  1336. pyodbc.ProgrammingError: ('42000', "[42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]在 SET 子句中多次指定了列名 'EST_ITM'。在同一 SET 子句中不得为一个列分配多个值。请修改 SET 子句,以确保一个列仅更新一次。如果 SET 子句更新了某视图的多列,那么列名 'EST_ITM' 可能会在该视图定义中出现两次。 (264) (SQLExecDirectW); [42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]无法预定义语句。 (8180)")
  1337. The above exception was the direct cause of the following exception:
  1338. Traceback (most recent call last):
  1339. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\exception.py", line 34, in inner
  1340. response = get_response(request)
  1341. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 126, in _get_response
  1342. response = self.process_exception_by_middleware(e, request)
  1343. File "C:\Users\12446\Envs\awj\lib\site-packages\django\core\handlers\base.py", line 124, in _get_response
  1344. response = wrapped_callback(request, *callback_args, **callback_kwargs)
  1345. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 68, in view
  1346. return self.dispatch(request, *args, **kwargs)
  1347. File "C:\Users\12446\Envs\awj\lib\site-packages\django\views\generic\base.py", line 88, in dispatch
  1348. return handler(request, *args, **kwargs)
  1349. File "E:\12446\PycharmProjects\wangli\wanjia\awj\awj\apps\stockinvoice\views.py", line 108, in post
  1350. ('LP',%s,1,%s,%s,%s,'AQ001',0,%s,5,1,1,'PC',1,'服務費用',%s,1,1,1)""", [ZL_NO,'PC'+ZL_NO[2::],AMT,AMT,datetime.datetime.strptime(LZ_DD, '%Y-%m-%d'),CUS_NO])
  1351. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 100, in execute
  1352. return super().execute(sql, params)
  1353. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 68, in execute
  1354. return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)
  1355. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 77, in _execute_with_wrappers
  1356. return executor(sql, params, many, context)
  1357. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  1358. return self.cursor.execute(sql, params)
  1359. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\utils.py", line 89, in __exit__
  1360. raise dj_exc_value.with_traceback(traceback) from exc_value
  1361. File "C:\Users\12446\Envs\awj\lib\site-packages\django\db\backends\utils.py", line 85, in _execute
  1362. return self.cursor.execute(sql, params)
  1363. File "C:\Users\12446\Envs\awj\lib\site-packages\sql_server\pyodbc\base.py", line 546, in execute
  1364. return self.cursor.execute(sql, params)
  1365. django.db.utils.ProgrammingError: ('42000', "[42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]在 SET 子句中多次指定了列名 'EST_ITM'。在同一 SET 子句中不得为一个列分配多个值。请修改 SET 子句,以确保一个列仅更新一次。如果 SET 子句更新了某视图的多列,那么列名 'EST_ITM' 可能会在该视图定义中出现两次。 (264) (SQLExecDirectW); [42000] [Microsoft][SQL Server Native Client 10.0][SQL Server]无法预定义语句。 (8180)")
  1366. ERROR 2019-10-18 19:47:07,836 basehttp 154 "POST /invoice/ HTTP/1.1" 500 131500
  1367. INFO 2019-10-18 19:48:39,128 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  1368. INFO 2019-10-18 19:52:03,188 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25
  1369. INFO 2019-10-18 20:02:22,372 basehttp 154 "POST /invoice/ HTTP/1.1" 200 25