How to populate DB from PDF extracted data

2018-03-09 Thread Shazia Nusrat
Hi, I am trying to work around with PDF's where user uploads PDF in image or filefield and then way to extract it for Django and finally update DB table based on it. Following are the models: class StudentFee(models.Model): class_name = models.CharField(choices=CLASSES, max_lenght=200)

Re: How to populate DB from PDF extracted data

2018-03-09 Thread m1chael
Good luck. Best case scenario in my opinion is using the utility pdf2text and regex, and this will be painful. On Fri, Mar 9, 2018, 3:01 AM Shazia Nusrat wrote: > Hi, > > I am trying to work around with PDF's where user uploads PDF in image or > filefield and then way to extract it for Django

Re: How to populate DB from PDF extracted data

2018-03-09 Thread Jason
PDF processing is very difficult, because the entire standard is a dumpster fire. For example, it has no concept of structure like headings, paragraphs or sentences because each and every character is just a character, location coordinate, font size and font type. In order to process the docum

Re: Customizing mode loading ...

2018-03-09 Thread Bernd Wechner
Well, not a single reply. So I'll reply with confirmation that the strategy below seems to work just fine! Have implemented what I need using that. Three distinct methods through which django loads a model instance (object) from database and overriding these provides a hook into making an object

Re: Printing to console from async method inside django channels

2018-03-09 Thread Andrew Godwin
Hi Chris, Since you also posted this to GitHub ( https://github.com/django/channels/issues/967), I will answer there. Andrew On Thu, Mar 8, 2018 at 8:17 PM, Chris Barry wrote: > I'm trying to print inside these methods in from this example in django > channels: > > https://github.com/andrewgod

Re: Printing to console from async method inside django channels

2018-03-09 Thread Chris Barry
Thanks very much, double posting the solution here just in case it helps anyone else: Ah, that didn't do it, so I did a full upgrade of channels, something in this set of upgrades sorted it. pip install channels -U Installing collected packages: asgiref, autobahn, daphne, Django, setuptools

Re: How to populate DB from PDF extracted data

2018-03-09 Thread Jaap van Wingerde
Use 'pdftohtml - xml' to convert the pdf in an xml-file and use per line in de xml-file regulair expressions to extract the data. [pdftohtml] https://www.sourceforge.net/projects/pdftohtml/ Op Fri, 9 Mar 2018 00:00:39 -0800 Shazia Nusrat schreef: > Hi, > > I am trying to work around with PDF's

Create table rows by an entered number

2018-03-09 Thread Ondra Baumrt
Hi, is there any possibility how to create a table with as many rows as is an entered number. In example: I have in DB an integer number 5 which means that I want to create table with 5 rows. Can I create table for any entered number using for-cycle or otherwise? Thanks for your help -- You

Re: Create table rows by an entered number

2018-03-09 Thread Jani Tiainen
Hi. Surely you can. Django template language has everything you need to create tables by arbitrary rows and columns. 9.3.2018 17.23 "Ondra Baumrt" kirjoitti: > Hi, > is there any possibility how to create a table with as many rows as is an > entered number. In example: I have in DB an integer

When to create a new app

2018-03-09 Thread Cictani
Hello, I have problem to figure out when I should create a new app in my Django project. Can you give me some Tipps? Best regards Andreas -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving email

Re: Channels: channel_layer appears to time out

2018-03-09 Thread toby @ tobyz
Update: there was an issue, and running the stock Ubuntu 16.04 Python was the cause; 3.5.2. I’ve provisioned 3.6.4, and channels is doing exactly what I ask of it. > On 2 Mar 2018, at 12:13, opera...@tobyz.net wrote: > > Andrew, > > Thanks for taking the time to reply. > > In classic fashio

IPN Notifications from PayPal

2018-03-09 Thread anas . devriani
i use ngrock to host my website , and when i did a payment using my paypal acount i didn't received any IPN notifications to my admin dashboard my django version is : 1.10 this is my payment signals code https://pastebin.com/ng7GqHiv

GROUP BY behavior change in Django 2.0 with annotate/extra

2018-03-09 Thread Michael Soderstrom
In a 1.11 branch I had a complex raw sql snippet added to a query set via annotate. When I updated Django to 2.0, the query set behavior changed to include the raw sql in the GROUP BY which destroyed the performance. The same behavior occurred using annotate and extra. I was able to hack aro