我有以下字符串:-1,856,32,0,0,0.000000,0.0000000,0,0,137,0,0,0,1400,0,101,0,0,0,42,00,0,0,0,0,0,0,00,0,0,0,0,0,554,0-1,841,1,0,0,0.000000,0.0000000,0,0,163,0,0,0,1820,0,120,0,0,0,43,00,0,0,0,0,0,0,00,0,0,0,0,0,517,0然后我使用分隔符-1拆分它,这意味着将有一个由2个元素组成的数组(我们称它为array1)。现在,假设array1的第一个元素我想用\r\n再次拆分它,这将是一个数组(array
我在尝试向我的模型添加/发布数据时遇到了问题。这是我在pythonmanage.pyshell中所做的:>>>frombooking.modelsimport*>>>qa=Product.objects.get(id=5)>>>sd=Booking.objects.create(...date_select='2011-11-29',...product_name=qa.name,...quantity=1,...price=qa.price,...totalcost=20,...first_name='lalala',...last_name='sadsd',...contact='